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

Method visit

src/ast/ast_simulate.cpp:802–817  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

800 }
801
802 ExpressionPtr SimulateVisitor::visit(ExprMakeVariant * expr) {
803 const auto &at = expr->at;
804 SimNode_Block * block;
805 if ( expr->useCMRES ) {
806 block = context.code->makeNode<SimNode_MakeLocalCMRes>(at);
807 } else {
808 block = context.code->makeNode<SimNode_MakeLocal>(at, expr->stackTop);
809 }
810 auto simlist = sv_simulateLocal(expr);
811 block->total = int(simlist.size());
812 block->list = (SimNode **) context.code->allocate(sizeof(SimNode *)*block->total);
813 for ( uint32_t i=0, is=block->total; i!=is; ++i )
814 block->list[i] = simlist[i];
815 setE(expr, block);
816 return expr;
817 }
818
819 // structure
820

Callers 1

simulateExpressionMethod · 0.45

Calls 15

GetR2VFunction · 0.85
bakeConstStringKeyFunction · 0.85
getTypeBaseSizeFunction · 0.85
simulateExpressionFunction · 0.85
flattenOrSequenceFunction · 0.85
getCallBaseFunction · 0.85
matchEquNequZeroFunction · 0.85
copyFunction · 0.85
isRefMethod · 0.80
isHandleMethod · 0.80
getR2VTypeMethod · 0.80
getValueMethod · 0.80

Tested by

no test coverage detected