UNPKG

@neo-one/smart-contract-compiler

Version:

NEO•ONE TypeScript smart contract compiler.

18 lines (16 loc) 610 B
import { tsUtils } from '@neo-one/ts-utils'; import ts from 'typescript'; import { NodeCompiler } from '../NodeCompiler'; export class NoSubstitutionTemplateLiteralCompiler extends NodeCompiler { constructor() { super(...arguments); this.kind = ts.SyntaxKind.NoSubstitutionTemplateLiteral; } visitNode(sb, expr, options) { if (options.pushValue) { sb.emitPushString(expr, tsUtils.literal.getLiteralValue(expr)); sb.emitHelper(expr, options, sb.helpers.wrapString); } } } //# sourceMappingURL=NoSubstitutionTemplateLiteralCompiler.js.map