added default cases to switch statements, so that gcc won't complain about

unhandled enum values

look, i do know what i'm doing
This commit is contained in:
jez_higgins 2005-08-05 20:56:15 +00:00
parent 135e75220b
commit 02c4e53d42

View file

@ -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