Skip to content

PromptScript API


Interface: InheritOperation

Defined in: core/src/types/ast.ts:645

Canonical inheritance operation.

Extends

Properties

declaration

readonly declaration: object

Defined in: core/src/types/ast.ts:647

loc

readonly loc: object

Source location

loc.column

readonly column: number

Column number (1-indexed)

loc.file

readonly file: string

File path

loc.line

readonly line: number

Line number (1-indexed)

loc.offset?

readonly optional offset?: number

Byte offset from start of file

params?

readonly optional params?: readonly object[]

Template parameters (for parameterized inheritance)

path

readonly path: object

Path to parent file

path.isRelative

readonly isRelative: boolean

Whether this is a relative path

path.loc

readonly loc: object

Source location

path.loc.column

readonly column: number

Column number (1-indexed)

path.loc.file

readonly file: string

File path

path.loc.line

readonly line: number

Line number (1-indexed)

path.loc.offset?

readonly optional offset?: number

Byte offset from start of file

path.namespace?

readonly optional namespace?: string

Namespace (e.g., "core" from "@core/...")

path.raw

readonly raw: string

Original string representation

path.segments

readonly segments: readonly string[]

Path segments

path.type

readonly type: "PathReference"

Node type discriminator

path.version?

readonly optional version?: string

Version constraint

type

readonly type: "InheritDeclaration"

Node type discriminator


loc

readonly loc: object

Defined in: core/src/types/ast.ts:467

column

readonly column: number

Column number (1-indexed)

file

readonly file: string

File path

line

readonly line: number

Line number (1-indexed)

offset?

readonly optional offset?: number

Byte offset from start of file

Inherited from

CanonicalNode.loc


sourceLayerId

readonly sourceLayerId: string

Defined in: core/src/types/ast.ts:648


type

readonly type: "InheritOperation"

Defined in: core/src/types/ast.ts:646

Overrides

CanonicalNode.type