2 #ifndef PARALLEL_COMPASS_FUNCTIONNAMES_H
3 #define PARALLEL_COMPASS_FUNCTIONNAMES_H
8 #define DEBUG_OUTPUT_FUNCNAMES false
21 #if DEBUG_OUTPUT_FUNCNAMES
22 std::cout <<
" eval inherited: node: " << node->
class_name() <<
" depth:" << depth << std::endl;
41 std::string result =
"";
43 for (s = synAttributes.
begin(); s != synAttributes.
end(); ++s)
45 std::string &str = *s;
47 if (str.size() > 0 && str[str.size()-1] !=
'\n')
50 #if DEBUG_OUTPUT_FUNCNAMES
51 std::cout <<
" eval synthesized: node: " << node->
class_name() <<
" result:" << result <<
" ..............\n" <<std::endl;
70 class FunctionNames:
public DistributedMemoryTraversal<int, std::string>
80 s <<
"process " << myID() <<
": at depth " << depth <<
": function " << funcName;
81 #if DEBUG_OUTPUT_FUNCNAMES
82 std::cout <<
" analyzeSubtree of funcDecl: " << funcName <<
" id:" << myID()
83 <<
" result: " << s.str() << std::endl;
92 int len = attribute.size() + 1;
93 char *str = strdup(attribute.c_str());
94 return std::make_pair(len, str);
100 return std::string((
const char *) serializedAttribute.second);
107 std::free(serializedAttribute.second);