MCPcopy Create free account
hub / github.com/beefytech/Beef / MarkUsingThis

Method MarkUsingThis

IDEHelper/Compiler/BfModule.cpp:15833–15847  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15831}
15832
15833void BfModule::MarkUsingThis()
15834{
15835 auto useMethodState = mCurMethodState;
15836 while ((useMethodState != NULL) && (useMethodState->mClosureState != NULL) && (useMethodState->mClosureState->mCapturing))
15837 {
15838 useMethodState = useMethodState->mPrevMethodState;
15839 }
15840
15841 if ((useMethodState != NULL) && (!useMethodState->mLocals.IsEmpty()))
15842 {
15843 auto localVar = useMethodState->mLocals[0];
15844 if (localVar->mIsThis)
15845 localVar->mReadFromId = useMethodState->GetRootMethodState()->mCurAccessId++;
15846 }
15847}
15848
15849BfTypedValue BfModule::GetThis(bool markUsing)
15850{

Callers 3

LookupIdentifierMethod · 0.80
LoadPropertyMethod · 0.80
LoadFieldMethod · 0.80

Calls 2

GetRootMethodStateMethod · 0.80
IsEmptyMethod · 0.45

Tested by

no test coverage detected