@glimmer/opcode-compiler
Advanced tools
Comparing version 0.32.2 to 0.32.3
@@ -34,2 +34,53 @@ 'use strict'; | ||
var _lazy = require('./lib/lazy'); | ||
Object.keys(_lazy).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _lazy[key]; | ||
} | ||
}); | ||
}); | ||
var _compile = require('./lib/compile'); | ||
Object.keys(_compile).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _compile[key]; | ||
} | ||
}); | ||
}); | ||
var _compiler = require('./lib/compiler'); | ||
Object.keys(_compiler).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _compiler[key]; | ||
} | ||
}); | ||
}); | ||
var _compilableTemplate = require('./lib/compilable-template'); | ||
Object.defineProperty(exports, 'CompilableBlock', { | ||
enumerable: true, | ||
get: function () { | ||
return _compilableTemplate.CompilableBlock; | ||
} | ||
}); | ||
Object.defineProperty(exports, 'CompilableProgram', { | ||
enumerable: true, | ||
get: function () { | ||
return _compilableTemplate.CompilableProgram; | ||
} | ||
}); | ||
var _opcodeBuilder = require('./lib/opcode-builder'); | ||
@@ -55,6 +106,6 @@ | ||
}); | ||
Object.defineProperty(exports, 'SimpleOpcodeBuilder', { | ||
Object.defineProperty(exports, 'StdOpcodeBuilder', { | ||
enumerable: true, | ||
get: function () { | ||
return _opcodeBuilder.SimpleOpcodeBuilder; | ||
return _opcodeBuilder.StdOpcodeBuilder; | ||
} | ||
@@ -81,11 +132,2 @@ }); | ||
var _compilableTemplate = require('./lib/compilable-template'); | ||
Object.defineProperty(exports, 'CompilableTemplate', { | ||
enumerable: true, | ||
get: function () { | ||
return _interopRequireDefault(_compilableTemplate).default; | ||
} | ||
}); | ||
var _debug = require('./lib/debug'); | ||
@@ -122,2 +164,2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YXgnO1xuXG5leHBvcnQgKiBmcm9tICcuL2xpYi9sYXp5JztcbmV4cG9ydCAqIGZyb20gJy4vbGliL2NvbXBpbGUnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvY29tcGlsZXInO1xuXG5leHBvcnQge1xuICBDb21waWxhYmxlQmxvY2ssXG4gIENvbXBpbGFibGVQcm9ncmFtXG59IGZyb20gJy4vbGliL2NvbXBpbGFibGUtdGVtcGxhdGUnO1xuXG5leHBvcnQge1xuICBMYXp5T3Bjb2RlQnVpbGRlcixcbiAgRWFnZXJPcGNvZGVCdWlsZGVyLFxuICBPcGNvZGVCdWlsZGVyLFxuICBPcGNvZGVCdWlsZGVyQ29uc3RydWN0b3IsXG4gIFN0ZE9wY29kZUJ1aWxkZXIsXG59IGZyb20gJy4vbGliL29wY29kZS1idWlsZGVyJztcblxuZXhwb3J0IHsgUGFydGlhbERlZmluaXRpb24gfSBmcm9tICcuL2xpYi9wYXJ0aWFsLXRlbXBsYXRlJztcblxuZXhwb3J0IHtcbiAgZGVmYXVsdCBhcyB0ZW1wbGF0ZUZhY3RvcnksXG4gIFRlbXBsYXRlRmFjdG9yeVxufSBmcm9tICcuL2xpYi90ZW1wbGF0ZSc7XG5cbmV4cG9ydCB7XG4gIGRlYnVnLFxuICBkZWJ1Z1NsaWNlLFxuICBsb2dPcGNvZGVcbn0gZnJvbSAnLi9saWIvZGVidWcnO1xuXG5leHBvcnQge1xuICBXcmFwcGVkQnVpbGRlcixcbn0gZnJvbSAnLi9saWIvd3JhcHBlZC1jb21wb25lbnQnO1xuIl19 |
@@ -1,2 +0,2 @@ | ||
'use strict'; | ||
"use strict"; | ||
@@ -6,24 +6,31 @@ Object.defineProperty(exports, "__esModule", { | ||
}); | ||
exports.PLACEHOLDER_HANDLE = undefined; | ||
var _debug = require('./debug'); | ||
var _syntax = require('./syntax'); | ||
const PLACEHOLDER_HANDLE = exports.PLACEHOLDER_HANDLE = -1; | ||
class CompilableTemplateImpl { | ||
constructor(statements, containingLayout, options, symbolTable) { | ||
this.statements = statements; | ||
this.containingLayout = containingLayout; | ||
this.options = options; | ||
this.symbolTable = symbolTable; | ||
class CompilableProgram { | ||
constructor(compiler, layout) { | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
this.compiled = null; | ||
this.statementCompiler = (0, _syntax.statementCompiler)(); | ||
} | ||
static topLevel(block, options) { | ||
return new CompilableTemplateImpl(block.statements, { block, referrer: options.referrer }, options, { hasEval: block.hasEval, symbols: block.symbols }); | ||
get symbolTable() { | ||
return this.layout.block; | ||
} | ||
compile(stdLib) { | ||
let { compiled } = this; | ||
if (compiled !== null) return compiled; | ||
compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
let { block: { statements } } = this.layout; | ||
return this.compiled = this.compiler.add(statements, this.layout); | ||
} | ||
} | ||
exports.CompilableProgram = CompilableProgram; | ||
class CompilableBlock { | ||
constructor(compiler, parsed) { | ||
this.compiler = compiler; | ||
this.parsed = parsed; | ||
this.compiled = null; | ||
} | ||
get symbolTable() { | ||
return this.parsed.block; | ||
} | ||
compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
// Track that compilation has started but not yet finished by temporarily | ||
@@ -34,20 +41,7 @@ // using a placeholder handle. In eager compilation mode, where compile() | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
let { options, statements, containingLayout } = this; | ||
let { referrer } = containingLayout; | ||
let { program, resolver, macros, asPartial, Builder } = options; | ||
let builder = new Builder(program, resolver, referrer, macros, containingLayout, asPartial, stdLib); | ||
for (let i = 0; i < statements.length; i++) { | ||
this.statementCompiler.compile(statements[i], builder); | ||
} | ||
let handle = builder.commit(program.heap, containingLayout.block.symbols.length); | ||
if (false) { | ||
let { heap } = program; | ||
let start = heap.getaddr(handle); | ||
let end = start + heap.sizeof(handle); | ||
(0, _debug.debugSlice)(program, start, end); | ||
} | ||
return this.compiled = handle; | ||
let { block: { statements }, containingLayout } = this.parsed; | ||
return this.compiled = this.compiler.add(statements, containingLayout); | ||
} | ||
} | ||
exports.default = CompilableTemplateImpl; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGlsYWJsZS10ZW1wbGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvY29tcGlsYWJsZS10ZW1wbGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7O0FBU0EsQUFBTyxBQUFFLEFBQVUsQUFBRSxBQUFNLEFBQVMsQUFBQzs7QUFFckMsQUFBTyxBQUFrQixBQUFpQixBQUFhLEFBQU0sQUFBVSxBQUFDLEFBRXhFLEFBQU07O0FBQUMsTUFBTSxBQUFrQixrREFBRyxDQUFDLEFBQUMsQUFBQyxBQUVyQyxBQUFNLEFBQUMsQUFBTzs7Z0JBY1EsQUFBdUIsWUFBVSxBQUE4QixrQkFBVSxBQUFxQyxTQUFTLEFBQXdCLGFBQS9JO2FBQVUsYUFBVixBQUFVLEFBQWEsQUFBVTthQUFnQixtQkFBaEIsQUFBZ0IsQUFBYyxBQUFVO2FBQU8sVUFBUCxBQUFPLEFBQThCLEFBQVM7YUFBVyxjQUo5SSxBQUltSSxBQUFXLEFBQWE7YUFKbkosV0FBbUIsQUFBSSxBQUFDLEFBS3RDLEFBQUk7YUFBQyxBQUFpQixvQkFBRyxBQUFpQixBQUFFLEFBQUMsQUFDL0MsQUFBQztBQWZELEFBQU07V0FBQyxBQUFRLFNBQWUsQUFBOEIsT0FBRSxBQUFxQyxTQUNqRyxBQUFNO2VBQUMsSUFBSSxBQUFzQix1QkFDL0IsQUFBSyxNQUFDLEFBQVUsWUFDaEIsRUFBRSxBQUFLLE9BQUUsQUFBUSxVQUFFLEFBQU8sUUFBQyxBQUFRLEFBQUUsWUFDckMsQUFBTyxTQUNQLEVBQUUs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cmVzb2x2ZXIsIHJlZmVycmVyLCBtYWNyb3MsIGNvbnRhaW5pbmdMYXlvdXQsIGFzUGFydGlhbCwgc3RkTGliKTtcblxuICAgIGZvciAobGV0IGkgPSAwOyBpIDwgc3RhdGVtZW50cy5sZW5ndGg7IGkrKykge1xuICAgICAgdGhpcy5zdGF0ZW1lbnRDb21waWxlci5jb21waWxlKHN0YXRlbWVudHNbaV0sIGJ1aWxkZXIpO1xuICAgIH1cblxuICAgIGxldCBoYW5kbGUgPSBidWlsZGVyLmNvbW1pdChwcm9ncmFtLmhlYXAsIGNvbnRhaW5pbmdMYXlvdXQuYmxvY2suc3ltYm9scy5sZW5ndGgpO1xuXG4gICAgaWYgKERFQlVHKSB7XG4gICAgICBsZXQgeyBoZWFwIH0gPSBwcm9ncmFtO1xuICAgICAgbGV0IHN0YXJ0ID0gaGVhcC5nZXRhZGRyKGhhbmRsZSk7XG4gICAgICBsZXQgZW5kID0gc3RhcnQgKyBoZWFwLnNpemVvZihoYW5kbGUpO1xuXG4gICAgICBkZWJ1Z1NsaWNlKHByb2dyYW0sIHN0YXJ0LCBlbmQpO1xuICAgIH1cblxuICAgIHJldHVybiAodGhpcy5jb21waWxlZCA9IGhhbmRsZSk7XG4gIH1cbn1cbiJdfQ== | ||
exports.CompilableBlock = CompilableBlock; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGlsYWJsZS10ZW1wbGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvY29tcGlsYWJsZS10ZW1wbGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7OztBQVlPLE1BQU0sQUFBa0Isa0RBQUcsQ0FBQyxBQUFDLEFBQUMsQUFFckMsQUFBTTs7Z0JBSVEsQUFBMEIsVUFDMUIsQUF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FjZWhvbGRlciBoYW5kbGUuIEluIGVhZ2VyIGNvbXBpbGF0aW9uIG1vZGUsIHdoZXJlIGNvbXBpbGUoKVxuICAgIC8vIG1heSBiZSBjYWxsZWQgcmVjdXJzaXZlbHksIHdlIHVzZSB0aGlzIGFzIGEgc2lnbmFsIHRoYXQgdGhlIGhhbmRsZSBjYW5ub3RcbiAgICAvLyBiZSBrbm93biBzeW5jaHJvbm91c2x5IGFuZCBtdXN0IGJlIGxpbmtlZCBsYXppbHkuXG4gICAgdGhpcy5jb21waWxlZCA9IFBMQUNFSE9MREVSX0hBTkRMRTtcblxuICAgIGxldCB7IGJsb2NrOiB7IHN0YXRlbWVudHMgfSwgY29udGFpbmluZ0xheW91dCB9ID0gdGhpcy5wYXJzZWQ7XG5cbiAgICByZXR1cm4gdGhpcy5jb21waWxlZCA9IHRoaXMuY29tcGlsZXIuYWRkKHN0YXRlbWVudHMsIGNvbnRhaW5pbmdMYXlvdXQpO1xuICB9XG59XG4iXX0= |
@@ -22,3 +22,3 @@ 'use strict'; | ||
let { type, op1, op2, op3, size } = program.opcode(i); | ||
let [name, params] = debug(constants, type, op1, op2, op3); | ||
let [name, params] = debug(i, constants, type, op1, op2, op3); | ||
console.log(`${i}. ${logOpcode(name, params)}`); | ||
@@ -61,3 +61,3 @@ _size = size; | ||
} | ||
function debug(c, op, ...operands) { | ||
function debug(pos, c, op, ...operands) { | ||
let metadata = null; | ||
@@ -71,2 +71,5 @@ if (!metadata) { | ||
switch (operand.type) { | ||
case 'to': | ||
out[operand.name] = pos + op; | ||
break; | ||
case 'i32': | ||
@@ -138,2 +141,2 @@ case 'symbol': | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL2RlYnVnLnRz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GNvbnN0YW50czogRGVidWdDb25zdGFudHMpOiBQcmltaXRpdmUge1xuICBsZXQgZmxhZyA9IHByaW1pdGl2ZSAmIDc7IC8vIDExMVxuICBsZXQgdmFsdWUgPSBwcmltaXRpdmUgPj4gMztcblxuICBzd2l0Y2ggKGZsYWcpIHtcbiAgICBjYXNlIFByaW1pdGl2ZVR5cGUuTlVNQkVSOlxuICAgICAgcmV0dXJuIHZhbHVlO1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5GTE9BVDpcbiAgICAgIHJldHVybiBjb25zdGFudHMuZ2V0TnVtYmVyKHZhbHVlKTtcbiAgICBjYXNlIFByaW1pdGl2ZVR5cGUuU1RSSU5HOlxuICAgICAgcmV0dXJuIGNvbnN0YW50cy5nZXRTdHJpbmcodmFsdWUpO1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5CT09MRUFOX09SX1ZPSUQ6XG4gICAgICBzd2l0Y2ggKHZhbHVlKSB7XG4gICAgICAgIGNhc2UgMDogcmV0dXJuIGZhbHNlO1xuICAgICAgICBjYXNlIDE6IHJldHVybiB0cnVlO1xuICAgICAgICBjYXNlIDI6IHJldHVybiBudWxsO1xuICAgICAgICBjYXNlIDM6IHJldHVybiB1bmRlZmluZWQ7XG4gICAgICB9XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLk5FR0FUSVZFOlxuICAgICAgcmV0dXJuIGNvbnN0YW50cy5nZXROdW1iZXIodmFsdWUpO1xuICAgIGRlZmF1bHQ6XG4gICAgICB0aHJvdyB1bnJlYWNoYWJsZSgpO1xuICB9XG59XG4iXX0= | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL2RlYnVnLnRzIl0sIm5hbWVzIjpbXSwibWFwcGlu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yYW5kLm5hbWVdID0gb3A7XG4gICAgICAgIGJyZWFrO1xuICAgICAgY2FzZSAnaGFuZGxlJzpcbiAgICAgICAgb3V0W29wZXJhbmQubmFtZV0gPSBjLnJlc29sdmVIYW5kbGUob3ApO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ3N0cic6XG4gICAgICAgIG91dFtvcGVyYW5kLm5hbWVdID0gYy5nZXRTdHJpbmcob3ApO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ29wdGlvbi1zdHInOlxuICAgICAgICBvdXRbb3BlcmFuZC5uYW1lXSA9IG9wID8gYy5nZXRTdHJpbmcob3ApIDogbnVsbDtcbiAgICAgICAgYnJlYWs7XG4gICAgICBjYXNlICdzdHItYXJyYXknOlxuICAgICAgICBvdXRbb3BlcmFuZC5uYW1lXSA9IGMuZ2V0U3RyaW5nQXJyYXkob3ApO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ2FycmF5JzpcbiAgICAgICAgb3V0W29wZXJhbmQubmFtZV0gPSBjLmdldEFycmF5KG9wKTtcbiAgICAgICAgYnJlYWs7XG4gICAgICBjYXNlICdib29sJzpcbiAgICAgICAgb3V0W29wZXJhbmQubmFtZV0gPSAhIW9wO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ3ByaW1pdGl2ZSc6XG4gICAgICAgIG91dFtvcGVyYW5kLm5hbWVdID0gZGVjb2RlUHJpbWl0aXZlKG9wLCBjKTtcbiAgICAgICAgYnJlYWs7XG4gICAgICBjYXNlICdyZWdpc3Rlcic6XG4gICAgICAgIG91dFtvcGVyYW5kLm5hbWVdID0gUmVnaXN0ZXJbb3BdO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ3NlcmlhbGl6YWJsZSc6XG4gICAgICAgIG91dFtvcGVyYW5kLm5hbWVdID0gYy5nZXRTZXJpYWxpemFibGUob3ApO1xuICAgICAgICBicmVhaztcbiAgICAgIGNhc2UgJ2xhenktY29uc3RhbnQ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kZWZhdWx0OlxuICAgICAgdGhyb3cgdW5yZWFjaGFibGUoKTtcbiAgfVxufVxuIl19 |
@@ -7,2 +7,2 @@ "use strict"; | ||
const PLACEHOLDER_HANDLE = exports.PLACEHOLDER_HANDLE = -1; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZXJmYWNlcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvaW50ZXJmYWNlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7OztBQW9CTyxNQUFNLEFBQWtCLGtEQUFHLENBQUMsQUFBQyxBQUFDIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHtcbiAgT3BhcXVlLFxuICBPcHRpb24sXG4gIENvbXBpbGFibGVCbG9jayxcbiAgQ29tcG9uZW50Q2FwYWJpbGl0aWVzLFxuICBDb21waWxlVGltZVByb2dyYW0sXG59IGZyb20gJ0BnbGltbWVyL2ludGVyZmFjZXMnO1xuaW1wb3J0IHsgQ29yZSwgU2VyaWFsaXplZFRlbXBsYXRlQmxvY2sgfSBmcm9tICdAZ2xpbW1lci93aXJlLWZvcm1hdCc7XG5pbXBvcnQgeyBNYWNyb3MgfSBmcm9tICcuL3N5bnRheCc7XG5cbmV4cG9ydCBpbnRlcmZhY2UgRWFnZXJSZXNvbHZlcjxMb2NhdG9yPiB7XG4gIGdldENhcGFiaWxpdGllcyhsb2NhdG9yOiBMb2NhdG9yKTogQ29tcG9uZW50Q2FwYWJpbGl0aWVzO1xufVxuXG5leHBvcnQgaW50ZXJmYWNlIEVhZ2VyQ29tcGlsYXRpb25PcHRpb25zPFRlbXBsYXRlTWV0YSwgUiBleHRlbmRzIEVhZ2VyUmVzb2x2ZXI8VGVtcGxhdGVNZXRhPj4ge1xuICByZXNvbHZlcjogUjtcb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G4gIENvbXBvbmVudENhcGFiaWxpdGllcyxcbiAgQ29tcGlsZVRpbWVQcm9ncmFtLFxufSBmcm9tICdAZ2xpbW1lci9pbnRlcmZhY2VzJztcbmltcG9ydCB7IENvcmUgfSBmcm9tICdAZ2xpbW1lci93aXJlLWZvcm1hdCc7XG5pbXBvcnQgeyBNYWNyb3MgfSBmcm9tICcuL3N5bnRheCc7XG5cbmV4cG9ydCBpbnRlcmZhY2UgRWFnZXJSZXNvbHZlcjxMb2NhdG9yPiB7XG4gIGdldENhcGFiaWxpdGllcyhsb2NhdG9yOiBMb2NhdG9yKTogQ29tcG9uZW50Q2FwYWJpbGl0aWVzO1xufVxuXG5leHBvcnQgaW50ZXJmYWNlIEVhZ2VyQ29tcGlsYXRpb25PcHRpb25zPExvY2F0b3IsIFIgZXh0ZW5kcyBFYWdlclJlc29sdmVyPExvY2F0b3I+PiB7XG4gIHJlc29sdmVyOiBSO1xuICBwcm9ncmFtOiBDb21waWxlVGltZVByb2dyYW07XG4gIG1hY3JvczogTWFjcm9zO1xufVxuXG5leHBvcnQgY29uc3QgUExBQ0VIT0xERVJfSEFORExFID0gLTE7XG5cbmV4cG9ydCB0eXBlIFByaW1pdGl2ZSA9IHVuZGVmaW5lZCB8IG51bGwgfCBib29sZWFuIHwgbnVtYmVyIHwgc3RyaW5nO1xuXG5leHBvcnQgdHlwZSBDb21wb25lbnRBcmdzID0gW0NvcmUuUGFyYW1zLCBDb3JlLkhhc2gsIE9wdGlvbjxDb21waWxhYmxlQmxvY2s+LCBPcHRpb248Q29tcGlsYWJsZUJsb2NrPl07XG5cbmV4cG9ydCBpbnRlcmZhY2UgQ29tcG9uZW50QnVpbGRlciB7XG4gIHN0YXRpYyhkZWZpbml0aW9uOiBudW1iZXIsIGFyZ3M6IENvbXBvbmVudEFyZ3MpOiB2b2lkO1xufVxuIl19 |
@@ -7,3 +7,2 @@ 'use strict'; | ||
exports.default = templateFactory; | ||
exports.compilable = compilable; | ||
@@ -14,8 +13,4 @@ var _util = require('@glimmer/util'); | ||
var _compilableTemplate2 = _interopRequireDefault(_compilableTemplate); | ||
var _wrappedComponent = require('./wrapped-component'); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
let clientId = 0; | ||
@@ -25,3 +20,3 @@ function templateFactory({ id: templateId, meta, block }) { | ||
let id = templateId || `client-${clientId++}`; | ||
let create = (options, envMeta) => { | ||
let create = (compiler, envMeta) => { | ||
let newMeta = envMeta ? (0, _util.assign)({}, envMeta, meta) : meta; | ||
@@ -31,3 +26,3 @@ if (!parsedBlock) { | ||
} | ||
return new TemplateImpl(options, { id, block: parsedBlock, referrer: newMeta }); | ||
return new TemplateImpl(compiler, { id, block: parsedBlock, referrer: newMeta }); | ||
}; | ||
@@ -37,4 +32,4 @@ return { id, meta, create }; | ||
class TemplateImpl { | ||
constructor(options, parsedLayout) { | ||
this.options = options; | ||
constructor(compiler, parsedLayout) { | ||
this.compiler = compiler; | ||
this.parsedLayout = parsedLayout; | ||
@@ -47,3 +42,2 @@ this.layout = null; | ||
this.hasEval = block.hasEval; | ||
this.statements = block.statements; | ||
this.referrer = parsedLayout.referrer; | ||
@@ -54,23 +48,13 @@ this.id = parsedLayout.id || `client-${clientId++}`; | ||
if (this.layout) return this.layout; | ||
return this.layout = compilable(this.parsedLayout, this.options, false); | ||
return this.layout = new _compilableTemplate.CompilableProgram(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
} | ||
asPartial() { | ||
if (this.partial) return this.partial; | ||
return this.partial = compilable(this.parsedLayout, this.options, true); | ||
return this.layout = new _compilableTemplate.CompilableProgram(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: true })); | ||
} | ||
asWrappedLayout() { | ||
if (this.wrappedLayout) return this.wrappedLayout; | ||
let compileOptions = (0, _util.assign)({}, this.options, { | ||
asPartial: false, | ||
referrer: this.referrer | ||
}); | ||
return this.wrappedLayout = new _wrappedComponent.WrappedBuilder(compileOptions, this.parsedLayout); | ||
return this.wrappedLayout = new _wrappedComponent.WrappedBuilder(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
} | ||
} | ||
function compilable(layout, options, asPartial) { | ||
let { block, referrer } = layout; | ||
let { hasEval, symbols } = block; | ||
let compileOptions = (0, _util.assign)({}, options, { asPartial, referrer }); | ||
return new _compilableTemplate2.default(block.statements, layout, compileOptions, { referrer, hasEval, symbols }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGVtcGxhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3RlbXBsYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7O0FBQ0EsQUFBTyxBQUFFLEFBQU0sQUFBRSxBQUFNLEFBQWUsQUFBQzs7QUFNdkMsQUFBTyxBQUFrQixBQUFNLEFBQXVCLEFBQUM7Ozs7QUFFdkQsQUFBTyxBQUFFLEFBQWMsQUFBRSxBQUFNLEFBQXFCLEFBQUM7Ozs7QUFnQ3JELElBQUksQUFBUSxXQUFHLEFBQUMsQUFBQyxBQVNqQixBQUFNLEFBQUMsQUFBTzt5QkFBMEIsRUFBRSxBQUFFLElBQUUsQUFBVSxZQUFFLEFBQUksTUFBRSxBQUFLLEFBQXdDLFNBQzNHO1FBQUksQUFBb0MsQUFBQyxBQUN6QztRQUFJLEFBQUUsS0FBRyxBQUFVLEFBQUksd0JBQVUsQUFBUSxBQUFFLEFBQUUsQUFBQyxVQUM5QztRQUFJLEFBQU0sU0FBRyxDQUFDLEFBQWdDLFNBQUUsQUFBWSxZQUMxRDtZQUFJLEFBQU8sVUFBRyxBQUFPLFVBQUcsQUFBTSxrQkFBQyxBQUFFLElBQUUsQUFBTyxTQUFFLEFBQUksQUFBQyxRQUFHLEFBQUksQUFBQyxBQUN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WxhYmxlUHJvZ3JhbUluc3RhbmNlKHRoaXMuY29tcGlsZXIsIHsgLi4udGhpcy5wYXJzZWRMYXlvdXQsIGFzUGFydGlhbDogZmFsc2UgfSk7XG4gIH1cblxuICBhc1BhcnRpYWwoKTogQ29tcGlsYWJsZVByb2dyYW0ge1xuICAgIGlmICh0aGlzLnBhcnRpYWwpIHJldHVybiB0aGlzLnBhcnRpYWw7XG4gICAgcmV0dXJuIHRoaXMubGF5b3V0ID0gbmV3IENvbXBpbGFibGVQcm9ncmFtSW5zdGFuY2UodGhpcy5jb21waWxlciwgeyAuLi50aGlzLnBhcnNlZExheW91dCwgYXNQYXJ0aWFsOiB0cnVlIH0pO1xuICB9XG5cbiAgYXNXcmFwcGVkTGF5b3V0KCk6IENvbXBpbGFibGVQcm9ncmFtIHtcbiAgICBpZiAodGhpcy53cmFwcGVkTGF5b3V0KSByZXR1cm4gdGhpcy53cmFwcGVkTGF5b3V0O1xuICAgIHJldHVybiB0aGlzLndyYXBwZWRMYXlvdXQgPSBuZXcgV3JhcHBlZEJ1aWxkZXIodGhpcy5jb21waWxlciwgeyAuLi50aGlzLnBhcnNlZExheW91dCwgYXNQYXJ0aWFsOiBmYWxzZSB9KTtcbiAgfVxufVxuIl19 |
@@ -10,8 +10,6 @@ 'use strict'; | ||
var _compiler = require('./compiler'); | ||
var _compilableTemplate = require('./compilable-template'); | ||
var _compilableTemplate2 = _interopRequireDefault(_compilableTemplate); | ||
var _debug = require('./debug'); | ||
var _syntax = require('./syntax'); | ||
@@ -21,7 +19,5 @@ | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
class WrappedBuilder { | ||
constructor(options, layout) { | ||
this.options = options; | ||
constructor(compiler, layout) { | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
@@ -62,6 +58,4 @@ let { block } = layout; | ||
// Exit | ||
let { options, layout, referrer } = this; | ||
let { program, resolver, macros, asPartial } = options; | ||
let { Builder } = options; | ||
let b = new Builder(program, resolver, referrer, macros, layout, asPartial); | ||
let { compiler, layout } = this; | ||
let b = compiler.builderFor(layout); | ||
b.startLabels(); | ||
@@ -80,3 +74,3 @@ b.fetch(_vm.Register.s1); | ||
b.label('BODY'); | ||
b.invokeStaticBlock(blockFor(layout, this.options)); | ||
b.invokeStaticBlock(blockFor(layout, compiler)); | ||
b.fetch(_vm.Register.s1); | ||
@@ -88,8 +82,5 @@ b.jumpUnless('END'); | ||
b.stopLabels(); | ||
let handle = b.commit(options.program.heap, layout.block.symbols.length); | ||
let handle = b.commit(); | ||
if (false) { | ||
let { program, program: { heap } } = options; | ||
let start = heap.getaddr(handle); | ||
let end = start + heap.sizeof(handle); | ||
(0, _debug.debugSlice)(program, start, end); | ||
(0, _compiler.debug)(compiler, handle); | ||
} | ||
@@ -100,5 +91,10 @@ return handle; | ||
exports.WrappedBuilder = WrappedBuilder; | ||
function blockFor(layout, options) { | ||
let { block, referrer } = layout; | ||
return new _compilableTemplate2.default(block.statements, layout, options, { referrer, parameters: _util.EMPTY_ARRAY }); | ||
function blockFor(layout, compiler) { | ||
return new _compilableTemplate.CompilableBlock(compiler, { | ||
block: { | ||
statements: layout.block.statements, | ||
parameters: _util.EMPTY_ARRAY | ||
}, | ||
containingLayout: layout | ||
}); | ||
} | ||
@@ -112,9 +108,7 @@ class ComponentBuilder { | ||
let { builder } = this; | ||
let { resolver } = builder; | ||
if (handle !== null) { | ||
let capabilities = resolver.getCapabilities(handle); | ||
if (capabilities.dynamicLayout === false) { | ||
let layout = resolver.getLayout(handle); | ||
let { capabilities, compilable } = builder.compiler.resolveLayoutForHandle(handle); | ||
if (compilable) { | ||
builder.pushComponentDefinition(handle); | ||
builder.invokeStaticComponent(capabilities, layout, null, params, hash, false, _default, inverse); | ||
builder.invokeStaticComponent(capabilities, compilable, null, params, hash, false, _default, inverse); | ||
} else { | ||
@@ -128,2 +122,2 @@ builder.pushComponentDefinition(handle); | ||
exports.ComponentBuilder = ComponentBuilder; | ||
//# sourceMappingURL=data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4gICAgaWYgKGhhbmRsZSAhPT0gbnVsbCkge1xuICAgICAgbGV0IGNhcGFiaWxpdGllcyA9IHJlc29sdmVyLmdldENhcGFiaWxpdGllcyhoYW5kbGUpO1xuXG4gICAgICBpZiAoY2FwYWJpbGl0aWVzLmR5bmFtaWNMYXlvdXQgPT09IGZhbHNlKSB7XG4gICAgICAgIGxldCBsYXlvdXQgPSByZXNvbHZlci5nZXRMYXlvdXQoaGFuZGxlKSE7XG5cbiAgICAgICAgYnVpbGRlci5wdXNoQ29tcG9uZW50RGVmaW5pdGlvbihoYW5kbGUpO1xuICAgICAgICBidWlsZGVyLmludm9rZVN0YXRpY0NvbXBvbmVudChjYXBhYmlsaXRpZXMsIGxheW91dCwgbnVsbCwgcGFyYW1zLCBoYXNoLCBmYWxzZSwgX2RlZmF1bHQsIGludmVyc2UpO1xuICAgICAgfSBlbHNlIHtcbiAgICAgICAgYnVpbGRlci5wdXNoQ29tcG9uZW50RGVmaW5pdGlvbihoYW5kbGUpO1xuICAgICAgICBidWlsZGVyLmludm9rZUNvbXBvbmVudChudWxsLCBwYXJhbXMsIGhhc2gsIGZhbHNlLCBfZGVmYXVsdCwgaW52ZXJzZSk7XG4gICAgICB9XG4gICAgfVxuICB9XG59XG4iXX0= | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3dyYXBwZWQtY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7QUFBQSxBQUFPLEFBQUUsQUFBUSxBQUFFLEFBQU0sQUFBYSxBQUFDOztBQVF2QyxBQUFPLEFBQUUsQUFBSyxBQUF1QixBQUFNLEFBQVksQUFBQzs7QUFDeEQsQUFBTyx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ICAgICAgICBidWlsZGVyLnB1c2hDb21wb25lbnREZWZpbml0aW9uKGhhbmRsZSk7XG4gICAgICAgIGJ1aWxkZXIuaW52b2tlQ29tcG9uZW50KG51bGwsIHBhcmFtcywgaGFzaCwgZmFsc2UsIF9kZWZhdWx0LCBpbnZlcnNlKTtcbiAgICAgIH1cbiAgICB9XG4gIH1cbn1cbiJdfQ== |
@@ -34,2 +34,53 @@ 'use strict'; | ||
var _lazy = require('./lib/lazy'); | ||
Object.keys(_lazy).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _lazy[key]; | ||
} | ||
}); | ||
}); | ||
var _compile = require('./lib/compile'); | ||
Object.keys(_compile).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _compile[key]; | ||
} | ||
}); | ||
}); | ||
var _compiler = require('./lib/compiler'); | ||
Object.keys(_compiler).forEach(function (key) { | ||
if (key === "default" || key === "__esModule") return; | ||
Object.defineProperty(exports, key, { | ||
enumerable: true, | ||
get: function () { | ||
return _compiler[key]; | ||
} | ||
}); | ||
}); | ||
var _compilableTemplate = require('./lib/compilable-template'); | ||
Object.defineProperty(exports, 'CompilableBlock', { | ||
enumerable: true, | ||
get: function () { | ||
return _compilableTemplate.CompilableBlock; | ||
} | ||
}); | ||
Object.defineProperty(exports, 'CompilableProgram', { | ||
enumerable: true, | ||
get: function () { | ||
return _compilableTemplate.CompilableProgram; | ||
} | ||
}); | ||
var _opcodeBuilder = require('./lib/opcode-builder'); | ||
@@ -55,6 +106,6 @@ | ||
}); | ||
Object.defineProperty(exports, 'SimpleOpcodeBuilder', { | ||
Object.defineProperty(exports, 'StdOpcodeBuilder', { | ||
enumerable: true, | ||
get: function () { | ||
return _opcodeBuilder.SimpleOpcodeBuilder; | ||
return _opcodeBuilder.StdOpcodeBuilder; | ||
} | ||
@@ -81,11 +132,2 @@ }); | ||
var _compilableTemplate = require('./lib/compilable-template'); | ||
Object.defineProperty(exports, 'CompilableTemplate', { | ||
enumerable: true, | ||
get: function () { | ||
return _interopRequireDefault(_compilableTemplate).default; | ||
} | ||
}); | ||
var _debug = require('./lib/debug'); | ||
@@ -122,2 +164,2 @@ | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7QUFBQSxBQUFjLEFBQWtCLEFBQUMsQUFFakMsQUFBTzs7Ozs7Ozs7Ozs7Ozs7O21CQUNMLEFBQVc7Ozs7OzttQkFFWCxBQUFNLEFBRVAsQUFBTSxBQUFjLEFBQUMsQUFFdEIsQUFBTzs7Ozs7Ozs7OzBCQUVMLEFBQWlCOzs7Ozs7MEJBQ2pCLEFBQWtCOzs7Ozs7MEJBQ2xCLEFBQWE7Ozs7OzswQkFFYixBQUFtQixBQUNwQixBQUFNLEFBQXNCLEFBQUMsQUFFOUIsQUFBTzs7Ozs7Ozs7OzRCQUFFLEFBQWlCLEFBQUUsQUFBTSxBQUF3QixBQUFDLEFBRTNELEFBQU87Ozs7Ozs7Ozs2Q0FDTCxBQUFPLEFBQUksQUFBZSxBQUUzQixBQUFNLEFBQWdCLEFBQUMsQUFFeEIsQUFBTzs7Ozs7Ozs7O3VEQUNMLEFBQU8sQUFBSSxBQUFrQixBQUM5QixBQUFNLEFBQTJCLEFBQUMsQUFFbkMsQUFBTzs7Ozs7Ozs7O2tCQUNMLEFBQUs7Ozs7OztrQkFDTCxBQUFVOzs7Ozs7a0JBQ1YsQUFBUyxBQUNWLEFB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Object.defineProperty(exports, "__esModule", { | ||
}); | ||
exports.PLACEHOLDER_HANDLE = undefined; | ||
var _createClass = function () { | ||
function defineProperties(target, props) { | ||
for (var i = 0; i < props.length; i++) { | ||
var descriptor = props[i];descriptor.enumerable = descriptor.enumerable || false;descriptor.configurable = true;if ("value" in descriptor) descriptor.writable = true;Object.defineProperty(target, descriptor.key, descriptor); | ||
} | ||
}return function (Constructor, protoProps, staticProps) { | ||
if (protoProps) defineProperties(Constructor.prototype, protoProps);if (staticProps) defineProperties(Constructor, staticProps);return Constructor; | ||
}; | ||
}(); | ||
var _debug = require('./debug'); | ||
var _syntax = require('./syntax'); | ||
function _classCallCheck(instance, Constructor) { | ||
@@ -20,23 +24,39 @@ if (!(instance instanceof Constructor)) { | ||
var PLACEHOLDER_HANDLE = exports.PLACEHOLDER_HANDLE = -1; | ||
var CompilableProgram = exports.CompilableProgram = function () { | ||
function CompilableProgram(compiler, layout) { | ||
_classCallCheck(this, CompilableProgram); | ||
var CompilableTemplateImpl = function () { | ||
function CompilableTemplateImpl(statements, containingLayout, options, symbolTable) { | ||
_classCallCheck(this, CompilableTemplateImpl); | ||
this.statements = statements; | ||
this.containingLayout = containingLayout; | ||
this.options = options; | ||
this.symbolTable = symbolTable; | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
this.compiled = null; | ||
this.statementCompiler = (0, _syntax.statementCompiler)(); | ||
} | ||
CompilableTemplateImpl.topLevel = function topLevel(block, options) { | ||
return new CompilableTemplateImpl(block.statements, { block: block, referrer: options.referrer }, options, { hasEval: block.hasEval, symbols: block.symbols }); | ||
CompilableProgram.prototype.compile = function compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
var statements = this.layout.block.statements; | ||
return this.compiled = this.compiler.add(statements, this.layout); | ||
}; | ||
CompilableTemplateImpl.prototype.compile = function compile(stdLib) { | ||
var compiled = this.compiled; | ||
_createClass(CompilableProgram, [{ | ||
key: "symbolTable", | ||
get: function get() { | ||
return this.layout.block; | ||
} | ||
}]); | ||
if (compiled !== null) return compiled; | ||
return CompilableProgram; | ||
}(); | ||
var CompilableBlock = exports.CompilableBlock = function () { | ||
function CompilableBlock(compiler, parsed) { | ||
_classCallCheck(this, CompilableBlock); | ||
this.compiler = compiler; | ||
this.parsed = parsed; | ||
this.compiled = null; | ||
} | ||
CompilableBlock.prototype.compile = function compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
// Track that compilation has started but not yet finished by temporarily | ||
@@ -47,31 +67,18 @@ // using a placeholder handle. In eager compilation mode, where compile() | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
var options = this.options, | ||
statements = this.statements, | ||
containingLayout = this.containingLayout; | ||
var referrer = containingLayout.referrer; | ||
var program = options.program, | ||
resolver = options.resolver, | ||
macros = options.macros, | ||
asPartial = options.asPartial, | ||
Builder = options.Builder; | ||
var _parsed = this.parsed, | ||
statements = _parsed.block.statements, | ||
containingLayout = _parsed.containingLayout; | ||
var builder = new Builder(program, resolver, referrer, macros, containingLayout, asPartial, stdLib); | ||
for (var i = 0; i < statements.length; i++) { | ||
this.statementCompiler.compile(statements[i], builder); | ||
} | ||
var handle = builder.commit(program.heap, containingLayout.block.symbols.length); | ||
if (false) { | ||
var heap = program.heap; | ||
return this.compiled = this.compiler.add(statements, containingLayout); | ||
}; | ||
var start = heap.getaddr(handle); | ||
var end = start + heap.sizeof(handle); | ||
(0, _debug.debugSlice)(program, start, end); | ||
_createClass(CompilableBlock, [{ | ||
key: "symbolTable", | ||
get: function get() { | ||
return this.parsed.block; | ||
} | ||
return this.compiled = handle; | ||
}; | ||
}]); | ||
return CompilableTemplateImpl; | ||
return CompilableBlock; | ||
}(); | ||
exports.default = CompilableTemplateImpl; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGlsYWJsZS10ZW1wbGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy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LyBtYXkgYmUgY2FsbGVkIHJlY3Vyc2l2ZWx5LCB3ZSB1c2UgdGhpcyBhcyBhIHNpZ25hbCB0aGF0IHRoZSBoYW5kbGUgY2Fubm90XG4gICAgLy8gYmUga25vd24gc3luY2hyb25vdXNseSBhbmQgbXVzdCBiZSBsaW5rZWQgbGF6aWx5LlxuICAgIHRoaXMuY29tcGlsZWQgPSBQTEFDRUhPTERFUl9IQU5ETEU7XG5cbiAgICBsZXQgeyBibG9jazogeyBzdGF0ZW1lbnRzIH0sIGNvbnRhaW5pbmdMYXlvdXQgfSA9IHRoaXMucGFyc2VkO1xuXG4gICAgcmV0dXJuIHRoaXMuY29tcGlsZWQgPSB0aGlzLmNvbXBpbGVyLmFkZChzdGF0ZW1lbnRzLCBjb250YWluaW5nTGF5b3V0KTtcbiAgfVxufVxuIl19 |
@@ -29,3 +29,3 @@ 'use strict'; | ||
var _debug = debug(constants, type, op1, op2, op3), | ||
var _debug = debug(i, constants, type, op1, op2, op3), | ||
name = _debug[0], | ||
@@ -73,5 +73,5 @@ params = _debug[1]; | ||
} | ||
function debug(c, op) { | ||
for (var _len = arguments.length, operands = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { | ||
operands[_key - 2] = arguments[_key]; | ||
function debug(pos, c, op) { | ||
for (var _len = arguments.length, operands = Array(_len > 3 ? _len - 3 : 0), _key = 3; _key < _len; _key++) { | ||
operands[_key - 3] = arguments[_key]; | ||
} | ||
@@ -87,2 +87,5 @@ | ||
switch (operand.type) { | ||
case 'to': | ||
out[operand.name] = pos + op; | ||
break; | ||
case 'i32': | ||
@@ -154,2 +157,2 @@ case 'symbol': | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL2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mRlZmluZWQ7XG4gICAgICB9XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLk5FR0FUSVZFOlxuICAgICAgcmV0dXJuIGNvbnN0YW50cy5nZXROdW1iZXIodmFsdWUpO1xuICAgIGRlZmF1bHQ6XG4gICAgICB0aHJvdyB1bnJlYWNoYWJsZSgpO1xuICB9XG59XG4iXX0= |
@@ -7,2 +7,2 @@ "use strict"; | ||
var PLACEHOLDER_HANDLE = exports.PLACEHOLDER_HANDLE = -1; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZXJmYWNlcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvaW50ZXJmYWNlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7OztBQW9CTyxJQUFNLEFBQWtCLGtEQUFHLENBQUMsQUFBQyxBQUFDIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHtcbiAgT3BhcXVlLFxuICBPcHRpb24sXG4gIENvbXBpbGFibGVCbG9jayxcbiAgQ29tcG9uZW50Q2FwYWJpbGl0aWVzLFxuICBDb21waWxlVGltZVByb2dyYW0sXG59IGZyb20gJ0BnbGltbWVyL2ludGVyZmFjZXMnO1xuaW1wb3J0IHsgQ29yZSwgU2VyaWFsaXplZFRlbXBsYXRlQmxvY2sgfSBmcm9tICdAZ2xpbW1lci93aXJlLWZvcm1hdCc7XG5pbXBvcnQgeyBNYWNyb3MgfSBmcm9tICcuL3N5bnRheCc7XG5cbmV4cG9ydCBpbnRlcmZhY2UgRWFnZXJSZXNvbHZlcjxMb2NhdG9yPiB7XG4gIGdldENhcGFiaWxpdGllcyhsb2NhdG9yOiBMb2NhdG9yKTogQ29tcG9uZW50Q2FwYWJpbGl0aWVzO1xufVxuXG5leHBvcnQgaW50ZXJmYWNlI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iZXIsIGFyZ3M6IENvbXBvbmVudEFyZ3MpOiB2b2lkO1xufVxuIl19 |
@@ -7,3 +7,2 @@ 'use strict'; | ||
exports.default = templateFactory; | ||
exports.compilable = compilable; | ||
@@ -14,8 +13,4 @@ var _util = require('@glimmer/util'); | ||
var _compilableTemplate2 = _interopRequireDefault(_compilableTemplate); | ||
var _wrappedComponent = require('./wrapped-component'); | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
function _classCallCheck(instance, Constructor) { | ||
@@ -35,3 +30,3 @@ if (!(instance instanceof Constructor)) { | ||
var id = templateId || 'client-' + clientId++; | ||
var create = function create(options, envMeta) { | ||
var create = function create(compiler, envMeta) { | ||
var newMeta = envMeta ? (0, _util.assign)({}, envMeta, meta) : meta; | ||
@@ -41,3 +36,3 @@ if (!parsedBlock) { | ||
} | ||
return new TemplateImpl(options, { id: id, block: parsedBlock, referrer: newMeta }); | ||
return new TemplateImpl(compiler, { id: id, block: parsedBlock, referrer: newMeta }); | ||
}; | ||
@@ -48,6 +43,6 @@ return { id: id, meta: meta, create: create }; | ||
var TemplateImpl = function () { | ||
function TemplateImpl(options, parsedLayout) { | ||
function TemplateImpl(compiler, parsedLayout) { | ||
_classCallCheck(this, TemplateImpl); | ||
this.options = options; | ||
this.compiler = compiler; | ||
this.parsedLayout = parsedLayout; | ||
@@ -61,3 +56,2 @@ this.layout = null; | ||
this.hasEval = block.hasEval; | ||
this.statements = block.statements; | ||
this.referrer = parsedLayout.referrer; | ||
@@ -69,3 +63,3 @@ this.id = parsedLayout.id || 'client-' + clientId++; | ||
if (this.layout) return this.layout; | ||
return this.layout = compilable(this.parsedLayout, this.options, false); | ||
return this.layout = new _compilableTemplate.CompilableProgram(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
}; | ||
@@ -75,3 +69,3 @@ | ||
if (this.partial) return this.partial; | ||
return this.partial = compilable(this.parsedLayout, this.options, true); | ||
return this.layout = new _compilableTemplate.CompilableProgram(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: true })); | ||
}; | ||
@@ -81,7 +75,3 @@ | ||
if (this.wrappedLayout) return this.wrappedLayout; | ||
var compileOptions = (0, _util.assign)({}, this.options, { | ||
asPartial: false, | ||
referrer: this.referrer | ||
}); | ||
return this.wrappedLayout = new _wrappedComponent.WrappedBuilder(compileOptions, this.parsedLayout); | ||
return this.wrappedLayout = new _wrappedComponent.WrappedBuilder(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
}; | ||
@@ -91,12 +81,2 @@ | ||
}(); | ||
function compilable(layout, options, asPartial) { | ||
var block = layout.block, | ||
referrer = layout.referrer; | ||
var hasEval = block.hasEval, | ||
symbols = block.symbols; | ||
var compileOptions = (0, _util.assign)({}, options, { asPartial: asPartial, referrer: referrer }); | ||
return new _compilableTemplate2.default(block.statements, layout, compileOptions, { referrer: referrer, hasEval: hasEval, symbols: symbols }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGVtcGxhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3RlbXBsYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7O0FBQ0EsQUFBTyxBQUFFLEFBQU0sQUFBRSxBQUFNLEFBQWUsQUFBQzs7QUFNdkMsQUFBTyxBQUFrQixBQUFNLEFBQXVCLEFBQUM7Ozs7QUFFdkQsQUFBTyxBQUFFLEFBQWMsQUFBRSxBQUFNLEFBQXFCLEFBQUM7Ozs7Ozs7Ozs7QUFnQ3JELElBQUksQUFBUSxXQUFHLEFBQUMsQUFBQyxBQVNqQixBQUFNLEFBQUMsQUFBTztTQUEwQixzQkFDdEM7UUFENEMsQUFBVSxrQkFBZCxBQUFFO1FBQWMsQUFBSTtRQUFFLEFBQ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+10,6 @@ 'use strict'; | ||
var _compiler = require('./compiler'); | ||
var _compilableTemplate = require('./compilable-template'); | ||
var _compilableTemplate2 = _interopRequireDefault(_compilableTemplate); | ||
var _debug = require('./debug'); | ||
var _syntax = require('./syntax'); | ||
@@ -21,4 +19,2 @@ | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
function _classCallCheck(instance, Constructor) { | ||
@@ -31,6 +27,6 @@ if (!(instance instanceof Constructor)) { | ||
var WrappedBuilder = exports.WrappedBuilder = function () { | ||
function WrappedBuilder(options, layout) { | ||
function WrappedBuilder(compiler, layout) { | ||
_classCallCheck(this, WrappedBuilder); | ||
this.options = options; | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
@@ -73,12 +69,6 @@ var block = layout.block; | ||
// Exit | ||
var options = this.options, | ||
layout = this.layout, | ||
referrer = this.referrer; | ||
var program = options.program, | ||
resolver = options.resolver, | ||
macros = options.macros, | ||
asPartial = options.asPartial; | ||
var Builder = options.Builder; | ||
var compiler = this.compiler, | ||
layout = this.layout; | ||
var b = new Builder(program, resolver, referrer, macros, layout, asPartial); | ||
var b = compiler.builderFor(layout); | ||
b.startLabels(); | ||
@@ -97,3 +87,3 @@ b.fetch(_vm.Register.s1); | ||
b.label('BODY'); | ||
b.invokeStaticBlock(blockFor(layout, this.options)); | ||
b.invokeStaticBlock(blockFor(layout, compiler)); | ||
b.fetch(_vm.Register.s1); | ||
@@ -105,10 +95,5 @@ b.jumpUnless('END'); | ||
b.stopLabels(); | ||
var handle = b.commit(options.program.heap, layout.block.symbols.length); | ||
var handle = b.commit(); | ||
if (false) { | ||
var _program = options.program, | ||
heap = options.program.heap; | ||
var start = heap.getaddr(handle); | ||
var end = start + heap.sizeof(handle); | ||
(0, _debug.debugSlice)(_program, start, end); | ||
(0, _compiler.debug)(compiler, handle); | ||
} | ||
@@ -120,7 +105,10 @@ return handle; | ||
}(); | ||
function blockFor(layout, options) { | ||
var block = layout.block, | ||
referrer = layout.referrer; | ||
return new _compilableTemplate2.default(block.statements, layout, options, { referrer: referrer, parameters: _util.EMPTY_ARRAY }); | ||
function blockFor(layout, compiler) { | ||
return new _compilableTemplate.CompilableBlock(compiler, { | ||
block: { | ||
statements: layout.block.statements, | ||
parameters: _util.EMPTY_ARRAY | ||
}, | ||
containingLayout: layout | ||
}); | ||
} | ||
@@ -140,10 +128,11 @@ var ComponentBuilder = exports.ComponentBuilder = function () { | ||
var builder = this.builder; | ||
var resolver = builder.resolver; | ||
if (handle !== null) { | ||
var capabilities = resolver.getCapabilities(handle); | ||
if (capabilities.dynamicLayout === false) { | ||
var layout = resolver.getLayout(handle); | ||
var _builder$compiler$res = builder.compiler.resolveLayoutForHandle(handle), | ||
capabilities = _builder$compiler$res.capabilities, | ||
compilable = _builder$compiler$res.compilable; | ||
if (compilable) { | ||
builder.pushComponentDefinition(handle); | ||
builder.invokeStaticComponent(capabilities, layout, null, params, hash, false, _default, inverse); | ||
builder.invokeStaticComponent(capabilities, compilable, null, params, hash, false, _default, inverse); | ||
} else { | ||
@@ -158,2 +147,2 @@ builder.pushComponentDefinition(handle); | ||
}(); | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3dyYXBwZWQtY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7QUFBQSxBQUFPLEFBQUUsQUFBUSxBQUFFLEFBQU0sQUFBYSxBQUFDOztBQVV2QyxBQUFPLEFBQWtCLEFBQU0sQUFBdUIsQUFBQzs7OztBQUN2RCxBQUFPLEFBQUUsQUFBVSxBQUFFLEFBQU0sQUFBUyxBQUFDOztBQUVyQyxBQUFPLEFBQUUsQUFBVyxBQUFFLEF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AgICAgIFB1dFZhbHVlKFRhZ0V4cHIpXG4gICAgLy8gICAgICAgIFRlc3RcbiAgICAvLyAgICAgICAgSnVtcFVubGVzcyhFTkQpXG4gICAgLy8gICAgICAgIENsb3NlRWxlbWVudFxuICAgIC8vIEVORDogICBOb29wXG4gICAgLy8gICAgICAgIERpZFJlbmRlckxheW91dFxuICAgIC8vICAgICAgICBFeGl0XG4gICAgLy9cbiAgICAvLz09PT09PT09U1RBVElDXG4gICAgLy8gICAgICAgIE9wZW5QcmltaXRpdmVFbGVtZW50T3Bjb2RlXG4gICAgLy8gICAgICAgIERpZENyZWF0ZUVsZW1lbnRcbiAgICAvLyAgICAgICAgLi4uYXR0ciBzdGF0ZW1lbnRzLi4uXG4gICAgLy8gICAgICAgIEZsdXNoRWxlbWVudFxuICAgIC8vICAgICAgICAuLi5ib2R5IHN0YXRlbWVudHMuLi5cbiAgICAvLyAgICAgICAgQ2xvc2VFbGVtZW50XG4gICAgLy8gICAgICAgIERpZFJlbmRlckxheW91dFxuICAgIC8vICAgICAgICBFeGl0XG5cbiAgICBsZXQgeyBjb21waWxlciwgbGF5b3V0IH0gPSB0aGlzO1xuICAgIGxldCBiID0gY29tcGlsZXIuYnVpbGRlckZvcihsYXlvdXQpO1xuXG4gICAgYi5zdGFydExhYmVscygpO1xuXG4gICAgYi5mZXRjaChSZWdpc3Rlci5zMSk7XG5cbiAgICBiLmdldENvbXBvbmVudFRhZ05hbWUoUmVnaXN0ZXIuczApO1xuICAgIGIucHJpbWl0aXZlUmVmZXJlbmNlKCk7XG5cbiAgICBiLmR1cCgpO1xuICAgIGIubG9hZChSZWdpc3Rlci5zMSk7XG5cbiAgICBiLmp1bXBVbmxlc3MoJ0JPRFknKTtcblxuICAgIGIuZmV0Y2goUmVnaXN0ZXIuczEpO1xuICAgIGIucHV0Q29tcG9uZW50T3BlcmF0aW9ucygpO1xuICAgIGIub3BlbkR5bmFtaWNFbGVtZW50KCk7XG4gICAgYi5kaWRDcmVhdGVFbGVt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25lbnRCdWlsZGVyIHtcbiAgY29uc3RydWN0b3IocHJpdmF0ZSBidWlsZGVyOiBPcGNvZGVCdWlsZGVyPExvY2F0b3I+KSB7fVxuXG4gIHN0YXRpYyhoYW5kbGU6IG51bWJlciwgYXJnczogQ29tcG9uZW50QXJncykge1xuICAgIGxldCBbcGFyYW1zLCBoYXNoLCBfZGVmYXVsdCwgaW52ZXJzZV0gPSBhcmdzO1xuICAgIGxldCB7IGJ1aWxkZXIgfSA9IHRoaXM7XG5cbiAgICBpZiAoaGFuZGxlICE9PSBudWxsKSB7XG4gICAgICBsZXQgeyBjYXBhYmlsaXRpZXMsIGNvbXBpbGFibGUgfSA9IGJ1aWxkZXIuY29tcGlsZXIucmVzb2x2ZUxheW91dEZvckhhbmRsZShoYW5kbGUpO1xuXG4gICAgICBpZiAoY29tcGlsYWJsZSkge1xuICAgICAgICBidWlsZGVyLnB1c2hDb21wb25lbnREZWZpbml0aW9uKGhhbmRsZSk7XG4gICAgICAgIGJ1aWxkZXIuaW52b2tlU3RhdGljQ29tcG9uZW50KGNhcGFiaWxpdGllcywgY29tcGlsYWJsZSwgbnVsbCwgcGFyYW1zLCBoYXNoLCBmYWxzZSwgX2RlZmF1bHQsIGludmVyc2UpO1xuICAgICAgfSBlbHNlIHtcbiAgICAgICAgYnVpbGRlci5wdXNoQ29tcG9uZW50RGVmaW5pdGlvbihoYW5kbGUpO1xuICAgICAgICBidWlsZGVyLmludm9rZUNvbXBvbmVudChudWxsLCBwYXJhbXMsIGhhc2gsIGZhbHNlLCBfZGVmYXVsdCwgaW52ZXJzZSk7XG4gICAgICB9XG4gICAgfVxuICB9XG59XG4iXX0= |
export * from './lib/interfaces'; | ||
export { ATTRS_BLOCK, Macros } from './lib/syntax'; | ||
export { LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, SimpleOpcodeBuilder } from './lib/opcode-builder'; | ||
export * from './lib/lazy'; | ||
export * from './lib/compile'; | ||
export * from './lib/compiler'; | ||
export { CompilableBlock, CompilableProgram } from './lib/compilable-template'; | ||
export { LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, StdOpcodeBuilder } from './lib/opcode-builder'; | ||
export { PartialDefinition } from './lib/partial-template'; | ||
export { default as templateFactory } from './lib/template'; | ||
export { default as CompilableTemplate } from './lib/compilable-template'; | ||
export { debug, debugSlice, logOpcode } from './lib/debug'; | ||
export { WrappedBuilder } from './lib/wrapped-component'; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsY0FBYyxBQUFrQixBQUFDO0FBRWpDLEFBQU8sU0FDTCxBQUFXLGFBRVgsQUFBTSxBQUVQLGNBQU0sQUFBYyxBQUFDO0FBRXRCLEFBQU8sU0FFTCxBQUFpQixtQkFDakIsQUFBa0Isb0JBQ2xCLEFBQWEsZUFFYixBQUFtQixBQUNwQiwyQkFBTSxBQUFzQixBQUFDO0FBRTlCLEFBQU8sU0FBRSxBQUFpQixBQUFFLHlCQUFNLEFBQXdCLEFBQUM7QUFFM0QsQUFBTyxTQUNMLEFBQU8sV0FBSSxBQUFlLEFBRTNCLHVCQUFNLEFBQWdCLEFBQUM7QUFFeEIsQUFBTyxTQUNMLEFBQU8sV0FBSSxBQUFrQixBQUM5QiwwQkFBTSxBQUEyQixBQUFDO0FBRW5DLEFBQU8sU0FDTCxBQUFLLE9BQ0wsQUFBVSxZQUNWLEFBQVMsQUFDVixpQkFBTSxBQUFhLEFBQUM7QUFFckIsQUFBTyxTQUNMLEFBQWMsQUFDZixzQkFBTSxBQUF5QixBQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9saWIvaW50ZXJmY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i9jb21waWxhYmxlLXRlbXBsYXRlJztcblxuZXhwb3J0IHtcbiAgTGF6eU9wY29kZUJ1aWxkZXIsXG4gIEVhZ2VyT3Bjb2RlQnVpbGRlcixcbiAgT3Bjb2RlQnVpbGRlcixcbiAgT3Bjb2RlQnVpbGRlckNvbnN0cnVjdG9yLFxuICBTdGRPcGNvZGVCdWlsZGVyLFxufSBmcm9tICcuL2xpYi9vcGNvZGUtYnVpbGRlcic7XG5cbmV4cG9ydCB7IFBhcnRpYWxEZWZpbml0aW9uIH0gZnJvbSAnLi9saWIvcGFydGlhbC10ZW1wbGF0ZSc7XG5cbmV4cG9ydCB7XG4gIGRlZmF1bHQgYXMgdGVtcGxhdGVGYWN0b3J5LFxuICBUZW1wbGF0ZUZhY3Rvcnlcbn0gZnJvbSAnLi9saWIvdGVtcGxhdGUnO1xuXG5leHBvcnQge1xuICBkZWJ1ZyxcbiAgZGVidWdTbGljZSxcbiAgbG9nT3Bjb2RlXG59IGZyb20gJy4vbGliL2RlYnVnJztcblxuZXhwb3J0IHtcbiAgV3JhcHBlZEJ1aWxkZXIsXG59IGZyb20gJy4vbGliL3dyYXBwZWQtY29tcG9uZW50JztcbiJdfQ== |
@@ -1,20 +0,29 @@ | ||
import { debugSlice } from './debug'; | ||
import { statementCompiler } from './syntax'; | ||
export const PLACEHOLDER_HANDLE = -1; | ||
export default class CompilableTemplateImpl { | ||
constructor(statements, containingLayout, options, symbolTable) { | ||
this.statements = statements; | ||
this.containingLayout = containingLayout; | ||
this.options = options; | ||
this.symbolTable = symbolTable; | ||
export class CompilableProgram { | ||
constructor(compiler, layout) { | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
this.compiled = null; | ||
this.statementCompiler = statementCompiler(); | ||
} | ||
static topLevel(block, options) { | ||
return new CompilableTemplateImpl(block.statements, { block, referrer: options.referrer }, options, { hasEval: block.hasEval, symbols: block.symbols }); | ||
get symbolTable() { | ||
return this.layout.block; | ||
} | ||
compile(stdLib) { | ||
let { compiled } = this; | ||
if (compiled !== null) return compiled; | ||
compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
let { block: { statements } } = this.layout; | ||
return this.compiled = this.compiler.add(statements, this.layout); | ||
} | ||
} | ||
export class CompilableBlock { | ||
constructor(compiler, parsed) { | ||
this.compiler = compiler; | ||
this.parsed = parsed; | ||
this.compiled = null; | ||
} | ||
get symbolTable() { | ||
return this.parsed.block; | ||
} | ||
compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
// Track that compilation has started but not yet finished by temporarily | ||
@@ -25,19 +34,6 @@ // using a placeholder handle. In eager compilation mode, where compile() | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
let { options, statements, containingLayout } = this; | ||
let { referrer } = containingLayout; | ||
let { program, resolver, macros, asPartial, Builder } = options; | ||
let builder = new Builder(program, resolver, referrer, macros, containingLayout, asPartial, stdLib); | ||
for (let i = 0; i < statements.length; i++) { | ||
this.statementCompiler.compile(statements[i], builder); | ||
} | ||
let handle = builder.commit(program.heap, containingLayout.block.symbols.length); | ||
if (false) { | ||
let { heap } = program; | ||
let start = heap.getaddr(handle); | ||
let end = start + heap.sizeof(handle); | ||
debugSlice(program, start, end); | ||
} | ||
return this.compiled = handle; | ||
let { block: { statements }, containingLayout } = this.parsed; | ||
return this.compiled = this.compiler.add(statements, containingLayout); | ||
} | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGlsYWJsZS10ZW1wbGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvY29tcGlsYWJsZS10ZW1wbGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBU0EsQUFBTyxTQUFFLEFBQVUsQUFBRSxrQkFBTSxBQUFTLEFBQUM7QUFFckMsQ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b3V0IH0gPSB0aGlzLnBhcnNlZDtcblxuICAgIHJldHVybiB0aGlzLmNvbXBpbGVkID0gdGhpcy5jb21waWxlci5hZGQoc3RhdGVtZW50cywgY29udGFpbmluZ0xheW91dCk7XG4gIH1cbn1cbiJdfQ== |
@@ -12,3 +12,3 @@ import { Register } from '@glimmer/vm'; | ||
let { type, op1, op2, op3, size } = program.opcode(i); | ||
let [name, params] = debug(constants, type, op1, op2, op3); | ||
let [name, params] = debug(i, constants, type, op1, op2, op3); | ||
console.log(`${i}. ${logOpcode(name, params)}`); | ||
@@ -51,3 +51,3 @@ _size = size; | ||
} | ||
export function debug(c, op, ...operands) { | ||
export function debug(pos, c, op, ...operands) { | ||
let metadata = null; | ||
@@ -61,2 +61,5 @@ if (!metadata) { | ||
switch (operand.type) { | ||
case 'to': | ||
out[operand.name] = pos + op; | ||
break; | ||
case 'i32': | ||
@@ -128,2 +131,2 @@ case 'symbol': | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL2RlYnVnLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQU9BLEFBQU8sQUFBRSxBQUFRLFNBQU0sQUFBUSxBQUFFLGdCQUFNLEFBQWEsQUFBQyxBQUNyRCxBQUFPLEFBQUUsQUFBSyxBQUFFLEFBQU0sQUFBNEIsQUFBQzs7QUFDbkQsQUFBTyxTQUFFLEFBQVcsYUFBRSxBQUFJLEFBQUUsWUFBTSxBQUFlLEFBQUM7QUFpQmxELEFBQU0sMkJBQXFCLEFBQTJCLFNBQUUsQUFBYSxPQUFFLEFBQVc7QUFDaEYsQUFBRSxBQUFDLEFBQUMsQUFBSyxBQUFDLGVBQUMsQUFBQztBQUNWLEFBQStCO0FBQy9C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aXRjaCAoZmxhZykge1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5OVU1CRVI6XG4gICAgICByZXR1cm4gdmFsdWU7XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLkZMT0FUOlxuICAgICAgcmV0dXJuIGNvbnN0YW50cy5nZXROdW1iZXIodmFsdWUpO1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5TVFJJTkc6XG4gICAgICByZXR1cm4gY29uc3RhbnRzLmdldFN0cmluZyh2YWx1ZSk7XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLkJPT0xFQU5fT1JfVk9JRDpcbiAgICAgIHN3aXRjaCAodmFsdWUpIHtcbiAgICAgICAgY2FzZSAwOiByZXR1cm4gZmFsc2U7XG4gICAgICAgIGNhc2UgMTogcmV0dXJuIHRydWU7XG4gICAgICAgIGNhc2UgMjogcmV0dXJuIG51bGw7XG4gICAgICAgIGNhc2UgMzogcmV0dXJuIHVuZGVmaW5lZDtcbiAgICAgIH1cbiAgICBjYXNlIFByaW1pdGl2ZVR5cGUuTkVHQVRJVkU6XG4gICAgICByZXR1cm4gY29uc3RhbnRzLmdldE51bWJlcih2YWx1ZSk7XG4gICAgZGVmYXVsdDpcbiAgICAgIHRocm93IHVucmVhY2hhYmxlKCk7XG4gIH1cbn1cbiJdfQ== |
export const PLACEHOLDER_HANDLE = -1; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZXJmYWNlcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3BhY2thZ2VzL0BnbGltbWVyL29wY29kZS1jb21waWxlci9saWIvaW50ZXJmYWNlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFvQkEsQUFBTSxPQUFDLE1BQU0sQUFBa0IscUJBQUcsQ0FBQyxBQUFDLEFBQUMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcn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XI8TG9jYXRvcj4+IHtcbiAgcmVzb2x2ZXI6IFI7XG4gIHByb2dyYW06IENvbXBpbGVUaW1lUHJvZ3JhbTtcbiAgbWFjcm9zOiBNYWNyb3M7XG59XG5cbmV4cG9ydCBjb25zdCBQTEFDRUhPTERFUl9IQU5ETEUgPSAtMTtcblxuZXhwb3J0IHR5cGUgUHJpbWl0aXZlID0gdW5kZWZpbmVkIHwgbnVsbCB8IGJvb2xlYW4gfCBudW1iZXIgfCBzdHJpbmc7XG5cbmV4cG9ydCB0eXBlIENvbXBvbmVudEFyZ3MgPSBbQ29yZS5QYXJhbXMsIENvcmUuSGFzaCwgT3B0aW9uPENvbXBpbGFibGVCbG9jaz4sIE9wdGlvbjxDb21waWxhYmxlQmxvY2s+XTtcblxuZXhwb3J0IGludGVyZmFjZSBDb21wb25lbnRCdWlsZGVyIHtcbiAgc3RhdGljKGRlZmluaXRpb246IG51bWJlciwgYXJnczogQ29tcG9uZW50QXJncyk6IHZvaWQ7XG59XG4iXX0= |
import { assign } from '@glimmer/util'; | ||
import CompilableTemplate from './compilable-template'; | ||
import { CompilableProgram as CompilableProgramInstance } from './compilable-template'; | ||
import { WrappedBuilder } from "./wrapped-component"; | ||
@@ -8,3 +8,3 @@ let clientId = 0; | ||
let id = templateId || `client-${clientId++}`; | ||
let create = (options, envMeta) => { | ||
let create = (compiler, envMeta) => { | ||
let newMeta = envMeta ? assign({}, envMeta, meta) : meta; | ||
@@ -14,3 +14,3 @@ if (!parsedBlock) { | ||
} | ||
return new TemplateImpl(options, { id, block: parsedBlock, referrer: newMeta }); | ||
return new TemplateImpl(compiler, { id, block: parsedBlock, referrer: newMeta }); | ||
}; | ||
@@ -20,4 +20,4 @@ return { id, meta, create }; | ||
class TemplateImpl { | ||
constructor(options, parsedLayout) { | ||
this.options = options; | ||
constructor(compiler, parsedLayout) { | ||
this.compiler = compiler; | ||
this.parsedLayout = parsedLayout; | ||
@@ -30,3 +30,2 @@ this.layout = null; | ||
this.hasEval = block.hasEval; | ||
this.statements = block.statements; | ||
this.referrer = parsedLayout.referrer; | ||
@@ -37,23 +36,13 @@ this.id = parsedLayout.id || `client-${clientId++}`; | ||
if (this.layout) return this.layout; | ||
return this.layout = compilable(this.parsedLayout, this.options, false); | ||
return this.layout = new CompilableProgramInstance(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
} | ||
asPartial() { | ||
if (this.partial) return this.partial; | ||
return this.partial = compilable(this.parsedLayout, this.options, true); | ||
return this.layout = new CompilableProgramInstance(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: true })); | ||
} | ||
asWrappedLayout() { | ||
if (this.wrappedLayout) return this.wrappedLayout; | ||
let compileOptions = assign({}, this.options, { | ||
asPartial: false, | ||
referrer: this.referrer | ||
}); | ||
return this.wrappedLayout = new WrappedBuilder(compileOptions, this.parsedLayout); | ||
return this.wrappedLayout = new WrappedBuilder(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
} | ||
} | ||
export function compilable(layout, options, asPartial) { | ||
let { block, referrer } = layout; | ||
let { hasEval, symbols } = block; | ||
let compileOptions = assign({}, options, { asPartial, referrer }); | ||
return new CompilableTemplate(block.statements, layout, compileOptions, { referrer, hasEval, symbols }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGVtcGxhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3RlbXBsYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLEFBQU8sU0FBRSxBQUFNLEFBQUUsY0FBTSxBQUFlLEFBQUM7QUFNdkMsT0FBTyxBQUFrQix3QkFBTSxBQUF1QixBQUFDO0FBRXZELEFBQU8sU0FBRSxBQUFjLEFBQUUsc0JBQU0sQUFBcUIsQUFBQztBQWdDckQsSUFBSSx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immer/vm'; | ||
import CompilableTemplate from './compilable-template'; | ||
import { debugSlice } from './debug'; | ||
import { debug } from './compiler'; | ||
import { CompilableBlock as CompilableBlockInstance } from './compilable-template'; | ||
import { ATTRS_BLOCK } from './syntax'; | ||
@@ -8,4 +8,4 @@ | ||
export class WrappedBuilder { | ||
constructor(options, layout) { | ||
this.options = options; | ||
constructor(compiler, layout) { | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
@@ -46,6 +46,4 @@ let { block } = layout; | ||
// Exit | ||
let { options, layout, referrer } = this; | ||
let { program, resolver, macros, asPartial } = options; | ||
let { Builder } = options; | ||
let b = new Builder(program, resolver, referrer, macros, layout, asPartial); | ||
let { compiler, layout } = this; | ||
let b = compiler.builderFor(layout); | ||
b.startLabels(); | ||
@@ -64,3 +62,3 @@ b.fetch(Register.s1); | ||
b.label('BODY'); | ||
b.invokeStaticBlock(blockFor(layout, this.options)); | ||
b.invokeStaticBlock(blockFor(layout, compiler)); | ||
b.fetch(Register.s1); | ||
@@ -72,8 +70,5 @@ b.jumpUnless('END'); | ||
b.stopLabels(); | ||
let handle = b.commit(options.program.heap, layout.block.symbols.length); | ||
let handle = b.commit(); | ||
if (false) { | ||
let { program, program: { heap } } = options; | ||
let start = heap.getaddr(handle); | ||
let end = start + heap.sizeof(handle); | ||
debugSlice(program, start, end); | ||
debug(compiler, handle); | ||
} | ||
@@ -83,5 +78,10 @@ return handle; | ||
} | ||
function blockFor(layout, options) { | ||
let { block, referrer } = layout; | ||
return new CompilableTemplate(block.statements, layout, options, { referrer, parameters: EMPTY_ARRAY }); | ||
function blockFor(layout, compiler) { | ||
return new CompilableBlockInstance(compiler, { | ||
block: { | ||
statements: layout.block.statements, | ||
parameters: EMPTY_ARRAY | ||
}, | ||
containingLayout: layout | ||
}); | ||
} | ||
@@ -95,9 +95,7 @@ export class ComponentBuilder { | ||
let { builder } = this; | ||
let { resolver } = builder; | ||
if (handle !== null) { | ||
let capabilities = resolver.getCapabilities(handle); | ||
if (capabilities.dynamicLayout === false) { | ||
let layout = resolver.getLayout(handle); | ||
let { capabilities, compilable } = builder.compiler.resolveLayoutForHandle(handle); | ||
if (compilable) { | ||
builder.pushComponentDefinition(handle); | ||
builder.invokeStaticComponent(capabilities, layout, null, params, hash, false, _default, inverse); | ||
builder.invokeStaticComponent(capabilities, compilable, null, params, hash, false, _default, inverse); | ||
} else { | ||
@@ -110,2 +108,2 @@ builder.pushComponentDefinition(handle); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3dyYXBwZWQtY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLEFBQU8sU0FBRSxBQUFRLEFBQUUsZ0JBQU0sQUFBYSxBQUFDO0FBVXZDLE9BQU8sQUFBa0Isd0JBQU0sQUFBdUIsQUFBQztBQUN2RCxBQUFPLFNBQUUsQUFBVSxBQUFFLGtCQUFNLEFBQVMsQUFBQztBQUVyQyxBQUFPLFNBQUUsQUFBVyxBQUFFLG1CQUFNLEFBQVUsQUFBQyxBQUV2QyxBQUFPLEFBQUUsQUFBSyxBQUFFLEFBQU0sQUFBNEIsQUFBQzs7QUFDbkQsQUFBTyxTQUFFLEFBQVcsQUFBRSxtQkFBTSxBQUFlLEFBQUM7QUFFNUMsQUFBTTtBQUlKLGdCQUFtQixBQUFxQyxTQUFVLEFBQWtDO0FBQWpGLGFBQU8sVUFBUCxBQUFPLEFBQThCO0FBQVUsYUFBTSxTQUFOLEFBQU0sQUFBNEI7QUFDbEcsWUFBSSxFQUFFLEFBQUssQUFBRSxVQUFHLEFBQU0sQUFBQztBQUV2QixBQUFJLGFBQUMsQUFBVztBQUNkLEFBQU8scUJBQUUsQUFB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4gICAgbGV0IHsgYmxvY2sgfSA9IGxheW91dDtcblxuICAgIHRoaXMuc3ltYm9sVGFibGUgPSB7XG4gICAgICBoYXNFdmFsOiBibG9jay5oYXNFdmFsLFxuICAgICAgc3ltYm9sczogYmxvY2suc3ltYm9scy5jb25jYXQoW0FUVFJTX0JMT0NLXSlcbiAgICB9O1xuICB9XG5cbiAgY29tcGlsZSgpOiBudW1iZXIge1xuICAgIC8vPT09PT09PT1EWU5BTUlDXG4gICAgLy8gICAgICAgIFB1dFZhbHVlKFRhZ0V4cHIpXG4gICAgLy8gICAgICAgIFRlc3RcbiAgICAvLyAgICAgICAgSnVtcFVubGVzcyhCT0RZKVxuICAgIC8vICAgICAgICBPcGVuRHluYW1pY1ByaW1pdGl2ZUVsZW1lbnRcbiAgICAvLyAgICAgICAgRGlkQ3JlYXRlRWxlbWVudFxuICAgIC8vICAgICAgICAuLi5hdHRyIHN0YXRlbWVudHMuLi5cbiAgICAvLyAgICAgICAgRmx1c2hFbGVtZW50XG4gICAgLy8gQk9EWTogIE5vb3BcbiAgICAvLyAgICAgICAgLi4uYm9keSBzdGF0ZW1lbnRzLi4uXG4gICAgLy8gICAgICAgIFB1dFZhbHVlKFRhZ0V4cHIpXG4gICAgLy8gICAgICAgIFRlc3RcbiAgICAvLyAgICAgICAgSnVtcFVubGVzcyhFTkQpXG4gICAgLy8gICAgICAgIENsb3NlRWxlbWVudFxuICAgIC8vIEVORDogICBOb29wXG4gICAgLy8gICAgICAgIERpZFJlbmRlckxheW91dFxuICAgIC8vICAgICAgICBFeGl0XG4gICAgLy9cbiAgICAvLz09PT09PT09U1RBVElDXG4gICAgLy8gICAgICAgIE9wZW5QcmltaXRpdmVFbGVtZW50T3Bjb2RlXG4gICAgLy8gICAgICAgIERpZENyZWF0ZUVsZW1lbnRcbiAgICAvLyAgICAgICAgLi4uYXR0ciBzdGF0ZW1lbnRzLi4uXG4gICAgLy8gICAgICAgIEZsdXNoRWxlbWVudFxuICAgIC8vICAgICAgICA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V0YT4pIHt9XG5cbiAgc3RhdGljKGhhbmRsZTogbnVtYmVyLCBhcmdzOiBDb21wb25lbnRBcmdzKSB7XG4gICAgbGV0IFtwYXJhbXMsIGhhc2gsIF9kZWZhdWx0LCBpbnZlcnNlXSA9IGFyZ3M7XG4gICAgbGV0IHsgYnVpbGRlciB9ID0gdGhpcztcbiAgICBsZXQgeyByZXNvbHZlciB9ID0gYnVpbGRlcjtcblxuICAgIGlmIChoYW5kbGUgIT09IG51bGwpIHtcbiAgICAgIGxldCBjYXBhYmlsaXRpZXMgPSByZXNvbHZlci5nZXRDYXBhYmlsaXRpZXMoaGFuZGxlKTtcblxuICAgICAgaWYgKGNhcGFiaWxpdGllcy5keW5hbWljTGF5b3V0ID09PSBmYWxzZSkge1xuICAgICAgICBsZXQgbGF5b3V0ID0gcmVzb2x2ZXIuZ2V0TGF5b3V0KGhhbmRsZSkhO1xuXG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VTdGF0aWNDb21wb25lbnQoY2FwYWJpbGl0aWVzLCBsYXlvdXQsIG51bGwsIHBhcmFtcywgaGFzaCwgZmFsc2UsIF9kZWZhdWx0LCBpbnZlcnNlKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VDb21wb25lbnQobnVsbCwgcGFyYW1zLCBoYXNoLCBmYWxzZSwgX2RlZmF1bHQsIGludmVyc2UpO1xuICAgICAgfVxuICAgIH1cbiAgfVxufVxuIl19 | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpb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iAgICAgICAgYnVpbGRlci5wdXNoQ29tcG9uZW50RGVmaW5pdGlvbihoYW5kbGUpO1xuICAgICAgICBidWlsZGVyLmludm9rZVN0YXRpY0NvbXBvbmVudChjYXBhYmlsaXRpZXMsIGNvbXBpbGFibGUsIG51bGwsIHBhcmFtcywgaGFzaCwgZmFsc2UsIF9kZWZhdWx0LCBpbnZlcnNlKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VDb21wb25lbnQobnVsbCwgcGFyYW1zLCBoYXNoLCBmYWxzZSwgX2RlZmF1bHQsIGludmVyc2UpO1xuICAgICAgfVxuICAgIH1cbiAgfVxufVxuIl19 |
export * from './lib/interfaces'; | ||
export { ATTRS_BLOCK, Macros } from './lib/syntax'; | ||
export { LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, SimpleOpcodeBuilder } from './lib/opcode-builder'; | ||
export * from './lib/lazy'; | ||
export * from './lib/compile'; | ||
export * from './lib/compiler'; | ||
export { CompilableBlock, CompilableProgram } from './lib/compilable-template'; | ||
export { LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, StdOpcodeBuilder } from './lib/opcode-builder'; | ||
export { PartialDefinition } from './lib/partial-template'; | ||
export { default as templateFactory } from './lib/template'; | ||
export { default as CompilableTemplate } from './lib/compilable-template'; | ||
export { debug, debugSlice, logOpcode } from './lib/debug'; | ||
export { WrappedBuilder } from './lib/wrapped-component'; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsY0FBYy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cnQge1xuICBkZWJ1ZyxcbiAgZGVidWdTbGljZSxcbiAgbG9nT3Bjb2RlXG59IGZyb20gJy4vbGliL2RlYnVnJztcblxuZXhwb3J0IHtcbiAgV3JhcHBlZEJ1aWxkZXIsXG59IGZyb20gJy4vbGliL3dyYXBwZWQtY29tcG9uZW50JztcbiJdfQ== |
@@ -0,27 +1,43 @@ | ||
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); | ||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
import { debugSlice } from './debug'; | ||
import { statementCompiler } from './syntax'; | ||
export var PLACEHOLDER_HANDLE = -1; | ||
export var CompilableProgram = function () { | ||
function CompilableProgram(compiler, layout) { | ||
_classCallCheck(this, CompilableProgram); | ||
var CompilableTemplateImpl = function () { | ||
function CompilableTemplateImpl(statements, containingLayout, options, symbolTable) { | ||
_classCallCheck(this, CompilableTemplateImpl); | ||
this.statements = statements; | ||
this.containingLayout = containingLayout; | ||
this.options = options; | ||
this.symbolTable = symbolTable; | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
this.compiled = null; | ||
this.statementCompiler = statementCompiler(); | ||
} | ||
CompilableTemplateImpl.topLevel = function topLevel(block, options) { | ||
return new CompilableTemplateImpl(block.statements, { block: block, referrer: options.referrer }, options, { hasEval: block.hasEval, symbols: block.symbols }); | ||
CompilableProgram.prototype.compile = function compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
var statements = this.layout.block.statements; | ||
return this.compiled = this.compiler.add(statements, this.layout); | ||
}; | ||
CompilableTemplateImpl.prototype.compile = function compile(stdLib) { | ||
var compiled = this.compiled; | ||
_createClass(CompilableProgram, [{ | ||
key: "symbolTable", | ||
get: function get() { | ||
return this.layout.block; | ||
} | ||
}]); | ||
if (compiled !== null) return compiled; | ||
return CompilableProgram; | ||
}(); | ||
export var CompilableBlock = function () { | ||
function CompilableBlock(compiler, parsed) { | ||
_classCallCheck(this, CompilableBlock); | ||
this.compiler = compiler; | ||
this.parsed = parsed; | ||
this.compiled = null; | ||
} | ||
CompilableBlock.prototype.compile = function compile() { | ||
if (this.compiled !== null) return this.compiled; | ||
// Track that compilation has started but not yet finished by temporarily | ||
@@ -32,31 +48,18 @@ // using a placeholder handle. In eager compilation mode, where compile() | ||
this.compiled = PLACEHOLDER_HANDLE; | ||
var options = this.options, | ||
statements = this.statements, | ||
containingLayout = this.containingLayout; | ||
var referrer = containingLayout.referrer; | ||
var program = options.program, | ||
resolver = options.resolver, | ||
macros = options.macros, | ||
asPartial = options.asPartial, | ||
Builder = options.Builder; | ||
var _parsed = this.parsed, | ||
statements = _parsed.block.statements, | ||
containingLayout = _parsed.containingLayout; | ||
var builder = new Builder(program, resolver, referrer, macros, containingLayout, asPartial, stdLib); | ||
for (var i = 0; i < statements.length; i++) { | ||
this.statementCompiler.compile(statements[i], builder); | ||
} | ||
var handle = builder.commit(program.heap, containingLayout.block.symbols.length); | ||
if (false) { | ||
var heap = program.heap; | ||
return this.compiled = this.compiler.add(statements, containingLayout); | ||
}; | ||
var start = heap.getaddr(handle); | ||
var end = start + heap.sizeof(handle); | ||
debugSlice(program, start, end); | ||
_createClass(CompilableBlock, [{ | ||
key: "symbolTable", | ||
get: function get() { | ||
return this.parsed.block; | ||
} | ||
return this.compiled = handle; | ||
}; | ||
}]); | ||
return CompilableTemplateImpl; | ||
return CompilableBlock; | ||
}(); | ||
export default CompilableTemplateImpl; | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcGlsYWJsZS10ZW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1c2UgdGhpcyBhcyBhIHNpZ25hbCB0aGF0IHRoZSBoYW5kbGUgY2Fubm90XG4gICAgLy8gYmUga25vd24gc3luY2hyb25vdXNseSBhbmQgbXVzdCBiZSBsaW5rZWQgbGF6aWx5LlxuICAgIHRoaXMuY29tcGlsZWQgPSBQTEFDRUhPTERFUl9IQU5ETEU7XG5cbiAgICBsZXQgeyBibG9jazogeyBzdGF0ZW1lbnRzIH0sIGNvbnRhaW5pbmdMYXlvdXQgfSA9IHRoaXMucGFyc2VkO1xuXG4gICAgcmV0dXJuIHRoaXMuY29tcGlsZWQgPSB0aGlzLmNvbXBpbGVyLmFkZChzdGF0ZW1lbnRzLCBjb250YWluaW5nTGF5b3V0KTtcbiAgfVxufVxuIl19 |
@@ -19,3 +19,3 @@ import { Register } from '@glimmer/vm'; | ||
var _debug = debug(constants, type, op1, op2, op3), | ||
var _debug = debug(i, constants, type, op1, op2, op3), | ||
name = _debug[0], | ||
@@ -63,5 +63,5 @@ params = _debug[1]; | ||
} | ||
export function debug(c, op) { | ||
for (var _len = arguments.length, operands = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { | ||
operands[_key - 2] = arguments[_key]; | ||
export function debug(pos, c, op) { | ||
for (var _len = arguments.length, operands = Array(_len > 3 ? _len - 3 : 0), _key = 3; _key < _len; _key++) { | ||
operands[_key - 3] = arguments[_key]; | ||
} | ||
@@ -77,2 +77,5 @@ | ||
switch (operand.type) { | ||
case 'to': | ||
out[operand.name] = pos + op; | ||
break; | ||
case 'i32': | ||
@@ -144,2 +147,2 @@ case 'symbol': | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL2RlYnVnLnRzIl0sIm5hbWVzIjpbXSwibWFwc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lY29kZVByaW1pdGl2ZShwcmltaXRpdmU6IG51bWJlciwgY29uc3RhbnRzOiBEZWJ1Z0NvbnN0YW50cyk6IFByaW1pdGl2ZSB7XG4gIGxldCBmbGFnID0gcHJpbWl0aXZlICYgNzsgLy8gMTExXG4gIGxldCB2YWx1ZSA9IHByaW1pdGl2ZSA+PiAzO1xuXG4gIHN3aXRjaCAoZmxhZykge1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5OVU1CRVI6XG4gICAgICByZXR1cm4gdmFsdWU7XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLkZMT0FUOlxuICAgICAgcmV0dXJuIGNvbnN0YW50cy5nZXROdW1iZXIodmFsdWUpO1xuICAgIGNhc2UgUHJpbWl0aXZlVHlwZS5TVFJJTkc6XG4gICAgICByZXR1cm4gY29uc3RhbnRzLmdldFN0cmluZyh2YWx1ZSk7XG4gICAgY2FzZSBQcmltaXRpdmVUeXBlLkJPT0xFQU5fT1JfVk9JRDpcbiAgICAgIHN3aXRjaCAodmFsdWUpIHtcbiAgICAgICAgY2FzZSAwOiByZXR1cm4gZmFsc2U7XG4gICAgICAgIGNhc2UgMTogcmV0dXJuIHRydWU7XG4gICAgICAgIGNhc2UgMjogcmV0dXJuIG51bGw7XG4gICAgICAgIGNhc2UgMzogcmV0dXJuIHVuZGVmaW5lZDtcbiAgICAgIH1cbiAgICBjYXNlIFByaW1pdGl2ZVR5cGUuTkVHQVRJVkU6XG4gICAgICByZXR1cm4gY29uc3RhbnRzLmdldE51bWJlcih2YWx1ZSk7XG4gICAgZGVmYXVsdDpcbiAgICAgIHRocm93IHVucmVhY2hhYmxlKCk7XG4gIH1cbn1cbiJdfQ== | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGVidWcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tc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CbG9jayxcbiAgQ29tcG9uZW50Q2FwYWJpbGl0aWVzLFxuICBDb21waWxlVGltZVByb2dyYW0sXG59IGZyb20gJ0BnbGltbWVyL2ludGVyZmFjZXMnO1xuaW1wb3J0IHsgQ29yZSB9IGZyb20gJ0BnbGltbWVyL3dpcmUtZm9ybWF0JztcbmltcG9ydCB7IE1hY3JvcyB9IGZyb20gJy4vc3ludGF4JztcblxuZXhwb3J0IGludGVyZmFjZSBFYWdlclJlc29sdmVyPExvY2F0b3I+IHtcbiAgZ2V0Q2FwYWJpbGl0aWVzKGxvY2F0b3I6IExvY2F0b3IpOiBDb21wb25lbnRDYXBhYmlsaXRpZXM7XG59XG5cbmV4cG9ydCBpbnRlcmZhY2UgRWFnZXJDb21waWxhdGlvbk9wdGlvbnM8TG9jYXRvciwgUiBleHRlbmRzIEVhZ2VyUmVzb2x2ZXI8TG9jYXRvcj4+IHtcbiAgcmVzb2x2ZXI6IFI7XG4gIHByb2dyYW06IENvbXBpbGVUaW1lUHJvZ3JhbTtcbiAgbWFjcm9zOiBNYWNyb3M7XG59XG5cbmV4cG9ydCBjb25zdCBQTEFDRUhPTERFUl9IQU5ETEUgPSAtMTtcblxuZXhwb3J0IHR5cGUgUHJpbWl0aXZlID0gdW5kZWZpbmVkIHwgbnVsbCB8IGJvb2xlYW4gfCBudW1iZXIgfCBzdHJpbmc7XG5cbmV4cG9ydCB0eXBlIENvbXBvbmVudEFyZ3MgPSBbQ29yZS5QYXJhbXMsIENvcmUuSGFzaCwgT3B0aW9uPENvbXBpbGFibGVCbG9jaz4sIE9wdGlvbjxDb21waWxhYmxlQmxvY2s+XTtcblxuZXhwb3J0IGludGVyZmFjZSBDb21wb25lbnRCdWlsZGVyIHtcbiAgc3RhdGljKGRlZmluaXRpb246IG51bWJlciwgYXJnczogQ29tcG9uZW50QXJncyk6IHZvaWQ7XG59XG4iXX0= |
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
import { assign } from '@glimmer/util'; | ||
import CompilableTemplate from './compilable-template'; | ||
import { CompilableProgram as CompilableProgramInstance } from './compilable-template'; | ||
import { WrappedBuilder } from "./wrapped-component"; | ||
@@ -14,3 +14,3 @@ var clientId = 0; | ||
var id = templateId || 'client-' + clientId++; | ||
var create = function create(options, envMeta) { | ||
var create = function create(compiler, envMeta) { | ||
var newMeta = envMeta ? assign({}, envMeta, meta) : meta; | ||
@@ -20,3 +20,3 @@ if (!parsedBlock) { | ||
} | ||
return new TemplateImpl(options, { id: id, block: parsedBlock, referrer: newMeta }); | ||
return new TemplateImpl(compiler, { id: id, block: parsedBlock, referrer: newMeta }); | ||
}; | ||
@@ -27,6 +27,6 @@ return { id: id, meta: meta, create: create }; | ||
var TemplateImpl = function () { | ||
function TemplateImpl(options, parsedLayout) { | ||
function TemplateImpl(compiler, parsedLayout) { | ||
_classCallCheck(this, TemplateImpl); | ||
this.options = options; | ||
this.compiler = compiler; | ||
this.parsedLayout = parsedLayout; | ||
@@ -40,3 +40,2 @@ this.layout = null; | ||
this.hasEval = block.hasEval; | ||
this.statements = block.statements; | ||
this.referrer = parsedLayout.referrer; | ||
@@ -48,3 +47,3 @@ this.id = parsedLayout.id || 'client-' + clientId++; | ||
if (this.layout) return this.layout; | ||
return this.layout = compilable(this.parsedLayout, this.options, false); | ||
return this.layout = new CompilableProgramInstance(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
}; | ||
@@ -54,3 +53,3 @@ | ||
if (this.partial) return this.partial; | ||
return this.partial = compilable(this.parsedLayout, this.options, true); | ||
return this.layout = new CompilableProgramInstance(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: true })); | ||
}; | ||
@@ -60,7 +59,3 @@ | ||
if (this.wrappedLayout) return this.wrappedLayout; | ||
var compileOptions = assign({}, this.options, { | ||
asPartial: false, | ||
referrer: this.referrer | ||
}); | ||
return this.wrappedLayout = new WrappedBuilder(compileOptions, this.parsedLayout); | ||
return this.wrappedLayout = new WrappedBuilder(this.compiler, Object.assign({}, this.parsedLayout, { asPartial: false })); | ||
}; | ||
@@ -70,12 +65,2 @@ | ||
}(); | ||
export function compilable(layout, options, asPartial) { | ||
var block = layout.block, | ||
referrer = layout.referrer; | ||
var hasEval = block.hasEval, | ||
symbols = block.symbols; | ||
var compileOptions = assign({}, options, { asPartial: asPartial, referrer: referrer }); | ||
return new CompilableTemplate(block.statements, layout, compileOptions, { referrer: referrer, hasEval: hasEval, symbols: symbols }); | ||
} | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGVtcGxhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3RlbXBsYXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQ0EsQUFBTyxTQUFFLEFBQU0sQUFBRSxjQUFNLEFBQWUsQUFBQztBQU12QyxPQUFPLEFBQWtCLHdCQUFNLEFBQXVCLEFBQUM7QUFFdkQsQUFBTyxTQUFFLEFBQWMsQUFBRSxzQkFBTSxBQUFxQixBQUFDO0FBZ0NyRCxJQUFJLEFBQVEsV0FBRyxBQUFDLEFBQUM7QUFTakIsQUFBTSxBQUFDLEFBQU8sd0JBQTBCO0FBQ3RDLFFBRDRDLEFBQVUsa0JBQWQsQUFBRTtRQUFjLEFBQUk7UUFBRSxBQUFLLEFBQXdDOztRQUN2RyxBQUFvQyxBQUFDLEFBQ3pDO1FBQUksQUFBRSxLQUFHLEFBQVUsQUFBSSwwQkFBVSxBQUFRLEFBQUUsQUFBRSxBQUFDLEFBQzlDO1FBQUksQUFBTSxTQUFHLGdCQUFDLEFBQWdDLFNBQUUsQUFBWSxTQUMxRDtZQUFJLEFBQU8sVUFBRyxBQUFPLFVBQUcsQUFBTSxPQUFDLEFBQUUsSUFBRSxBQUFPLFNBQUUsQUFB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sYXlvdXQ7XG4gICAgcmV0dXJuIHRoaXMubGF5b3V0ID0gbmV3IENvbXBpbGFibGVQcm9ncmFtSW5zdGFuY2UodGhpcy5jb21waWxlciwgeyAuLi50aGlzLnBhcnNlZExheW91dCwgYXNQYXJ0aWFsOiBmYWxzZSB9KTtcbiAgfVxuXG4gIGFzUGFydGlhbCgpOiBDb21waWxhYmxlUHJvZ3JhbSB7XG4gICAgaWYgKHRoaXMucGFydGlhbCkgcmV0dXJuIHRoaXMucGFydGlhbDtcbiAgICByZXR1cm4gdGhpcy5sYXlvdXQgPSBuZXcgQ29tcGlsYWJsZVByb2dyYW1JbnN0YW5jZSh0aGlzLmNvbXBpbGVyLCB7IC4uLnRoaXMucGFyc2VkTGF5b3V0LCBhc1BhcnRpYWw6IHRydWUgfSk7XG4gIH1cblxuICBhc1dyYXBwZWRMYXlvdXQoKTogQ29tcGlsYWJsZVByb2dyYW0ge1xuICAgIGlmICh0aGlzLndyYXBwZWRMYXlvdXQpIHJldHVybiB0aGlzLndyYXBwZWRMYXlvdXQ7XG4gICAgcmV0dXJuIHRoaXMud3JhcHBlZExheW91dCA9IG5ldyBXcmFwcGVkQnVpbGRlcih0aGlzLmNvbXBpbGVyLCB7IC4uLnRoaXMucGFyc2VkTGF5b3V0LCBhc1BhcnRpYWw6IGZhbHNlIH0pO1xuICB9XG59XG4iXX0= |
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } | ||
import { Register } from '@glimmer/vm'; | ||
import CompilableTemplate from './compilable-template'; | ||
import { debugSlice } from './debug'; | ||
import { debug } from './compiler'; | ||
import { CompilableBlock as CompilableBlockInstance } from './compilable-template'; | ||
import { ATTRS_BLOCK } from './syntax'; | ||
@@ -10,6 +10,6 @@ | ||
export var WrappedBuilder = function () { | ||
function WrappedBuilder(options, layout) { | ||
function WrappedBuilder(compiler, layout) { | ||
_classCallCheck(this, WrappedBuilder); | ||
this.options = options; | ||
this.compiler = compiler; | ||
this.layout = layout; | ||
@@ -52,12 +52,6 @@ var block = layout.block; | ||
// Exit | ||
var options = this.options, | ||
layout = this.layout, | ||
referrer = this.referrer; | ||
var program = options.program, | ||
resolver = options.resolver, | ||
macros = options.macros, | ||
asPartial = options.asPartial; | ||
var Builder = options.Builder; | ||
var compiler = this.compiler, | ||
layout = this.layout; | ||
var b = new Builder(program, resolver, referrer, macros, layout, asPartial); | ||
var b = compiler.builderFor(layout); | ||
b.startLabels(); | ||
@@ -76,3 +70,3 @@ b.fetch(Register.s1); | ||
b.label('BODY'); | ||
b.invokeStaticBlock(blockFor(layout, this.options)); | ||
b.invokeStaticBlock(blockFor(layout, compiler)); | ||
b.fetch(Register.s1); | ||
@@ -84,10 +78,5 @@ b.jumpUnless('END'); | ||
b.stopLabels(); | ||
var handle = b.commit(options.program.heap, layout.block.symbols.length); | ||
var handle = b.commit(); | ||
if (false) { | ||
var _program = options.program, | ||
heap = options.program.heap; | ||
var start = heap.getaddr(handle); | ||
var end = start + heap.sizeof(handle); | ||
debugSlice(_program, start, end); | ||
debug(compiler, handle); | ||
} | ||
@@ -99,7 +88,10 @@ return handle; | ||
}(); | ||
function blockFor(layout, options) { | ||
var block = layout.block, | ||
referrer = layout.referrer; | ||
return new CompilableTemplate(block.statements, layout, options, { referrer: referrer, parameters: EMPTY_ARRAY }); | ||
function blockFor(layout, compiler) { | ||
return new CompilableBlockInstance(compiler, { | ||
block: { | ||
statements: layout.block.statements, | ||
parameters: EMPTY_ARRAY | ||
}, | ||
containingLayout: layout | ||
}); | ||
} | ||
@@ -119,10 +111,11 @@ export var ComponentBuilder = function () { | ||
var builder = this.builder; | ||
var resolver = builder.resolver; | ||
if (handle !== null) { | ||
var capabilities = resolver.getCapabilities(handle); | ||
if (capabilities.dynamicLayout === false) { | ||
var layout = resolver.getLayout(handle); | ||
var _builder$compiler$res = builder.compiler.resolveLayoutForHandle(handle), | ||
capabilities = _builder$compiler$res.capabilities, | ||
compilable = _builder$compiler$res.compilable; | ||
if (compilable) { | ||
builder.pushComponentDefinition(handle); | ||
builder.invokeStaticComponent(capabilities, layout, null, params, hash, false, _default, inverse); | ||
builder.invokeStaticComponent(capabilities, compilable, null, params, hash, false, _default, inverse); | ||
} else { | ||
@@ -137,2 +130,2 @@ builder.pushComponentDefinition(handle); | ||
}(); | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcGNvZGUtY29tcGlsZXIvbGliL3dyYXBwZWQtY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsQUFBTyxTQUFFLEFBQVEsQUFBRSxnQkFBTSxBQUFhLEFBQUM7QUFVdkMsT0FBTyxBQUFrQix3QkFBTSxBQUF1QixBQUFDO0FBQ3ZELEFBQU8sU0FBRSxBQUFVLEFBQUUsa0JBQU0sQUFBUyxBQUFDO0FBRXJDLEFBQU8sU0FBRSxBQUFXLEFBQUUsbUJBQU0sQUFBVSxBQUFDLEFBRXZDLEFBQU8sQUFBRSxBQUFLLEFBQUUsQUFBTSxBQUE0QixBQUFDOztBQUNuRCxBQUFPLFNBQUUsQUFBVyxBQUFFLG1CQUFNLEFBQWUsQUFBQztBQUU1QyxBQUFNLFdBSUo7NEJBQW1CLEFBQXFDLFNBQVUsQUFBa0M7QUFBakY7O2FBQU8sVUFBUCxBQUFPLEFBQThCLEFBQVU7YUFBTSxTQUFOLEFBQU0sQUFBNEIsQUFDbEcsQUFBSTtZQUFFLEFBQUssQUFBRSxRQUFHLEFBQU0sQUFBQyxBQUV2QixBQUFJOzthQUFDLEFBQVc7cUJBQ0wsQUFBSyxNQUFDLEFBQU8sQUFDdEIsQUFBTztxQkFBRSxBQUFLLE1BQUMsQUFBTyxRQUFDLEFBQU0sT0FBQyxDQ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0IHsgYmxvY2sgfSA9IGxheW91dDtcblxuICAgIHRoaXMuc3ltYm9sVGFibGUgPSB7XG4gICAgICBoYXNFdmFsOiBibG9jay5oYXNFdmFsLFxuICAgICAgc3ltYm9sczogYmxvY2suc3ltYm9scy5jb25jYXQoW0FUVFJTX0JMT0NLXSlcbiAgICB9O1xuICB9XG5cbiAgY29tcGlsZSgpOiBudW1iZXIge1xuICAgIC8vPT09PT09PT1EWU5BTUlDXG4gICAgLy8gICAgICAgIFB1dFZhbHVlKFRhZ0V4cHIpXG4gICAgLy8gICAgICAgIFRlc3RcbiAgICAvLyAgICAgICAgSnVtcFVubGVzcyhCT0RZKVxuICAgIC8vICAgICAgICBPcGVuRHluYW1pY1ByaW1pdGl2ZUVsZW1lbnRcbiAgICAvLyAgICAgICAgRGlkQ3JlYXRlRWxlbWVudFxuICAgIC8vICAgICAgICAuLi5hdHRyIHN0YXRlbWVudHMuLi5cbiAgICAvLyAgICAgICAgRmx1c2hFbGVtZW50XG4gICAgLy8gQk9EWTogIE5vb3BcbiAgICAvLyAgICAgICAgLi4uYm9keSBzdGF0ZW1lbnRzLi4uXG4gICAgLy8gICAgICAgIFB1dFZhbHVlKFRhZ0V4cHIpXG4gICAgLy8gICAgICAgIFRlc3RcbiAgICAvLyAgICAgICAgSnVtcFVubGVzcyhFTkQpXG4gICAgLy8gICAgICAgIENsb3NlRWxlbWVudFxuICAgIC8vIEVORDogICBOb29wXG4gICAgLy8gICAgICAgIERpZFJlbmRlckxheW91dFxuICAgIC8vICAgICAgICBFeGl0XG4gICAgLy9cbiAgICAvLz09PT09PT09U1RBVElDXG4gICAgLy8gICAgICAgIE9wZW5QcmltaXRpdmVFbGVtZW50T3Bjb2RlXG4gICAgLy8gICAgICAgIERpZENyZWF0ZUVsZW1lbnRcbiAgICAvLyAgICAgICAgLi4uYXR0ciBzdGF0ZW1lbnRzLi4uXG4gICAgLy8gICAgICAgIEZsdXNoRWxlbWVudFxuICAgIC8vICAgICAgICAuLi5ib2R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t9XG5cbiAgc3RhdGljKGhhbmRsZTogbnVtYmVyLCBhcmdzOiBDb21wb25lbnRBcmdzKSB7XG4gICAgbGV0IFtwYXJhbXMsIGhhc2gsIF9kZWZhdWx0LCBpbnZlcnNlXSA9IGFyZ3M7XG4gICAgbGV0IHsgYnVpbGRlciB9ID0gdGhpcztcbiAgICBsZXQgeyByZXNvbHZlciB9ID0gYnVpbGRlcjtcblxuICAgIGlmIChoYW5kbGUgIT09IG51bGwpIHtcbiAgICAgIGxldCBjYXBhYmlsaXRpZXMgPSByZXNvbHZlci5nZXRDYXBhYmlsaXRpZXMoaGFuZGxlKTtcblxuICAgICAgaWYgKGNhcGFiaWxpdGllcy5keW5hbWljTGF5b3V0ID09PSBmYWxzZSkge1xuICAgICAgICBsZXQgbGF5b3V0ID0gcmVzb2x2ZXIuZ2V0TGF5b3V0KGhhbmRsZSkhO1xuXG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VTdGF0aWNDb21wb25lbnQoY2FwYWJpbGl0aWVzLCBsYXlvdXQsIG51bGwsIHBhcmFtcywgaGFzaCwgZmFsc2UsIF9kZWZhdWx0LCBpbnZlcnNlKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VDb21wb25lbnQobnVsbCwgcGFyYW1zLCBoYXNoLCBmYWxzZSwgX2RlZmF1bHQsIGludmVyc2UpO1xuICAgICAgfVxuICAgIH1cbiAgfVxufVxuIl19 | ||
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3JhcHBlZC1jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9wYWNrYWdlcy9AZ2xpbW1lci9vcG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xlKSB7XG4gICAgICAgIGJ1aWxkZXIucHVzaENvbXBvbmVudERlZmluaXRpb24oaGFuZGxlKTtcbiAgICAgICAgYnVpbGRlci5pbnZva2VTdGF0aWNDb21wb25lbnQoY2FwYWJpbGl0aWVzLCBjb21waWxhYmxlLCBudWxsLCBwYXJhbXMsIGhhc2gsIGZhbHNlLCBfZGVmYXVsdCwgaW52ZXJzZSk7XG4gICAgICB9IGVsc2Uge1xuICAgICAgICBidWlsZGVyLnB1c2hDb21wb25lbnREZWZpbml0aW9uKGhhbmRsZSk7XG4gICAgICAgIGJ1aWxkZXIuaW52b2tlQ29tcG9uZW50KG51bGwsIHBhcmFtcywgaGFzaCwgZmFsc2UsIF9kZWZhdWx0LCBpbnZlcnNlKTtcbiAgICAgIH1cbiAgICB9XG4gIH1cbn1cbiJdfQ== |
export * from './lib/interfaces'; | ||
export { ATTRS_BLOCK, CompileOptions, Macros, TemplateOptions } from './lib/syntax'; | ||
export { CompileTimeLookup, LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, OpcodeBuilderConstructor, SimpleOpcodeBuilder } from './lib/opcode-builder'; | ||
export { ATTRS_BLOCK, CompileOptions, Macros } from './lib/syntax'; | ||
export * from './lib/lazy'; | ||
export * from './lib/compile'; | ||
export * from './lib/compiler'; | ||
export { CompilableBlock, CompilableProgram } from './lib/compilable-template'; | ||
export { LazyOpcodeBuilder, EagerOpcodeBuilder, OpcodeBuilder, OpcodeBuilderConstructor, StdOpcodeBuilder } from './lib/opcode-builder'; | ||
export { PartialDefinition } from './lib/partial-template'; | ||
export { default as templateFactory, TemplateFactory } from './lib/template'; | ||
export { default as CompilableTemplate } from './lib/compilable-template'; | ||
export { debug, debugSlice, logOpcode } from './lib/debug'; | ||
export { WrappedBuilder } from './lib/wrapped-component'; |
@@ -1,16 +0,18 @@ | ||
import { CompilableTemplate, STDLib, CompilableProgram } from '@glimmer/interfaces'; | ||
import { Statement, SerializedTemplateBlock } from '@glimmer/wire-format'; | ||
import { ParsedLayout } from './interfaces'; | ||
import { CompileOptions } from './syntax'; | ||
import { CompilableTemplate, ProgramSymbolTable, CompilableProgram as ICompilableProgram, LayoutWithContext, Opaque, Compiler, BlockSymbolTable, BlockWithContext } from '@glimmer/interfaces'; | ||
export declare const PLACEHOLDER_HANDLE = -1; | ||
export default class CompilableTemplateImpl<SymbolTable, TemplateMeta> implements CompilableTemplate<SymbolTable> { | ||
private statements; | ||
private containingLayout; | ||
private options; | ||
symbolTable: SymbolTable; | ||
static topLevel<TemplateMeta>(block: SerializedTemplateBlock, options: CompileOptions<TemplateMeta>): CompilableProgram; | ||
export declare class CompilableProgram implements ICompilableProgram { | ||
protected compiler: Compiler<Opaque>; | ||
protected layout: LayoutWithContext; | ||
private compiled; | ||
private statementCompiler; | ||
constructor(statements: Statement[], containingLayout: ParsedLayout, options: CompileOptions<TemplateMeta>, symbolTable: SymbolTable); | ||
compile(stdLib?: STDLib): number; | ||
constructor(compiler: Compiler<Opaque>, layout: LayoutWithContext); | ||
readonly symbolTable: ProgramSymbolTable; | ||
compile(): number; | ||
} | ||
export declare class CompilableBlock implements CompilableTemplate<BlockSymbolTable> { | ||
private compiler; | ||
private parsed; | ||
private compiled; | ||
constructor(compiler: Compiler<Opaque>, parsed: BlockWithContext); | ||
readonly symbolTable: BlockSymbolTable; | ||
compile(): number; | ||
} |
@@ -13,2 +13,2 @@ import { CompileTimeProgram, Option } from '@glimmer/interfaces'; | ||
export declare function logOpcode(type: string, params: Option<Object>): string | void; | ||
export declare function debug(c: DebugConstants, op: Op, ...operands: number[]): [string, object]; | ||
export declare function debug(pos: number, c: DebugConstants, op: Op, ...operands: number[]): [string, object]; |
@@ -1,3 +0,3 @@ | ||
import { Opaque, Option, CompilableBlock, ComponentCapabilities, CompileTimeProgram } from '@glimmer/interfaces'; | ||
import { Core, SerializedTemplateBlock } from '@glimmer/wire-format'; | ||
import { Option, CompilableBlock, ComponentCapabilities, CompileTimeProgram } from '@glimmer/interfaces'; | ||
import { Core } from '@glimmer/wire-format'; | ||
import { Macros } from './syntax'; | ||
@@ -7,3 +7,3 @@ export interface EagerResolver<Locator> { | ||
} | ||
export interface EagerCompilationOptions<TemplateMeta, R extends EagerResolver<TemplateMeta>> { | ||
export interface EagerCompilationOptions<Locator, R extends EagerResolver<Locator>> { | ||
resolver: R; | ||
@@ -19,6 +19,1 @@ program: CompileTimeProgram; | ||
} | ||
export interface ParsedLayout<TemplateMeta = Opaque> { | ||
id?: Option<string>; | ||
block: SerializedTemplateBlock; | ||
referrer: TemplateMeta; | ||
} |
@@ -1,18 +0,9 @@ | ||
import { Opaque, Option, VMHandle, ComponentCapabilities, CompilableTemplate, CompilableBlock, CompilableProgram, CompileTimeConstants, CompileTimeProgram, CompileTimeLazyConstants, CompileTimeHeap, STDLib, SymbolTable } from "@glimmer/interfaces"; | ||
import { Opaque, Option, VMHandle, ComponentCapabilities, CompilableTemplate, CompilableBlock, CompilableProgram, CompileTimeConstants, CompileTimeLazyConstants, STDLib, SymbolTable, Compiler, LayoutWithContext } from "@glimmer/interfaces"; | ||
import { Op, Register } from '@glimmer/vm'; | ||
import * as WireFormat from '@glimmer/wire-format'; | ||
import { SerializedInlineBlock } from "@glimmer/wire-format"; | ||
import { Primitive, ParsedLayout } from './interfaces'; | ||
import { Macros } from './syntax'; | ||
import { Primitive } from './interfaces'; | ||
import { ComponentBuilder } from './wrapped-component'; | ||
import { InstructionEncoder, Operand } from "@glimmer/encoder"; | ||
export declare type Label = string; | ||
export interface CompileTimeLookup<TemplateMeta> { | ||
getCapabilities(handle: number): ComponentCapabilities; | ||
getLayout(handle: number): Option<CompilableProgram>; | ||
lookupHelper(name: string, referrer: TemplateMeta): Option<number>; | ||
lookupModifier(name: string, referrer: TemplateMeta): Option<number>; | ||
lookupComponentDefinition(name: string, referrer: TemplateMeta): Option<number>; | ||
lookupPartial(name: string, referrer: TemplateMeta): Option<number>; | ||
} | ||
export interface Blocks { | ||
@@ -24,6 +15,11 @@ main: Option<CompilableBlock>; | ||
export interface OpcodeBuilderConstructor { | ||
new <TemplateMeta>(program: CompileTimeProgram, lookup: CompileTimeLookup<TemplateMeta>, meta: Opaque, macros: Macros, containingLayout: ParsedLayout, asPartial: boolean, stdLib?: STDLib): OpcodeBuilder<TemplateMeta>; | ||
new <Locator>(compiler: Compiler, containingLayout: LayoutWithContext): OpcodeBuilder<Locator>; | ||
} | ||
export declare class SimpleOpcodeBuilder { | ||
export declare class StdOpcodeBuilder { | ||
protected size: number; | ||
static build(compiler: Compiler, callback: (builder: StdOpcodeBuilder) => void): number; | ||
protected encoder: InstructionEncoder; | ||
compiler: Compiler<this>; | ||
private labelsStack; | ||
constructor(compiler: Compiler, size?: number); | ||
push(name: Op): void; | ||
@@ -37,7 +33,12 @@ push(name: Op, arg1: Operand): void; | ||
pushMachine(name: Op, arg1: Operand, arg2: Operand, arg3: Operand): void; | ||
commit(heap: CompileTimeHeap, scopeSize: number): number; | ||
commit(): number; | ||
reserve(name: Op): void; | ||
reserveWithOperand(name: Op, operand: number): void; | ||
reserveMachine(name: Op): void; | ||
main(): void; | ||
dynamicContent(): void; | ||
appendHTML(): void; | ||
appendSafeHTML(): void; | ||
appendDocumentFragment(): void; | ||
appendNode(): void; | ||
appendText(): void; | ||
beginComponentTransaction(): void; | ||
@@ -70,42 +71,13 @@ commitComponentTransaction(): void; | ||
protected readonly nextPos: number; | ||
} | ||
export declare type VMHandlePlaceholder = [number, () => VMHandle]; | ||
export declare abstract class OpcodeBuilder<Locator> extends SimpleOpcodeBuilder { | ||
program: CompileTimeProgram; | ||
resolver: CompileTimeLookup<Locator>; | ||
referrer: Locator; | ||
macros: Macros; | ||
containingLayout: ParsedLayout; | ||
asPartial: boolean; | ||
protected stdLib: STDLib | undefined; | ||
constants: CompileTimeConstants; | ||
component: ComponentBuilder<Locator>; | ||
private expressionCompiler; | ||
private labelsStack; | ||
private isComponentAttrs; | ||
constructor(program: CompileTimeProgram, resolver: CompileTimeLookup<Locator>, referrer: Locator, macros: Macros, containingLayout: ParsedLayout, asPartial: boolean, stdLib?: STDLib | undefined); | ||
compileInline(sexp: WireFormat.Statements.Append): true | ["expr", WireFormat.Expressions.Expression]; | ||
compileBlock(name: string, params: WireFormat.Core.Params, hash: WireFormat.Core.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>): void; | ||
label(name: string): void; | ||
setComponentAttrs(enabled: boolean): void; | ||
expr(expression: WireFormat.Expression): void; | ||
pushArgs(names: string[], flags: number): void; | ||
private readonly labels; | ||
startLabels(): void; | ||
stopLabels(): void; | ||
pushComponentDefinition(handle: number): void; | ||
pushCurriedComponent(): void; | ||
pushDynamicComponentInstance(): void; | ||
resolveDynamicComponent(referrer: Locator): void; | ||
staticComponentHelper(tag: string, hash: WireFormat.Core.Hash, template: Option<CompilableBlock>): boolean; | ||
invokePartial(referrer: Locator, symbols: string[], evalInfo: number[]): void; | ||
resolveMaybeLocal(name: string): void; | ||
debugger(symbols: string[], evalInfo: number[]): void; | ||
text(text: string): void; | ||
openPrimitiveElement(tag: string): void; | ||
openDynamicElement(): void; | ||
flushElement(): void; | ||
closeElement(): void; | ||
staticAttr(_name: string, _namespace: Option<string>, _value: string): void; | ||
dynamicAttr(_name: string, _namespace: Option<string>, trusting: boolean): void; | ||
comment(_comment: string): void; | ||
modifier(locator: Locator, params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>): void; | ||
putIterator(): void; | ||
@@ -118,6 +90,4 @@ enterList(start: string): void; | ||
getVariable(symbol: number): void; | ||
getProperty(key: string): void; | ||
getBlock(symbol: number): void; | ||
hasBlock(symbol: number): void; | ||
hasBlockParams(to: number): void; | ||
concat(size: number): void; | ||
@@ -129,8 +99,4 @@ load(register: Register): void; | ||
returnTo(label: string): void; | ||
primitive(_primitive: Primitive): void; | ||
sizeImmediate(shifted: number, primitive: number): number; | ||
pushPrimitiveReference(primitive: Primitive): void; | ||
primitiveReference(): void; | ||
helper(helper: Locator, params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>): void; | ||
bindDynamicScope(_names: string[]): void; | ||
reifyU32(): void; | ||
enter(args: number): void; | ||
@@ -142,19 +108,21 @@ exit(): void; | ||
jumpUnless(target: string): void; | ||
string(_string: string): number; | ||
protected names(_names: string[]): number; | ||
protected symbols(symbols: number[]): number; | ||
inlineBlock(block: SerializedInlineBlock): CompilableBlock; | ||
evalSymbols(): Option<string[]>; | ||
compileParams(params: Option<WireFormat.Core.Params>): number; | ||
compileArgs(params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>, blocks: Option<Blocks>, synthetic: boolean): void; | ||
invokeStaticBlock(block: CompilableBlock, callerCount?: number): void; | ||
builtInGuardedAppend(): void; | ||
guardedAppend(expression: WireFormat.Expression, trusting: boolean): void; | ||
yield(to: number, params: Option<WireFormat.Core.Params>): void; | ||
jumpEq(value: number, target: string): void; | ||
assertSame(): void; | ||
pushEmptyArgs(): void; | ||
stdAppend(trusting: boolean): void; | ||
populateLayout(state: number): void; | ||
invokeComponent(attrs: Option<CompilableBlock>, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>, layout?: CompilableProgram): void; | ||
invokeStaticComponent(capabilities: ComponentCapabilities, layout: CompilableProgram, attrs: Option<CompilableBlock>, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>): void; | ||
dynamicComponent(definition: WireFormat.Expression, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>): void; | ||
invokeBareComponent(): void; | ||
isComponent(): void; | ||
curryComponent(definition: WireFormat.Expression, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean): void; | ||
contentType(): void; | ||
pushBlockScope(): void; | ||
} | ||
export declare type VMHandlePlaceholder = [number, () => VMHandle]; | ||
export declare abstract class OpcodeBuilder<Locator = Opaque> extends StdOpcodeBuilder { | ||
containingLayout: LayoutWithContext<Locator>; | ||
constants: CompileTimeConstants; | ||
stdLib: STDLib; | ||
component: ComponentBuilder<Locator>; | ||
private expressionCompiler; | ||
private isComponentAttrs; | ||
constructor(compiler: Compiler, containingLayout: LayoutWithContext<Locator>); | ||
abstract pushBlock(block: Option<CompilableBlock>): void; | ||
@@ -165,9 +133,45 @@ abstract resolveBlock(): void; | ||
abstract resolveLayout(): void; | ||
readonly referrer: Locator; | ||
setComponentAttrs(enabled: boolean): void; | ||
expr(expression: WireFormat.Expression): void; | ||
pushArgs(names: string[], flags: number): void; | ||
pushYieldableBlock(block: Option<CompilableBlock>): void; | ||
curryComponent(definition: WireFormat.Expression, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean): void; | ||
pushSymbolTable(table: Option<SymbolTable>): void; | ||
pushBlockScope(): void; | ||
pushYieldableBlock(block: Option<CompilableBlock>): void; | ||
invokeComponent(attrs: Option<CompilableBlock>, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>, layout?: CompilableProgram): void; | ||
invokeStaticComponent(capabilities: ComponentCapabilities, layout: CompilableProgram, attrs: Option<CompilableBlock>, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>): void; | ||
dynamicComponent(definition: WireFormat.Expression, params: Option<WireFormat.Core.Params>, hash: WireFormat.Core.Hash, synthetic: boolean, block: Option<CompilableBlock>, inverse?: Option<CompilableBlock>): void; | ||
yield(to: number, params: Option<WireFormat.Core.Params>): void; | ||
guardedAppend(expression: WireFormat.Expression, trusting: boolean): void; | ||
invokeStaticBlock(block: CompilableBlock, callerCount?: number): void; | ||
string(_string: string): number; | ||
protected names(_names: string[]): number; | ||
protected symbols(symbols: number[]): number; | ||
primitive(_primitive: Primitive): void; | ||
sizeImmediate(shifted: number, primitive: number): number; | ||
pushPrimitiveReference(primitive: Primitive): void; | ||
pushComponentDefinition(handle: number): void; | ||
resolveDynamicComponent(referrer: Locator): void; | ||
staticComponentHelper(tag: string, hash: WireFormat.Core.Hash, template: Option<CompilableBlock>): boolean; | ||
invokePartial(referrer: Locator, symbols: string[], evalInfo: number[]): void; | ||
resolveMaybeLocal(name: string): void; | ||
debugger(symbols: string[], evalInfo: number[]): void; | ||
text(text: string): void; | ||
openPrimitiveElement(tag: string): void; | ||
modifier(locator: Locator, params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>): void; | ||
comment(_comment: string): void; | ||
dynamicAttr(_name: string, _namespace: Option<string>, trusting: boolean): void; | ||
staticAttr(_name: string, _namespace: Option<string>, _value: string): void; | ||
hasBlockParams(to: number): void; | ||
getProperty(key: string): void; | ||
helper(helper: Locator, params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>): void; | ||
bindDynamicScope(_names: string[]): void; | ||
inlineBlock(block: SerializedInlineBlock): CompilableBlock; | ||
evalSymbols(): Option<string[]>; | ||
compileParams(params: Option<WireFormat.Core.Params>): number; | ||
compileArgs(params: Option<WireFormat.Core.Params>, hash: Option<WireFormat.Core.Hash>, blocks: Option<Blocks>, synthetic: boolean): void; | ||
template(block: Option<WireFormat.SerializedInlineBlock>): Option<CompilableBlock>; | ||
} | ||
export default OpcodeBuilder; | ||
export declare class LazyOpcodeBuilder<TemplateMeta> extends OpcodeBuilder<TemplateMeta> { | ||
export declare class LazyOpcodeBuilder<Locator> extends OpcodeBuilder<Locator> { | ||
constants: CompileTimeLazyConstants; | ||
@@ -182,3 +186,3 @@ pushBlock(block: Option<CompilableBlock>): void; | ||
} | ||
export declare class EagerOpcodeBuilder<TemplateMeta> extends OpcodeBuilder<TemplateMeta> { | ||
export declare class EagerOpcodeBuilder<Locator> extends OpcodeBuilder<Locator> { | ||
pushBlock(block: Option<CompilableBlock>): void; | ||
@@ -185,0 +189,0 @@ resolveBlock(): void; |
@@ -1,4 +0,4 @@ | ||
import { CompilableBlock, CompileTimeProgram, Option } from '@glimmer/interfaces'; | ||
import { CompilableBlock, Option, Opaque, Compiler } from '@glimmer/interfaces'; | ||
import * as WireFormat from '@glimmer/wire-format'; | ||
import OpcodeBuilder, { CompileTimeLookup, OpcodeBuilderConstructor } from "./opcode-builder"; | ||
import OpcodeBuilder from "./opcode-builder"; | ||
import S = WireFormat.Statements; | ||
@@ -8,5 +8,5 @@ import E = WireFormat.Expressions; | ||
export declare type TupleSyntax = WireFormat.Statement | WireFormat.TupleExpression; | ||
export declare type CompilerFunction<T extends TupleSyntax, TemplateMeta> = ((sexp: T, builder: OpcodeBuilder<TemplateMeta>) => void); | ||
export declare type CompilerFunction<T extends TupleSyntax> = ((sexp: T, builder: OpcodeBuilder<Opaque>) => void); | ||
export declare const ATTRS_BLOCK = "&attrs"; | ||
export declare class Compilers<T extends TupleSyntax> { | ||
export declare class Compilers<Syntax extends TupleSyntax> { | ||
private offset; | ||
@@ -16,6 +16,6 @@ private names; | ||
constructor(offset?: number); | ||
add<TemplateMeta>(name: number, func: CompilerFunction<T, TemplateMeta>): void; | ||
compile<TemplateMeta>(sexp: T, builder: OpcodeBuilder<TemplateMeta>): void; | ||
add<T extends Syntax>(name: number, func: (sexp: T, builder: OpcodeBuilder<Opaque>) => void): void; | ||
compile(sexp: Syntax, builder: OpcodeBuilder<Opaque>): void; | ||
} | ||
export declare function statementCompiler(): Compilers<S.Statement>; | ||
export declare function statementCompiler(): Compilers<WireFormat.Statement>; | ||
export declare function expressionCompiler(): Compilers<E.TupleExpression>; | ||
@@ -27,4 +27,4 @@ export declare class Macros { | ||
} | ||
export declare type BlockMacro<TemplateMeta> = (params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<TemplateMeta>) => void; | ||
export declare type MissingBlockMacro<TemplateMeta> = (name: string, params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<TemplateMeta>) => void; | ||
export declare type BlockMacro<Locator> = (params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<Locator>) => void; | ||
export declare type MissingBlockMacro<Locator> = (name: string, params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<Locator>) => void; | ||
export declare class Blocks { | ||
@@ -34,8 +34,8 @@ private names; | ||
private missing; | ||
add<TemplateMeta>(name: string, func: BlockMacro<TemplateMeta>): void; | ||
addMissing<TemplateMeta>(func: MissingBlockMacro<TemplateMeta>): void; | ||
compile<TemplateMeta>(name: string, params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<TemplateMeta>): void; | ||
add<Locator>(name: string, func: BlockMacro<Locator>): void; | ||
addMissing<Locator>(func: MissingBlockMacro<Locator>): void; | ||
compile<Locator>(name: string, params: C.Params, hash: C.Hash, template: Option<CompilableBlock>, inverse: Option<CompilableBlock>, builder: OpcodeBuilder<Locator>): void; | ||
} | ||
export declare type AppendSyntax = S.Append; | ||
export declare type AppendMacro<TemplateMeta> = (name: string, params: Option<C.Params>, hash: Option<C.Hash>, builder: OpcodeBuilder<TemplateMeta>) => ['expr', WireFormat.Expression] | true | false; | ||
export declare type AppendMacro<Locator> = (name: string, params: Option<C.Params>, hash: Option<C.Hash>, builder: OpcodeBuilder<Locator>) => ['expr', WireFormat.Expression] | true | false; | ||
export declare class Inlines { | ||
@@ -45,5 +45,5 @@ private names; | ||
private missing; | ||
add<TemplateMeta>(name: string, func: AppendMacro<TemplateMeta>): void; | ||
addMissing<TemplateMeta>(func: AppendMacro<TemplateMeta>): void; | ||
compile<TemplateMeta>(sexp: AppendSyntax, builder: OpcodeBuilder<TemplateMeta>): ['expr', WireFormat.Expression] | true; | ||
add<Locator>(name: string, func: AppendMacro<Locator>): void; | ||
addMissing<Locator>(func: AppendMacro<Locator>): void; | ||
compile<Locator>(sexp: AppendSyntax, builder: OpcodeBuilder<Locator>): ['expr', WireFormat.Expression] | true; | ||
} | ||
@@ -54,11 +54,6 @@ export declare function populateBuiltins(blocks?: Blocks, inlines?: Inlines): { | ||
}; | ||
export interface TemplateOptions<TemplateMeta> { | ||
program: CompileTimeProgram; | ||
macros: Macros; | ||
Builder: OpcodeBuilderConstructor; | ||
resolver: CompileTimeLookup<TemplateMeta>; | ||
} | ||
export interface CompileOptions<TemplateMeta> extends TemplateOptions<TemplateMeta> { | ||
export interface CompileOptions<Locator, Builder = Opaque> { | ||
compiler: Compiler<Builder>; | ||
asPartial: boolean; | ||
referrer: TemplateMeta; | ||
referrer: Locator; | ||
} |
@@ -1,7 +0,5 @@ | ||
import { Template, Opaque } from '@glimmer/interfaces'; | ||
import { Template } from '@glimmer/interfaces'; | ||
import { SerializedTemplateWithLazyBlock } from '@glimmer/wire-format'; | ||
import CompilableTemplate from './compilable-template'; | ||
import { ParsedLayout } from './interfaces'; | ||
import { TemplateOptions } from "./syntax"; | ||
export interface TemplateFactory<TemplateMeta> { | ||
import { LazyCompiler } from "@glimmer/opcode-compiler"; | ||
export interface TemplateFactory<Locator> { | ||
/** | ||
@@ -15,3 +13,3 @@ * Template identifier, if precompiled will be the id of the | ||
*/ | ||
meta: TemplateMeta; | ||
meta: Locator; | ||
/** | ||
@@ -23,3 +21,3 @@ * Used to create an environment specific singleton instance | ||
*/ | ||
create(env: TemplateOptions<Opaque>): Template<TemplateMeta>; | ||
create(env: LazyCompiler<Locator>): Template<Locator>; | ||
/** | ||
@@ -32,3 +30,3 @@ * Used to create an environment specific singleton instance | ||
*/ | ||
create<U>(env: TemplateOptions<Opaque>, meta: U): Template<TemplateMeta & U>; | ||
create<U>(env: LazyCompiler<Locator>, meta: U): Template<Locator & U>; | ||
} | ||
@@ -40,8 +38,3 @@ /** | ||
*/ | ||
export default function templateFactory<TemplateMeta>(serializedTemplate: SerializedTemplateWithLazyBlock<TemplateMeta>): TemplateFactory<TemplateMeta>; | ||
export default function templateFactory<TemplateMeta, U>(serializedTemplate: SerializedTemplateWithLazyBlock<TemplateMeta>): TemplateFactory<TemplateMeta & U>; | ||
export declare function compilable<TemplateMeta>(layout: ParsedLayout<TemplateMeta>, options: TemplateOptions<Opaque>, asPartial: boolean): CompilableTemplate<{ | ||
referrer: TemplateMeta; | ||
hasEval: boolean; | ||
symbols: string[]; | ||
}, Opaque>; | ||
export default function templateFactory<Locator>(serializedTemplate: SerializedTemplateWithLazyBlock<Locator>): TemplateFactory<Locator>; | ||
export default function templateFactory<Locator, U>(serializedTemplate: SerializedTemplateWithLazyBlock<Locator>): TemplateFactory<Locator & U>; |
@@ -1,17 +0,15 @@ | ||
import { ProgramSymbolTable, CompilableProgram } from '@glimmer/interfaces'; | ||
import { ComponentArgs, ComponentBuilder as IComponentBuilder, ParsedLayout } from './interfaces'; | ||
import { CompileOptions } from './syntax'; | ||
import { ProgramSymbolTable, CompilableProgram, LayoutWithContext, Compiler } from '@glimmer/interfaces'; | ||
import { ComponentArgs, ComponentBuilder as IComponentBuilder } from './interfaces'; | ||
import { OpcodeBuilder } from './opcode-builder'; | ||
export declare class WrappedBuilder<TemplateMeta> implements CompilableProgram { | ||
options: CompileOptions<TemplateMeta>; | ||
export declare class WrappedBuilder<Locator> implements CompilableProgram { | ||
private compiler; | ||
private layout; | ||
symbolTable: ProgramSymbolTable; | ||
private referrer; | ||
constructor(options: CompileOptions<TemplateMeta>, layout: ParsedLayout<TemplateMeta>); | ||
constructor(compiler: Compiler<OpcodeBuilder<Locator>>, layout: LayoutWithContext<Locator>); | ||
compile(): number; | ||
} | ||
export declare class ComponentBuilder<TemplateMeta> implements IComponentBuilder { | ||
export declare class ComponentBuilder<Locator> implements IComponentBuilder { | ||
private builder; | ||
constructor(builder: OpcodeBuilder<TemplateMeta>); | ||
constructor(builder: OpcodeBuilder<Locator>); | ||
static(handle: number, args: ComponentArgs): void; | ||
} |
{ | ||
"name": "@glimmer/opcode-compiler", | ||
"version": "0.32.2", | ||
"version": "0.32.3", | ||
"repository": "https://github.com/glimmerjs/glimmer-vm/tree/master/packages/@glimmer/opcode-compiler", | ||
"dependencies": { | ||
"@glimmer/util": "^0.32.2", | ||
"@glimmer/wire-format": "^0.32.2", | ||
"@glimmer/interfaces": "^0.32.2", | ||
"@glimmer/program": "^0.32.2", | ||
"@glimmer/vm": "^0.32.2", | ||
"@glimmer/encoder": "^0.32.2", | ||
"@glimmer/reference": "^0.32.2" | ||
"@glimmer/util": "^0.32.3", | ||
"@glimmer/wire-format": "^0.32.3", | ||
"@glimmer/interfaces": "^0.32.3", | ||
"@glimmer/program": "^0.32.3", | ||
"@glimmer/vm": "^0.32.3", | ||
"@glimmer/encoder": "^0.32.3", | ||
"@glimmer/reference": "^0.32.3" | ||
}, | ||
"devDependencies": { | ||
"@glimmer/local-debug-flags": "^0.32.2", | ||
"@glimmer/local-debug-flags": "^0.32.3", | ||
"typescript": "^2.2.0" | ||
@@ -17,0 +17,0 @@ }, |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1320204
68
10827
Updated@glimmer/encoder@^0.32.3
Updated@glimmer/interfaces@^0.32.3
Updated@glimmer/program@^0.32.3
Updated@glimmer/reference@^0.32.3
Updated@glimmer/util@^0.32.3
Updated@glimmer/vm@^0.32.3
Updated@glimmer/wire-format@^0.32.3