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

Function appendIndVariables

src/ast/ast_derive_alias.cpp:11–22  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9 typedef das_hash_set<Variable *> ExpressionSources;
10
11 void appendIndVariables ( Function * lookup, IndirectSources & indGlobalVariables, das_hash_set<Function *> & accessed ) {
12 if ( accessed.find(lookup)!=accessed.end() ) return;
13 accessed.insert(lookup);
14 for ( auto var : lookup->useGlobalVariables ) {
15 if ( indGlobalVariables.find(var)==indGlobalVariables.end() ) {
16 indGlobalVariables[var] = lookup;
17 }
18 }
19 for ( auto fun : lookup->useFunctions ) {
20 appendIndVariables(fun, indGlobalVariables, accessed);
21 }
22 }
23
24 bool isCompatibleFunction ( const FunctionPtr & func, const TypeDeclPtr & inv ) {
25 if ( func->arguments.size()!=inv->argTypes.size() ) return false;

Callers 3

deriveAliasingFunction · 0.85

Calls 3

findMethod · 0.45
endMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected