astdef

Search:
Group by:
Source   Edit  

Types

CompilesId = int
id that is used for the caching logic within system.compiles. See the seminst module. Source   Edit  
ItemId = object
  module*: int32
  item*: int32
Source   Edit  
ItemState = enum
  Complete, Partial, Sealed
Source   Edit  
PLib = ref TLib
Source   Edit  
PNode = ref TNode
Source   Edit  
PScope = ref TScope
Source   Edit  
PSym = ref TSym
Source   Edit  
PType = ref TType
Source   Edit  
TCallingConvention = enum
  ccNimCall = "nimcall", ccStdCall = "stdcall", ccCDecl = "cdecl",
  ccSafeCall = "safecall", ccSysCall = "syscall", ccInline = "inline",
  ccNoInline = "noinline", ccFastCall = "fastcall", ccThisCall = "thiscall",
  ccClosure = "closure", ccNoConvention = "noconv", ccMember = "member"
Source   Edit  
TIdPair[T] = object
  key*: ItemId
  val*: T
Source   Edit  
TIdPairSeq[T] = seq[TIdPair[T]]
Source   Edit  
TIdTable[T] = object
  counter*: int
  data*: TIdPairSeq[T]
Source   Edit  
TImplication = enum
  impUnknown, impNo, impYes
Source   Edit  
TInstantiation = object
  sym*: PSym
  concreteTypes*: seq[PType]
  genericParamsCount*: int
  compilesId*: CompilesId
Source   Edit  
TLib = object
  kind*: TLibKind
  generated*: bool
  isOverridden*: bool
  name*: Rope
  path*: PNode
Source   Edit  
TLibKind = enum
  libHeader, libDynamic
Source   Edit  
TLoc = object
  k*: TLocKind
  storage*: TStorageLoc
  flags*: TLocFlags
  lode*: PNode
  snippet*: Rope
Source   Edit  
TLocFlag = enum
  lfIndirect, lfNoDeepCopy, lfNoDecl, lfDynamicLib, lfExportLib, lfHeader,
  lfImportCompilerProc, lfSingleUse, lfEnforceDeref, lfPrepareForMutation
Source   Edit  
TLocFlags = set[TLocFlag]
Source   Edit  
TLocKind = enum
  locNone, locTemp, locLocalVar, locGlobalVar, locParam, locField, locExpr,
  locProc, locData, locCall, locOther
