MCPcopy Create free account
hub / github.com/Kitware/CMake / Pop

Method Pop

Source/cmState.cxx:1039–1070  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1037}
1038
1039cmStateSnapshot cmState::Pop(cmStateSnapshot const& originSnapshot)
1040{
1041 cmStateDetail::PositionType pos = originSnapshot.Position;
1042 cmStateDetail::PositionType prevPos = pos;
1043 ++prevPos;
1044 prevPos->IncludeDirectoryPosition =
1045 prevPos->BuildSystemDirectory->IncludeDirectories.size();
1046 prevPos->CompileDefinitionsPosition =
1047 prevPos->BuildSystemDirectory->CompileDefinitions.size();
1048 prevPos->CompileOptionsPosition =
1049 prevPos->BuildSystemDirectory->CompileOptions.size();
1050 prevPos->LinkOptionsPosition =
1051 prevPos->BuildSystemDirectory->LinkOptions.size();
1052 prevPos->LinkDirectoriesPosition =
1053 prevPos->BuildSystemDirectory->LinkDirectories.size();
1054 prevPos->BuildSystemDirectory->CurrentScope = prevPos;
1055 prevPos->UnwindState = pos->UnwindState;
1056
1057 if (!pos->Keep && this->SnapshotData.IsLast(pos)) {
1058 if (pos->Vars != prevPos->Vars) {
1059 assert(this->VarTree.IsLast(pos->Vars));
1060 this->VarTree.Pop(pos->Vars);
1061 }
1062 if (pos->ExecutionListFile != prevPos->ExecutionListFile) {
1063 assert(this->ExecutionListFiles.IsLast(pos->ExecutionListFile));
1064 this->ExecutionListFiles.Pop(pos->ExecutionListFile);
1065 }
1066 this->SnapshotData.Pop(pos);
1067 }
1068
1069 return { this, prevPos };
1070}
1071
1072static bool ParseEntryWithoutType(std::string const& entry, std::string& var,
1073 std::string& value)

Callers 12

DetachMethod · 0.45
~IncludeScopeMethod · 0.45
~ListFileScopeMethod · 0.45
~DeferScopeMethod · 0.45
PopSnapshotMethod · 0.45
~FindPackageStackRAIIMethod · 0.45
WriteBacktraceMethod · 0.45
PopPolicyMethod · 0.45
PrintCallStackFunction · 0.45
AddMethod · 0.45
AddMethod · 0.45

Calls 2

IsLastMethod · 0.80
sizeMethod · 0.45

Tested by 2

AddMethod · 0.36