import type * as ts from 'typescript' ; import { Scope } from '../../scope/scope' ; import { GetDescriptor } from '../descriptor' ; import { TypescriptHelper } from '../helper/helper' ; import { GetUndefinedDescriptor } from '../undefined/undefined' ; import { core } from '../../core/core' ; export function GetIdentifierDescriptor ( node , scope ) { if ( node . originalKeywordKind && node . originalKeywordKind === core . ts . SyntaxKind . UndefinedKeyword ) { return GetUndefinedDescriptor ( ) ; } const declaration = TypescriptHelper . GetDeclarationFromNode ( node ) ; return GetDescriptor ( declaration , scope ) ; }