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

Function process_tempita_pyd

tools/cythonize.py:64–73  ·  view source on GitHub ↗
(fromfile, tofile)

Source from the content-addressed store, hash-verified

62
63
64def process_tempita_pyd(fromfile, tofile):
65 import npy_tempita as tempita
66
67 assert fromfile.endswith('.pxd.in')
68 assert tofile.endswith('.pxd')
69 with open(fromfile) as f:
70 tmpl = f.read()
71 pyxcontent = tempita.sub(tmpl)
72 with open(tofile, "w") as f:
73 f.write(pyxcontent)
74
75def process_tempita_pxi(fromfile, tofile):
76 import npy_tempita as tempita

Callers

nothing calls this directly

Calls 4

openFunction · 0.85
endswithMethod · 0.80
readMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected