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

SyntaxError: Unexpected token (CATCH, 'catch') at 1:9034 between LexToken(PERIOD,'.',1,9033) and LexToken(LPAREN,'(',1,9039) #81

Open
mitar opened this issue Oct 29, 2015 · 4 comments

Comments

@mitar
Copy link

mitar commented Oct 29, 2015

For:

  evalCommandPromise.then(function () {
    callback(null, script.runInThisContext());
  }).catch(callback);
@ztane
Copy link
Contributor

ztane commented Nov 8, 2015

Haha unfortunate ES6 property name. I guess you could rewrite that code as ...)['catch'](callback)

@mitar
Copy link
Author

mitar commented Nov 9, 2015

Yea, sadly I would like to use slimit for automatic parser of the code. So I have first to parse it to be able to automatically convert it. Catch 22. ;-)

@ztane
Copy link
Contributor

ztane commented Nov 9, 2015

Well you could tokenize the source code and replace a . followed by catch keyword by ['catch'] - no parser needed ;)

On a more serious side, I wonder if still @rspivak is interested in developing/maintaining slimit

@metatoaster
Copy link

This is related to #59

metatoaster added a commit to calmjs/calmjs.parse that referenced this issue Jun 8, 2017
- Also note that the following issues were addressed, where applicable
  to the lexer or parser.

  - rspivak/slimit#52
  - rspivak/slimit#54
  - rspivak/slimit#57
  - rspivak/slimit#59
  - rspivak/slimit#62
  - rspivak/slimit#65
  - rspivak/slimit#70
  - rspivak/slimit#73
  - rspivak/slimit#79
  - rspivak/slimit#81
  - rspivak/slimit#82
  - rspivak/slimit#90

- Will get the release out when I get some sleep.
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

No branches or pull requests

3 participants