Source   Edit  
TMagic = enum
  mNone, mDefined, mDeclared, mDeclaredInScope, mCompiles, mArrGet, mArrPut,
  mAsgn, mLow, mHigh, mSizeOf, mAlignOf, mOffsetOf, mTypeTrait, mIs, mOf, mAddr,
  mType, mTypeOf, mPlugin, mEcho, mShallowCopy, mSlurp, mStaticExec, mStatic,
  mParseExprToAst, mParseStmtToAst, mExpandToAst, mQuoteAst, mInc, mDec, mOrd,
  mNew, mNewFinalize, mNewSeq, mNewSeqOfCap, mLengthOpenArray, mLengthStr,
  mLengthArray, mLengthSeq, mIncl, mExcl, mCard, mChr, mGCref, mGCunref, mAddI,
  mSubI, mMulI, mDivI, mModI, mSucc, mPred, mAddF64, mSubF64, mMulF64, mDivF64,
  mShrI, mShlI, mAshrI, mBitandI, mBitorI, mBitxorI, mMinI, mMaxI, mAddU, mSubU,
  mMulU, mDivU, mModU, mEqI, mLeI, mLtI, mEqF64, mLeF64, mLtF64, mLeU, mLtU,
  mEqEnum, mLeEnum, mLtEnum, mEqCh, mLeCh, mLtCh, mEqB, mLeB, mLtB, mEqRef,
  mLePtr, mLtPtr, mXor, mEqCString, mEqProc, mUnaryMinusI, mUnaryMinusI64,
  mAbsI, mNot, mUnaryPlusI, mBitnotI, mUnaryPlusF64, mUnaryMinusF64, mCharToStr,
  mBoolToStr, mCStrToStr, mStrToStr, mEnumToStr, mAnd, mOr, mImplies, mIff,
  mExists, mForall, mOld, mEqStr, mLeStr, mLtStr, mEqSet, mLeSet, mLtSet,
  mMulSet, mPlusSet, mMinusSet, mXorSet, mConStrStr, mSlice, mDotDot, mFields,
  mFieldPairs, mOmpParFor, mAppendStrCh, mAppendStrStr, mAppendSeqElem, mInSet,
  mRepr, mExit, mSetLengthStr, mSetLengthSeq, mSetLengthSeqUninit, mIsPartOf,
  mAstToStr, mParallel, mSwap, mIsNil, mArrToSeq, mOpenArrayToSeq, mNewString,
  mNewStringOfCap, mParseBiggestFloat, mMove, mEnsureMove, mWasMoved, mDup,
  mDestroy, mTrace, mDefault, mUnown, mFinished, mIsolate, mAccessEnv,
  mAccessTypeField, mArray, mOpenArray, mRange, mSet, mSeq, mVarargs, mRef,
  mPtr, mVar, mDistinct, mVoid, mTuple, mOrdinal, mIterableType, mInt, mInt8,
  mInt16, mInt32, mInt64, mUInt, mUInt8, mUInt16, mUInt32, mUInt64, mFloat,
  mFloat32, mFloat64, mFloat128, mBool, mChar, mString, mCstring, mPointer,
  mNil, mExpr, mStmt, mTypeDesc, mVoidType, mPNimrodNode, mSpawn, mDeepCopy,
  mIsMainModule, mCompileDate, mCompileTime, mProcCall, mCpuEndian, mHostOS,
  mHostCPU, mBuildOS, mBuildCPU, mAppType, mCompileOption, mCompileOptionArg,
  mNLen, mNChild, mNSetChild, mNAdd, mNAddMultiple, mNDel, mNKind, mNSymKind,
  mNccValue, mNccInc, mNcsAdd, mNcsIncl, mNcsLen, mNcsAt, mNctPut, mNctLen,
  mNctGet, mNctHasNext, mNctNext, mNIntVal, mNFloatVal, mNSymbol, mNIdent,
  mNGetType, mNStrVal, mNSetIntVal, mNSetFloatVal, mNSetSymbol, mNSetIdent,
  mNSetStrVal, mNLineInfo, mNNewNimNode, mNCopyNimNode, mNCopyNimTree,
  mStrToIdent, mNSigHash, mNSizeOf, mNBindSym, mNCallSite, mEqIdent,
  mEqNimrodNode, mSameNodeType, mGetImpl, mNGenSym, mNHint, mNWarning, mNError,
  mInstantiationInfo, mGetTypeInfo, mGetTypeInfoV2, mNimvm, mIntDefine,
  mStrDefine, mBoolDefine, mGenericDefine, mRunnableExamples, mException,
  mBuiltinType, mSymOwner, mUncheckedArray, mGetImplTransf,
  mSymIsInstantiationOf, mNodeId, mPrivateAccess, mZeroDefault
Source   Edit  
TNode {.final, acyclic.} = object
  when defined(useNodeIds):
    id*: int
  typField*: PType
  info*: TLineInfo
  flags*: TNodeFlags
  case kind*: TNodeKind
  of nkCharLit .. nkUInt64Lit:
    intVal*: BiggestInt
  of nkFloatLit .. nkFloat128Lit:
    floatVal*: BiggestFloat
  of nkStrLit .. nkTripleStrLit:
    strVal*: string
  of nkSym:
    sym*: PSym
  of nkIdent:
    ident*: PIdent
  else:
    sons*: TNodeSeq
  when defined(nimsuggest):
    endInfo*: TLineInfo
