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

Function apple_target

Platforms/Apple/__main__.py:275–283  ·  view source on GitHub ↗

Return the Apple platform identifier for a given host triple.

(host: str)

Source from the content-addressed store, hash-verified

273
274
275def apple_target(host: str) -> str:
276 """Return the Apple platform identifier for a given host triple."""
277 for _, platform_slices in HOSTS.items():
278 for slice_name, slice_parts in platform_slices.items():
279 for host_triple, multiarch in slice_parts.items():
280 if host == host_triple:
281 return ".".join(multiarch.split("-")[::-1])
282
283 raise KeyError(host)
284
285
286def apple_multiarch(host: str) -> str:

Callers 1

unpack_depsFunction · 0.85

Calls 3

itemsMethod · 0.45
joinMethod · 0.45
splitMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…