From 02c4e53d423aed145b23f61efe40f29d13ce2bd9 Mon Sep 17 00:00:00 2001 From: jez_higgins <> Date: Fri, 5 Aug 2005 20:56:15 +0000 Subject: [PATCH] added default cases to switch statements, so that gcc won't complain about unhandled enum values look, i do know what i'm doing --- XPath/impl/xpath_function.hpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/XPath/impl/xpath_function.hpp b/XPath/impl/xpath_function.hpp index b877a27c..48497b30 100644 --- a/XPath/impl/xpath_function.hpp +++ b/XPath/impl/xpath_function.hpp @@ -133,6 +133,8 @@ public: case DOM::Node_base::ELEMENT_NODE: case DOM::Node_base::PROCESSING_INSTRUCTION_NODE: return new StringValue(node.hasNamespaceURI() ? node.getLocalName() : node.getNodeName()); + default: // put this in to keep gcc quiet + ; } // switch ... return new StringValue(""); } // evaluate @@ -163,6 +165,8 @@ public: case DOM::Node_base::ATTRIBUTE_NODE: case DOM::Node_base::ELEMENT_NODE: return new StringValue(node.getNamespaceURI()); + default: // put this in to keep gcc quiet + ; } // switch ... return new StringValue(""); } // evaluate @@ -194,6 +198,8 @@ public: case DOM::Node_base::ELEMENT_NODE: case DOM::Node_base::PROCESSING_INSTRUCTION_NODE: return new StringValue(node.getNodeName()); + default: // stop gcc generating a warning about unhandled enum values + ; } // switch ... return new StringValue(""); } // evaluate