mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-05-03 03:00:14 -04:00
light refactors + tweaks
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
if (options.fileName) {
|
||||
err.message = "In " + options.fileName + ", " + err.message;
|
||||
}
|
||||
console.error(err.toString());
|
||||
throw err;
|
||||
}
|
||||
};
|
||||
@@ -44,13 +45,13 @@
|
||||
if (root.moduleCache) {
|
||||
root.moduleCache = {};
|
||||
}
|
||||
return path.extname(root.filename) !== '.coffee' || require.extensions ? root._compile(exports.compile(code, options), root.filename) : root._compile(code, root.filename);
|
||||
return path.extname(root.filename) !== '.coffee' || require.extensions ? root._compile(compile(code, options), root.filename) : root._compile(code, root.filename);
|
||||
};
|
||||
exports.eval = function(code, options) {
|
||||
var __dirname, __filename;
|
||||
__filename = options.fileName;
|
||||
__dirname = path.dirname(__filename);
|
||||
return eval(exports.compile(code, options));
|
||||
return eval(compile(code, options));
|
||||
};
|
||||
lexer = new Lexer;
|
||||
parser.lexer = {
|
||||
|
||||
Reference in New Issue
Block a user