THRIFT-877. compiler: smalltalk namespace doesn't work
This patch adds a special case to map 'smalltalk' to 'st' when checking for valid namespace declarations.
Patch: Bruce Lowekamp
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@990866 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/compiler/cpp/src/parse/t_program.h b/compiler/cpp/src/parse/t_program.h
index ddf7cd1..4f8f151 100644
--- a/compiler/cpp/src/parse/t_program.h
+++ b/compiler/cpp/src/parse/t_program.h
@@ -164,6 +164,11 @@
std::string base_language = language.substr(0, sub_index);
std::string sub_namespace;
+ if(base_language == "smalltalk") {
+ pwarning(1, "Namespace 'smalltalk' is deprecated. Use 'st' instead");
+ base_language = "st";
+ }
+
t_generator_registry::gen_map_t my_copy = t_generator_registry::get_generator_map();
t_generator_registry::gen_map_t::iterator it;