Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [vjet-dev] [wtp-dev] How do we get JSDT issues that have patches actually fixed ?

Hi Denis,

Thanks for your feedback.

VJET has a special js comment parser which inspects for type hints. These hints we call vjetdoc. 

The comment you have

  // > // Tag description.
  // > method(window).hashchange( function(e) {
  // >   var hash = location.hash;
  // >   ...
  // > });

 collides with vjet doc comments... just change //> to // ! > or remove the greater than sign.

Such as:

  //  // Tag description.
  //  method(window).hashchange( function(e) {
  //    var hash = location.hash;
  //    ...
  //  });



Thanks,

Justin

On Jan 29, 2013, at 6:35 PM, Denis Golovin <dgolovin@xxxxxxxxxx> wrote:

Justin,

I created VJetProject, added test.js file that contains snipped below and got 5 errors for this snippet. Meantime I can run it without any problems as Vjet Web project on FireFox and it works as expected without any errors, JSDT works correct in this case.

test.js content

  // > // Tag description.
  // > method(window).hashchange( function(e) {
  // >   var hash = location.hash;
  // >   ...
  // > });
  window.alert("test");

Description    Resource    Path    Location    Type
VJET comment error: Lexical error at line 1, column 3.  Encountered: "/" (47), after : "" For comment :// > // Tag description.    test.js    /js-vjet/src    line 3    VJET Problem
VJET comment error: Lexical error at line 1, column 18.  Encountered: "h" (104), after : "." For comment :// > method(window).hashchange( function(e) {    test.js    /js-vjet/src    line 4    VJET Problem
VJET comment error: Lexical error at line 1, column 14.  Encountered: "=" (61), after : "" For comment :// >   var hash = location.hash;    test.js    /js-vjet/src    line 5    VJET Problem
VJET comment error: Syntax error at ... delete this token For comment :// >   ...    test.js    /js-vjet/src    line 6    VJET Problem
VJET comment error: Syntax error at } delete this token For comment :// > });    test.js    /js-vjet/src    line 7    VJET Problem


Denis


On 01/29/2013 10:29 AM, Justin Early wrote:
Hi John,

Thanks for the feedback.

someVar = 1 + 2
++someVar

Yes I see the syntax error in VJET too... created bug for this.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=399417

Thanks for the info didn't see this case in our test suite.

For this

For our variant of JSDT [1] we disabled JSDT's problem checking and
instead plan to use an optimized version of JSHint-eclipse [2].

Do you see any issues with performance? JSDT has to parse the js file for search and code assist, then jshint has to parse and report issues.

Justin


On Jan 29, 2013, at 10:16 AM, John Peberdy <john@xxxxxxxxxx> wrote:

On Tue, Jan 29, 2013 at 11:15 AM, Justin Early <earlyster@xxxxxxxxx> wrote:
Can you be more specific on this issue?

the lack of handling semi-colons properly

Both JSDT and VJET report spurious errors for this code

someVar = 1 + 2
++someVar

For our variant of JSDT [1] we disabled JSDT's problem checking and
instead plan to use an optimized version of JSHint-eclipse [2].


[1] https://bitbucket.org/nexj/webtools.jsdt.core/
[2] http://github.eclipsesource.com/jshint-eclipse/





Thanks,

Justin

Sent from my iPad

On Jan 29, 2013, at 1:58 AM, Max Rydahl Andersen <max.andersen@xxxxxxxxxx> wrote:

Hi guys,

We got a bunch of fixes/patches submitted in bugzilla trying to get JSDT not fail on common available _javascript_ libraries;
especially in context of libraries popular in mobile tools.

Similar errors still exist in VJET which has its own fork of JDST so i'm cc'ing vjet-dev on this topic too.

Some of these issues and their patches are close to a year old...time to get these pushed in IMO.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=366247 - NPE in CompilationUnitBinding#sourceMethod() (triggered by birt and other js libraries)
https://bugs.eclipse.org/bugs/show_bug.cgi?id=356446 - [exceptions] Errors running builder '_javascript_ Validator' on project with ArrayIndexOutOfBoundsException (Also fixes #344745)
https://bugs.eclipse.org/bugs/show_bug.cgi?id=344745 - [search] ArrayIndexOutOfBoundsException in DiskIndex during problem detection
https://bugs.eclipse.org/bugs/show_bug.cgi?id=350693 - [exceptions][parser] ArrayIndexOutOfBoundsException in Parser#consumeEmptyStatement on a _javascript_ file when building project
https://bugs.eclipse.org/bugs/show_bug.cgi?id=357353 - ArrayIndexOutOfBoundsException in UnconditionalFlowInfo#markAsDefinitelyNonNull() with FieldReference
https://bugs.eclipse.org/bugs/show_bug.cgi?id=349020 - [validation] Eclipse complains about jquery minified JS files

These makes it much more tolerable to use JSDT with _javascript_ libraries.

One issue we haven't found a way to solve yet is the lack of handling semi-colons properly - but would love to see it fixed but lack the info on how to update/modify the parser.

But lets start with what we already got patches for - how do we get these issues with already existing patches fixed for Kepler ?

/max
_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev
_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev

--
John Peberdy
_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev



_______________________________________________
wtp-dev mailing list
wtp-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/wtp-dev



Back to the top