MCPcopy Create free account
hub / github.com/boostorg/build / construct

Method construct

v2/tools/cast.py:36–49  ·  view source on GitHub ↗
(name, source_targets, ps)

Source from the content-addressed store, hash-verified

34class CastTargetClass(targets.TypedTarget):
35
36 def construct(name, source_targets, ps):
37 result = []
38 for s in source_targets:
39 if not isinstance(s, virtual_targets.FileTarget):
40 get_manager().errors()("Source to the 'cast' metatager is not a file")
41
42 if s.action():
43 get_manager().errors()("Only non-derived targets allowed as sources for 'cast'.")
44
45
46 r = s.clone_with_different_type(self.type())
47 result.append(get_manager().virtual_targets().register(r))
48
49 return result
50
51
52@bjam_signature((["name", "type"], ["sources", "*"], ["requirements", "*"],

Callers

nothing calls this directly

Calls 5

get_managerFunction · 0.90
errorsMethod · 0.80
appendMethod · 0.80
virtual_targetsMethod · 0.80
registerMethod · 0.45

Tested by

no test coverage detected