Source   Edit  
TNodeFlag = enum
  nfNone, nfBase2, nfBase8, nfBase16, nfAllConst, nfTransf, nfNoRewrite, nfSem,
  nfLL, nfDotField, nfDotSetter, nfExplicitCall, nfExprCall, nfIsRef, nfIsPtr,
  nfPreventCg, nfBlockArg, nfFromTemplate, nfDefaultParam, nfDefaultRefsParam,
  nfExecuteOnReload, nfLastRead, nfFirstWrite, nfHasComment,
  nfSkipFieldChecking, nfDisabledOpenSym
Source   Edit  
TNodeFlags = set[TNodeFlag]
Source   Edit  
TNodeKinds = set[TNodeKind]
Source   Edit  
TNodePair = object
  h*: Hash
  key*: PNode
  val*: int
Source   Edit  
TNodeSeq = seq[PNode]
Source   Edit  
TNodeTable = object
  counter*: int
  data*: TNodePairSeq
  ignoreTypes*: bool
Source   Edit  
TObjectSeq = seq[RootRef]
Source   Edit  
TObjectSet = object
  counter*: int
  data*: TObjectSeq
Source   Edit  
TPair = object
  key*, val*: RootRef
Source   Edit  
TPairSeq = seq[TPair]
Source   Edit  
TScope {.acyclic.} = object
  depthLevel*: int
  symbols*: TStrTable
  parent*: PScope
  allowPrivateAccess*: seq[PSym]
  optionStackLen*: int
Source   Edit  
TStorageLoc = enum
  OnUnknown, OnStatic, OnStack, OnHeap
Source   Edit  
TStrTable = object
  counter*: int
  data*: seq[PSym]
Source   Edit  
TSym {.acyclic.} = object
  itemId*: ItemId
  state*: ItemState
  case kindImpl*: TSymKind
  of routineKinds:
    gcUnsafetyReasonImpl*: PSym
    transformedBodyImpl*: PNode
  of skLet, skVar, skField, skForVar:
    guardImpl*: PSym
    bitsizeImpl*: int
    alignmentImpl*: int
  else:
    nil
  magicImpl*: TMagic
  typImpl*: PType
  name*: PIdent
  infoImpl*: TLineInfo
  when defined(nimsuggest):
    endInfoImpl*: TLineInfo
    hasUserSpecifiedTypeImpl*: bool
  ownerFieldImpl*: PSym
  flagsImpl*: TSymFlags
  astImpl*: PNode
  optionsImpl*: TOptions
  positionImpl*: int
  offsetImpl*: int32
  disamb*: int32
  locImpl*: TLoc
  annexImpl*: PLib
  when hasFFI:
    cnameImpl*: string
  constraintImpl*: PNode
  instantiatedFromImpl*: PSym
  when defined(nimsuggest):
    allUsagesImpl*: seq[TLineInfo]
Source   Edit  
TSymFlag = enum
  sfUsed, sfExported, sfFromGeneric, sfGlobal, sfForward, sfWasForwarded,
  sfImportc, sfExportc, sfMangleCpp, sfVolatile, sfRegister, sfPure,
  sfNoSideEffect, sfSideEffect, sfMainModule, sfSystemModule, sfNoReturn,
  sfAddrTaken, sfCompilerProc, sfEscapes, sfDiscriminant, sfRequiresInit,
  sfDeprecated, sfExplain, sfError, sfShadowed, sfThread, sfCppNonPod,
  sfCompileTime, sfConstructor, sfDispatcher, sfBorrow, sfInfixCall,
  sfNamedParamCall, sfDiscardable, sfOverridden, sfCallsite, sfGenSym,
  sfNonReloadable, sfGeneratedOp, sfTemplateParam, sfCursor,
  sfInjectDestructors, sfNeverRaises, sfSystemRaisesDefect,
  sfUsedInFinallyOrExcept, sfSingleUsedTemp, sfNoalias, sfEffectsDelayed,
  sfGeneratedType, sfVirtual, sfByCopy, sfMember, sfCodegenDecl, sfWasGenSym,
  sfForceLift, sfDirty, sfCustomPragma, sfBase, sfGoto, sfAnon, sfAllUntyped,
  sfTemplateRedefinition
Source   Edit  
TSymFlags = set[TSymFlag]
Source   Edit  
TSymKind = enum
  skUnknown, skConditional, skDynLib, skParam, skGenericParam, skTemp, skModule,
  skType, skVar, skLet, skConst, skResult, skProc, skFunc, skMethod, skIterator,
  skConverter, skMacro, skTemplate, skField, skEnumField, skForVar, skLabel,
  skStub, skPackage
Source   Edit  
TSymKinds = set[TSymKind]
Source   Edit  
TType {.acyclic.} = object
  itemId*: ItemId
  kind*: TTypeKind
  state*: ItemState
  uniqueId*: ItemId
  callConvImpl*: TCallingConvention
  flagsImpl*: TTypeFlags
  sonsImpl*: TTypeSeq
  nImpl*: PNode
  ownerFieldImpl*: PSym
  symImpl*: PSym
  sizeImpl*: BiggestInt
  alignImpl*: int16
  paddingAtEndImpl*: int16
  locImpl*: TLoc
  typeInstImpl*: PType
Source   Edit  
TTypeAttachedOp = enum
  attachedWasMoved, attachedDestructor, attachedAsgn, attachedDup, attachedSink,
  attachedTrace, attachedDeepCopy
as usual, order is important here Source   Edit  
TTypeFlag = enum
  tfVarargs, tfNoSideEffect, tfFinal, tfInheritable, tfHasOwned, tfEnumHasHoles,
  tfShallow, tfThread, tfFromGeneric, tfUnresolved, tfResolved, tfRetType,
  tfCapturesEnv, tfByCopy, tfByRef, tfIterator, tfPartial, tfNotNil,
  tfRequiresInit, tfNeedsFullInit, tfVarIsPtr, tfHasMeta, tfHasGCedMem,
  tfPacked, tfHasStatic, tfGenericTypeParam, tfImplicitTypeParam,
  tfInferrableStatic, tfConceptMatchedTypeSym, tfExplicit, tfWildcard,
  tfHasAsgn, tfBorrowDot, tfTriggersCompileTime, tfRefsAnonObj, tfCovariant,
  tfWeakCovariant, tfContravariant, tfCheckedForDestructor, tfAcyclic,
  tfIncompleteStruct, tfCompleteStruct, tfExplicitCallConv, tfIsConstructor,
  tfEffectSystemWorkaround, tfIsOutParam, tfSendable, tfImplicitStatic
Source   Edit  
TTypeFlags = set[TTypeFlag]
Source   Edit  
TTypeKind = enum
  tyNone, tyBool, tyChar, tyEmpty, tyAlias, tyNil, tyUntyped, tyTyped,
  tyTypeDesc, tyGenericInvocation, tyGenericBody, tyGenericInst, tyGenericParam,
  tyDistinct, tyEnum, tyOrdinal, tyArray, tyObject, tyTuple, tySet, tyRange,
  tyPtr, tyRef, tyVar, tySequence, tyProc, tyPointer, tyOpenArray, tyString,
  tyCstring, tyForward, tyInt, tyInt8, tyInt16, tyInt32, tyInt64, tyFloat,
  tyFloat32, tyFloat64, tyFloat128, tyUInt, tyUInt8, tyUInt16, tyUInt32,
  tyUInt64, tyOwned, tySink, tyLent, tyVarargs, tyUncheckedArray, tyError,
  tyBuiltInTypeClass, tyUserTypeClass, tyUserTypeClassInst,
  tyCompositeTypeClass, tyInferred, tyAnd, tyOr, tyNot, tyAnything, tyStatic,
  tyFromExpr, tyConcept, tyVoid, tyIterable
Source   Edit  
TTypeKinds = set[TTypeKind]
Source   Edit  
TTypeSeq = seq[PType]
Source   Edit  

Vars

eqTypeFlags = {tfIterator, tfNotNil, tfVarIsPtr, tfGcSafe, tfNoSideEffect,
               tfIsOutParam}
type flags that are essential for type equality. This is now a variable because for emulation of version:1.0 we might exclude {tfGcSafe, tfNoSideEffect}. Source   Edit  

Consts

abstractInst = {tyGenericInst, tyDistinct, tyOrdinal, tyTypeDesc, tyAlias,
                tyInferred, tySink, tyOwned}
Source   Edit  
abstractVarRange = {tyGenericInst, tyRange, tyVar, tyDistinct, tyOrdinal,
                    tyTypeDesc, tyAlias, tyInferred, tySink, tyOwned}
Source   Edit  
bodyPos = 6
Source   Edit  
callableDefs = {nkLambda..nkDo, nkProcDef..nkIteratorDef, nkFuncDef}
Source   Edit  
ConcreteTypes: TTypeKinds = {tyBool, tyChar, tyEnum, tyArray, tyObject, tySet,
                             tyTuple, tyRange, tyPtr, tyRef, tyVar, tyLent,
                             tySequence, tyProc, tyPointer, tyOpenArray,
                             tyString, tyCstring, tyInt..tyInt64,
                             tyFloat..tyFloat128, tyUInt..tyUInt64}
Source   Edit  
ConstantDataTypes: TTypeKinds = {tyArray, tySet, tyTuple, tySequence}
Source   Edit  
ctfeWhitelist = {mNone, mSucc, mPred, mInc, mDec, mOrd, mLengthOpenArray,
                 mLengthStr, mLengthArray, mLengthSeq, mArrGet, mArrPut, mAsgn,
                 mDestroy, mIncl, mExcl, mCard, mChr, mAddI, mSubI, mMulI,
                 mDivI, mModI, mAddF64, mSubF64, mMulF64, mDivF64, mShrI, mShlI,
                 mBitandI, mBitorI, mBitxorI, mMinI, mMaxI, mAddU, mSubU, mMulU,
                 mDivU, mModU, mEqI, mLeI, mLtI, mEqF64, mLeF64, mLtF64, mLeU,
                 mLtU, mEqEnum, mLeEnum, mLtEnum, mEqCh, mLeCh, mLtCh, mEqB,
                 mLeB, mLtB, mEqRef, mEqProc, mLePtr, mLtPtr, mEqCString, mXor,
                 mUnaryMinusI, mUnaryMinusI64, mAbsI, mNot, mUnaryPlusI,
                 mBitnotI, mUnaryPlusF64, mUnaryMinusF64, mCharToStr,
                 mBoolToStr, mCStrToStr, mStrToStr, mEnumToStr, mAnd, mOr,
                 mEqStr, mLeStr, mLtStr, mEqSet, mLeSet, mLtSet, mMulSet,
                 mPlusSet, mMinusSet, mXorSet, mConStrStr, mAppendStrCh,
                 mAppendStrStr, mAppendSeqElem, mInSet, mRepr, mOpenArrayToSeq}
Source   Edit  
declarativeDefs = {nkProcDef, nkFuncDef, nkMethodDef, nkIteratorDef,
                   nkConverterDef}
Source   Edit  
defaultOffset = -1
Source   Edit  
defaultSize = -1
Source   Edit  
dispatcherPos = 8
Source   Edit  
effectListLen = 6
Source   Edit  
ensuresEffects = 2
Source   Edit  
ExportableSymKinds = {skType..skConst, skProc..skTemplate, skEnumField, skStub}
Source   Edit  
GcTypeKinds = {tyRef, tySequence, tyString}
Source   Edit  
generatedMagics = {mNone, mIsolate, mFinished, mOpenArrayToSeq}
magics that are generated as normal procs in the backend Source   Edit  
GenericTypes: TTypeKinds = {tyGenericInvocation, tyGenericBody, tyGenericParam}
Source   Edit  
IntegralTypes = {tyBool, tyChar, tyEnum, tyInt..tyInt64, tyFloat..tyFloat128,
                 tyUInt..tyUInt64}
