MCPcopy Create free account
hub / github.com/GaijinEntertainment/daScript / getReaderMacro

Method getReaderMacro

src/ast/ast_program.cpp:10–26  ·  view source on GitHub ↗

program

Source from the content-addressed store, hash-verified

8
9 // program
10 vector<ReaderMacro*> Program::getReaderMacro ( const string & name ) const {
11 vector<ReaderMacro*> macros;
12 string moduleName, markupName;
13 splitTypeName(name, moduleName, markupName);
14 auto tmod = thisModule.get();
15 auto modMacro = [&](Module * mod) -> bool {
16 if ( thisModule->isVisibleDirectly(mod) && mod!=tmod ) {
17 auto it = mod->readMacros.find(markupName);
18 if ( it != mod->readMacros.end() ) {
19 macros.push_back(it->second.get());
20 }
21 }
22 return true;
23 };
24 library.foreach(modMacro, moduleName);
25 return macros;
26 }
27
28 int Program::getContextStackSize() const {
29 return options.getIntOption("stack", policies.stack);

Callers 4

yyparseFunction · 0.80
yyparseFunction · 0.80
ds2_lexer.cppFile · 0.80
yyparseFunction · 0.80

Calls 6

splitTypeNameFunction · 0.85
getMethod · 0.45
findMethod · 0.45
endMethod · 0.45
push_backMethod · 0.45
foreachMethod · 0.45

Tested by

no test coverage detected