Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Esprima to the latest 2.7. #171

Merged
merged 1 commit into from Oct 26, 2015
Merged

Update Esprima to the latest 2.7. #171

merged 1 commit into from Oct 26, 2015

Conversation

ariya
Copy link
Contributor

@ariya ariya commented Oct 26, 2015

No description provided.

@brettlangdon
Copy link
Contributor

hey @ariya thank you for the pull request!

However, it looks like Esprima 2.7 is going to effect formatting. Would you be able to run ./node_modules/.bin/grunt fmt locally. I ended up with the following diff

diff --git a/lib/run.js b/lib/run.js
index 99ec6fe..6b6a197 100644
--- a/lib/run.js
+++ b/lib/run.js
@@ -236,7 +236,7 @@ if (paths.length > 0) {
     var chunk = process.stdin.read();
     if (chunk !== null) {
       js += chunk;
-    } else if (chunk === null && js === ''){
+    } else if (chunk === null && js === '') {
       console.log(doc);
       process.exit(-1);
     }
diff --git a/tests/search.js b/tests/search.js
index 92ef0be..011f45d 100644
--- a/tests/search.js
+++ b/tests/search.js
@@ -11,8 +11,14 @@ describe('jsfmt.search', function() {
   it('should test basic searching', function() {
     var results = jsfmt.search('var param1 = 1, done = function(){}; _.each(param1, done);', '_.each(a, b);');
     results[0].node.loc.should.eql({
-      start: {line: 1, column: 37},
-      end: {line: 1, column: 57}
+      start: {
+        line: 1,
+        column: 37
+      },
+      end: {
+        line: 1,
+        column: 57
+      }
     });
     results[0].wildcards.a.name.should.eql('param1');
     results[0].wildcards.b.name.should.eql('done');

Also, if there is a way we can make sure that these changed styles are represented in the examples/styleGuide.js then that would be great.

@brettlangdon
Copy link
Contributor

hmm... nevermind, it looks like these changes exist on master, they weren't caused by your changes. I will open a pull request to update the styles.

brettlangdon added a commit that referenced this pull request Oct 26, 2015
Update Esprima to the latest 2.7.
@brettlangdon brettlangdon merged commit 9fef923 into rdio:master Oct 26, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants