isKnownIntrinsic
On this page

isKnownIntrinsic()

Function in Backends

Returns true when name is a builtin the registry can spell on every target: either an id with an INTRINSICS entry or a member of PORTABLE_INTRINSICS.

import { isKnownIntrinsic } from 'typeshade'

The signature, the description and the examples come from the compiler's own source at commit 26de7be8.

Syntax

const isKnownIntrinsic: (name: string) => boolean

Parameters

name string

The call id to test.

Return value

boolean

Description

An id that is neither is a user-defined or external function, which spells the same everywhere, or a builtin nobody has classified yet. Ids in PRE_EMIT_INTRINSICS return false: they are removed before emit and have no spelling.

See also

Source

src/core/intrinsics.ts, line 1155, at commit 26de7be8

Edit this page Report a problem