Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

Commit

Permalink
doc,deps,test: fixed deps\test after upgrade to 1.2
Browse files Browse the repository at this point in the history
**deps**
chakrashim simulates StackTrace APIs to align with v8.
For `Error.captureStackTrace()` API, it relies on function.name
passed to it to filter out stack frames in callstack. However there
are 2 problems with this.
1. If user passed `o.p` as function name, chakrashim doesn't filter
out as it will try to filter out function name `p` instead (thats what
function.name for `o.p` woudl return). I have opened #75
to track this.
2. Currently depending on function passed as an argument is deferred
parse `function.name` would return a valid name, else it will return
empty. This is bug in chakracore and I am following up with language
team. We seems to rely on this bug while patching Error StackTrace
APIs. However now, `utils.getStackTrace` function is getting
deferred parse and it breaks a unit test. Fixed it by detecting if
it is libraryCodecaller or not. Once we have fix from chakracore,
we can re-evaluate this fix.

**test**
Fixed unit test after upgrade.

** doc**
There was some information in README.md left over from last
merge. Fixed it.

PR-URL: #76
Reviewed-By: Jianchun Xu <Jianchun.Xu@microsoft.com>
  • Loading branch information
kunalspathak committed Jun 14, 2016
1 parent 4dd7c22 commit 8641dc0
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 16 deletions.
14 changes: 1 addition & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,6 @@
Node.js on ChakraCore
===
This project enables Node.js to optionally use the ChakraCore JavaScript engine. This project is still **work in progress** and not an officially supported Node.js branch. Please refer to the original [PR](https://github.com/nodejs/node/pull/4765).
## Resources for Newcomers

* [Website](https://nodejs.org/en/)
* [Contributing to the project](./CONTRIBUTING.md)
* IRC (general questions): [#node.js on chat.freenode.net](https://webchat.freenode.net?channels=node.js&uio=d4)
* IRC (node core development): [#node-dev on chat.reenode.net](https://webchat.freenode.net?channels=node-dev&uio=d4)


### How it works

Expand Down Expand Up @@ -41,14 +34,9 @@ vcbuild chakracore nosign [x86|x64|arm]
```batch
vcbuild chakracore nobuild test [x86|x64|arm]
```
* [bengl](https://github.com/bengl) - **Bryan English** &lt;bryan@bryanenglish.com&gt;
* [bmeck](https://github.com/bmeck) - **Bradley Farias** &lt;bradley.meck@gmail.com&gt;
* [firedfox](https://github.com/firedfox) - **Daniel Wang** &lt;wangyang0123@gmail.com&gt;
* [jhamhader](https://github.com/jhamhader) - **Yuval Brik** &lt;yuval@brik.org.il&gt;
* [othiym23](https://github.com/othiym23) - **Forrest L Norvell** &lt;ogd@aoaioxxysz.net&gt;
* [yorkie](https://github.com/yorkie) - **Yorkie Liu** &lt;yorkiefixer@gmail.com&gt;

To test if Node.js was built correctly with ChakraCore:

```batch
C:\>node -e "console.log('Hello from Node.js ' + process.jsEngine)"
Hello from Node.js chakracore
Expand Down
2 changes: 1 addition & 1 deletion deps/chakrashim/lib/chakra_shim.js
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@
return props;
};
utils.getStackTrace = function() {
return captureStackTrace({}, utils.getStackTrace)();
return captureStackTrace({}, undefined)();
};
utils.isMapIterator = function(value) {
return value[mapIteratorProperty] == true;
Expand Down
2 changes: 1 addition & 1 deletion test/parallel/test-process-versions.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if (common.hasCrypto) {
expected_keys.push('openssl');
}

if (typeof Intl !== 'undefined') {
if (!common.isChakraEngine && typeof Intl !== 'undefined') {
expected_keys.push('icu');
}

Expand Down
2 changes: 1 addition & 1 deletion test/parallel/test-repl-harmony.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ var child = spawn(process.execPath, args);
var input = '(function(){"use strict"; const y=1;y=2})()\n';
var expectedOutput = common.engineSpecificMessage({
v8: /^> TypeError: Assignment to constant variable.\n/,
chakracore: /^> SyntaxError: Assignment to const\n/
chakracore: /^> TypeError: Assignment to const\n/
});

child.stderr.setEncoding('utf8');
Expand Down

0 comments on commit 8641dc0

Please sign in to comment.