MCPcopy Create free account
hub / github.com/numpy/numpy / _parse_policy_not_keepbase

Method _parse_policy_not_keepbase

numpy/distutils/ccompiler_opt.py:2127–2147  ·  view source on GitHub ↗

skip all baseline features

(self, has_baseline, final_targets, extra_flags)

Source from the content-addressed store, hash-verified

2125 return targets
2126
2127 def _parse_policy_not_keepbase(self, has_baseline, final_targets, extra_flags):
2128 """skip all baseline features"""
2129 skipped = []
2130 for tar in final_targets[:]:
2131 is_base = False
2132 if isinstance(tar, str):
2133 is_base = tar in self.parse_baseline_names
2134 else:
2135 # multi targets
2136 is_base = all([
2137 f in self.parse_baseline_names
2138 for f in tar
2139 ])
2140 if is_base:
2141 skipped.append(tar)
2142 final_targets.remove(tar)
2143
2144 if skipped:
2145 self.dist_log("skip baseline features", skipped)
2146
2147 return has_baseline, final_targets, extra_flags
2148
2149 def _parse_policy_keepsort(self, has_baseline, final_targets, extra_flags):
2150 """leave a notice that $keep_sort is on"""

Callers

nothing calls this directly

Calls 2

allFunction · 0.50
dist_logMethod · 0.45

Tested by

no test coverage detected