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

Function HandleRemoveItemCommand

Source/cmListCommand.cxx:377–397  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

375}
376
377bool HandleRemoveItemCommand(std::vector<std::string> const& args,
378 cmExecutionStatus& status)
379{
380 assert(args.size() >= 2);
381
382 if (args.size() == 2) {
383 return true;
384 }
385
386 std::string const& listName = args[1];
387 // expand the variable
388 auto list = GetList(listName, status.GetMakefile());
389
390 if (!list) {
391 return true;
392 }
393
394 status.GetMakefile().AddDefinition(
395 listName, list->remove_items(args.begin() + 2, args.end()).to_string());
396 return true;
397}
398
399bool HandleReverseCommand(std::vector<std::string> const& args,
400 cmExecutionStatus& status)

Callers

nothing calls this directly

Calls 7

to_stringMethod · 0.80
GetListFunction · 0.70
sizeMethod · 0.45
GetMakefileMethod · 0.45
AddDefinitionMethod · 0.45
beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…