erlang: Make the gen-code return a special value for bogus functions
authorDavid Reiss <dreiss@apache.org>
Mon, 30 Aug 2010 22:05:27 +0000 (22:05 +0000)
committerDavid Reiss <dreiss@apache.org>
Mon, 30 Aug 2010 22:05:27 +0000 (22:05 +0000)
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@990978 13f79535-47bb-0310-9956-ffa450edef68

compiler/cpp/src/generate/t_erl_generator.cc

index 30003ab..a5b6b9c 100644 (file)
@@ -649,8 +649,8 @@ void t_erl_generator::generate_service_interface(t_service* tservice) {
                          << "_thrift:function_info(Function, InfoType)." << endl;
       indent_down();
   } else {
-      // Dummy function_info so we don't worry about the ;s
-      indent(f_service_) << "function_info(xxx, dummy) -> dummy." << endl;
+      // Use a special return code for nonexistent functions
+      indent(f_service_) << "function_info(_Func, _Info) -> no_function." << endl;
   }
 
   indent(f_service_) << endl;