MCPcopy Create free account
hub / github.com/nodejs/node / _IsWindowsAbsPath

Function _IsWindowsAbsPath

tools/gyp/pylib/gyp/generator/msvs.py:180–187  ·  view source on GitHub ↗

On Cygwin systems Python needs a little help determining if a path is an absolute Windows path or not, so that it does not treat those as relative, which results in bad paths like: '..\\C:\\ \\some_source_code_file.cc'

(path)

Source from the content-addressed store, hash-verified

178
179
180def _IsWindowsAbsPath(path):
181 """
182 On Cygwin systems Python needs a little help determining if a path
183 is an absolute Windows path or not, so that
184 it does not treat those as relative, which results in bad paths like:
185 '..\\C:\\<some path>\\some_source_code_file.cc'
186 """
187 return path.startswith(("c:", "C:"))
188
189
190def _FixPaths(paths, separator="\\"):

Callers 1

_FixPathFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected