MCPcopy Index your code
hub / github.com/python/cpython / S_IFMT

Function S_IFMT

Lib/stat.py:27–31  ·  view source on GitHub ↗

Return the portion of the file's mode that describes the file type.

(mode)

Source from the content-addressed store, hash-verified

25 return mode & 0o7777
26
27def S_IFMT(mode):
28 """Return the portion of the file's mode that describes the
29 file type.
30 """
31 return mode & 0o170000
32
33# Constants used as S_IFMT() for various file types
34# (not all are implemented on all systems)

Callers 11

is_dirMethod · 0.90
is_fileMethod · 0.90
is_symlinkMethod · 0.90
S_ISDIRFunction · 0.85
S_ISCHRFunction · 0.85
S_ISBLKFunction · 0.85
S_ISREGFunction · 0.85
S_ISFIFOFunction · 0.85
S_ISLNKFunction · 0.85
S_ISSOCKFunction · 0.85
filemodeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…