Source   Edit  
miscPos = 5
Source   Edit  
namePos = 0
Source   Edit  
nfAllFieldsSet = nfBase2
Source   Edit  
NilableTypes: TTypeKinds = {tyPointer, tyCstring, tyRef, tyPtr, tyProc, tyError}
Source   Edit  
nkEffectList = nkArgList
Source   Edit  
nkFloatLiterals = {nkFloatLit..nkFloat128Lit}
Source   Edit  
nkIdentKinds = {nkIdent, nkSym, nkAccQuoted, nkOpenSymChoice, nkClosedSymChoice,
                nkOpenSym}
Source   Edit  
nkLambdaKinds = {nkLambda, nkDo}
Source   Edit  
nkLastBlockStmts = {nkRaiseStmt, nkReturnStmt, nkBreakStmt, nkContinueStmt}
Source   Edit  
nkLiterals = {nkCharLit..nkTripleStrLit}
Source   Edit  
nkPragmaCallKinds = {nkExprColonExpr, nkCall, nkCallStrLit}
Source   Edit  
nkStrKinds = {nkStrLit..nkTripleStrLit}
Source   Edit  
nkSymChoices = {nkClosedSymChoice, nkOpenSymChoice}
Source   Edit  
nkWhen = nkWhenStmt
Source   Edit  
nkWhenExpr = nkWhenStmt
Source   Edit  
OverloadableSyms = {skProc, skFunc, skMethod, skIterator, skConverter, skModule,
                    skTemplate, skMacro, skEnumField}
Source   Edit  
paramsPos = 3
Source   Edit  
patternPos = 1
Source   Edit  
PersistentNodeFlags: TNodeFlags = {nfBase2, nfBase8, nfBase16, nfDotSetter,
                                   nfDotField, nfIsRef, nfIsPtr, nfPreventCg,
                                   nfLL, nfFromTemplate, nfDefaultRefsParam,
                                   nfExecuteOnReload, nfLastRead, nfFirstWrite,
                                   nfSkipFieldChecking, nfDisabledOpenSym}
Source   Edit  
pragmasEffects = 4
Source   Edit  
pragmasPos = 4
Source   Edit  
procDefs = {nkLambda..nkDo, nkProcDef..nkConverterDef, nkIteratorDef, nkFuncDef}
Source   Edit  
PtrLikeKinds: TTypeKinds = {tyPointer, tyPtr}
Source   Edit  
resultPos = 7
Source   Edit  
routineDefs = {nkProcDef..nkIteratorDef, nkFuncDef}
Source   Edit  
routineKinds = {skProc, skFunc, skMethod, skIterator, skConverter, skMacro,
                skTemplate}
Source   Edit  
sfCompileToCpp = sfInfixCall
Source   Edit  
sfCompileToObjc = sfNamedParamCall
Source   Edit  
sfCppMember = {sfVirtual, sfMember, sfConstructor}
Source   Edit  
sfExperimental = sfOverridden
Source   Edit  
sfNoForward = sfRegister
Source   Edit  
sfNoInit = sfMainModule
Source   Edit  
sfReorder = sfForward
Source   Edit  
sfWrittenTo = sfBorrow
Source   Edit  
skError = skUnknown
Source   Edit  
skLocalVars = {skVar, skLet, skForVar, skParam, skResult}
Source   Edit  
skProcKinds = {skProc, skFunc, skTemplate, skMacro, skIterator, skMethod,
               skConverter}
Source   Edit  
StructuralEquivTypes: TTypeKinds = {tyNil, tyTuple, tyArray, tySet, tyRange,
                                    tyPtr, tyRef, tyVar, tyLent, tySequence,
                                    tyProc, tyOpenArray, tyVarargs}
