UNPKG

@neo-one/smart-contract-compiler

Version:

NEO•ONE TypeScript smart contract compiler.

27 lines (25 loc) 952 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RawIteratorForEachKeyHelper = void 0; const Helper_1 = require("../Helper"); class RawIteratorForEachKeyHelper extends Helper_1.Helper { constructor(options) { var _a; super(); this.each = options.each; this.deserializeKey = (_a = options.deserializeKey) !== null && _a !== void 0 ? _a : false; } emit(sb, node, options) { sb.emitHelper(node, options, sb.helpers.rawIteratorForEachBase({ each: (innerOptions) => { sb.emitSysCall(node, 'Neo.Iterator.Key'); if (this.deserializeKey) { sb.emitSysCall(node, 'Neo.Runtime.Deserialize'); } this.each(innerOptions); }, })); } } exports.RawIteratorForEachKeyHelper = RawIteratorForEachKeyHelper; //# sourceMappingURL=RawIteratorForEachKeyHelper.js.map