Comparing version 0.0.61 to 0.0.62
{ | ||
"name": "traceur", | ||
"version": "0.0.61", | ||
"version": "0.0.62", | ||
"description": "ES6 to ES5 compiler", | ||
@@ -57,3 +57,3 @@ "keywords": [ | ||
"semver": "2.x", | ||
"traceur": "0.0.60", | ||
"traceur": "0.0.61", | ||
"promises-aplus-tests": "2.x", | ||
@@ -60,0 +60,0 @@ "compat-table": "git+https://github.com/kangax/compat-table.git#gh-pages", |
@@ -33,4 +33,7 @@ // Copyright 2013 Traceur Authors. | ||
function compile(src, options) { | ||
return new NodeCompiler(Compiler.commonJSOptions(options)).compile(src); | ||
function compile(src, options, sourceName, outputName) { | ||
sourceName = sourceName || '<compile-source>'; | ||
outputName = outputName || '<compile-output>'; | ||
return new NodeCompiler(Compiler.commonJSOptions(options)). | ||
compile(src, sourceName, outputName); | ||
} | ||
@@ -37,0 +40,0 @@ |
@@ -128,3 +128,2 @@ // Copyright 2013 Traceur Authors. | ||
if (isSingleFileCompile) { | ||
commandOptions.filename = out; | ||
traceurAPI.recursiveModuleCompileToSingleFile(out, rootSources, | ||
@@ -131,0 +130,0 @@ commandOptions).then(function() { |
@@ -54,5 +54,5 @@ // Copyright 2014 Traceur Authors. | ||
// Assume that the .map and .js will be in the same subdirectory, | ||
// Use the rule from Source Map Revision 3: | ||
// If the generated code is associated with a script element and the | ||
// script element has a “src” attribute, the “src” attribute of the script | ||
// Use the rule from Source Map Revision 3: | ||
// If the generated code is associated with a script element and the | ||
// script element has a “src” attribute, the “src” attribute of the script | ||
// element will be the source origin. | ||
@@ -73,5 +73,4 @@ var sourceMapFilePath = path.basename(filename.replace(/\.js$/, '.map')); | ||
this.options_.filename = inputFilePath; | ||
this.writeTreeToFile(this.transform(this.parse(contents.toString())), | ||
outputFilePath); | ||
this.writeTreeToFile(this.transform( | ||
this.parse(contents.toString(), inputFilePath)), outputFilePath); | ||
}.bind(this)); | ||
@@ -78,0 +77,0 @@ } |
@@ -135,4 +135,4 @@ // Copyright 2012 Traceur Authors. | ||
// Create tree for System.get('normalizedName'); | ||
var tree = | ||
traceur.codegeneration.module.createModuleEvaluationStatement(normalizedName); | ||
var moduleModule = traceur.codegeneration.module; | ||
var tree = moduleModule.createModuleEvaluationStatement(normalizedName); | ||
elements.push(tree); | ||
@@ -139,0 +139,0 @@ } |
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
1145300
29861