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

Function std_c_flags

setup.py:283–300  ·  view source on GitHub ↗
(cmd)

Source from the content-addressed store, hash-verified

281 return flags
282
283 def std_c_flags(cmd):
284 compiler = cmd.compiler
285 flags = getattr(compiler, '__np_cache_c_flags', None)
286 if flags is not None:
287 return flags
288 flags = dict(
289 msvc = []
290 ).get(compiler.compiler_type, ['-std=c99'])
291
292 if not flags_is_required(compiler, False, flags, textwrap.dedent('''
293 inline static int test_inline() { return 0; }
294 int main(void)
295 { return test_inline(); }
296 ''')):
297 flags.clear()
298
299 setattr(compiler, '__np_cache_c_flags', flags)
300 return flags
301
302 class new_build_clib(build_clib):
303 def build_a_library(self, build_info, lib_name, libraries):

Callers 2

build_a_libraryMethod · 0.85
build_extensionMethod · 0.85

Calls 3

flags_is_requiredFunction · 0.85
clearMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected