THRIFT-3417: "namespace xsd" is not really working
Client: XSD
Patch: Benjamin Gould
This closes #691
diff --git a/compiler/cpp/src/thrifty.yy b/compiler/cpp/src/thrifty.yy
index e0dde8c..59f6b4f 100644
--- a/compiler/cpp/src/thrifty.yy
+++ b/compiler/cpp/src/thrifty.yy
@@ -297,13 +297,17 @@
{
pdebug("Header -> Include");
}
-| tok_namespace tok_identifier tok_identifier
+| tok_namespace tok_identifier tok_identifier TypeAnnotations
{
pdebug("Header -> tok_namespace tok_identifier tok_identifier");
declare_valid_program_doctext();
if (g_parse_mode == PROGRAM) {
g_program->set_namespace($2, $3);
}
+ if ($4 != NULL) {
+ g_program->set_namespace_annotations($2, $4->annotations_);
+ delete $4;
+ }
}
| tok_namespace '*' tok_identifier
{