Source   Edit  
tagEffects = 3
Source   Edit  
tfGcSafe = tfThread
Source   Edit  
tfGenericHasDestructor = tfExplicitCallConv
tyGenericBody where an instance has a generated destructor Source   Edit  
tfNonConstExpr = tfExplicitCallConv
tyFromExpr where the expression shouldn't be evaluated as a static value Source   Edit  
tfObjHasKids = tfEnumHasHoles
Source   Edit  
tfReturnsNew = tfInheritable
Source   Edit  
tfUnion = tfNoSideEffect
Source   Edit  
tyMetaTypes = {tyUntyped, tyTypeDesc, tyGenericParam,
               tyBuiltInTypeClass..tyCompositeTypeClass, tyAnd..tyAnything,
               tyConcept}
Source   Edit  
tyPureObject = tyTuple
Source   Edit  
tyTypeClasses = {tyBuiltInTypeClass, tyCompositeTypeClass, tyUserTypeClass,
                 tyUserTypeClassInst, tyConcept, tyAnd, tyOr, tyNot, tyAnything}
Source   Edit  
tyUserTypeClasses = {tyUserTypeClass, tyUserTypeClassInst}
Source   Edit  

Procs

proc `$`(x: ItemId): string {....raises: [], tags: [], forbids: [].}
Source   Edit  
proc `==`(a, b: ItemId): bool {.inline, ...raises: [], tags: [], forbids: [].}
Source   Edit  
proc forcePartial(s: PSym) {....raises: [], tags: [], forbids: [].}
Resets all impl-fields to their default values and sets state to Partial. This is useful for creating a stub symbol that can be lazily loaded later. The fields itemId, name, and disamb are preserved. Source   Edit  
proc forcePartial(t: PType) {....raises: [], tags: [], forbids: [].}
Resets all impl-fields to their default values and sets state to Partial. This is useful for creating a stub type that can be lazily loaded later. The fields itemId, kind, uniqueId are preserved. Source   Edit  
proc hash(x: ItemId): Hash {....raises: [], tags: [], forbids: [].}
Source   Edit  
proc len(n: PNode): int {.inline, ...raises: [], tags: [], forbids: [].}
Source   Edit  
proc newIdentNode(ident: PIdent; info: TLineInfo): PNode {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
proc newNode(kind: TNodeKind): PNode {....raises: [], tags: [], forbids: [].}
new node with unknown line info, no type, and no children Source   Edit  
proc newNode(kind: TNodeKind; info: TLineInfo): PNode {....raises: [], tags: [],
    forbids: [].}
new node with line info, no type, and no children Source   Edit  
proc newNodeI(kind: TNodeKind; info: TLineInfo): PNode {....raises: [], tags: [],
    forbids: [].}
new node with line info, no type, and no children Source   Edit  
proc newNodeI(kind: TNodeKind; info: TLineInfo; children: int): PNode {.
    ...raises: [], tags: [], forbids: [].}
new node with line info, type, and children Source   Edit  
proc newNodeIT(kind: TNodeKind; info: TLineInfo; typ: PType): PNode {.
    ...raises: [], tags: [], forbids: [].}
new node with line info, type, and no children Source   Edit  
proc newSymNode(sym: PSym; info: TLineInfo): PNode {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
proc safeLen(n: PNode): int {.inline, ...raises: [], tags: [], forbids: [].}
works even for leaves. Source   Edit  

Iterators

iterator items(n: PNode): PNode {....raises: [], tags: [], forbids: [].}
Source   Edit  

Templates

template `[]`(n: PNode; i: BackwardsIndex): PNode
Source   Edit  
template `[]`(n: PNode; i: int): PNode
Source   Edit  
template `[]=`(n: PNode; i: BackwardsIndex; x: PNode)
Source   Edit  
template `[]=`(n: PNode; i: int; x: PNode)
Source   Edit