Skip to content

Infinite loop when transpiling to Java html5.js from Closure Compiler contribs. #42

@didier-durand

Description

@didier-durand

Hello,

We are working on providing to the GWT community Java bindings (Java source code) to many standard Javascript libraries: see https://github.com/didier-durand/JSClosure2Interop
This work is based on this JSInterop Generator and Javscript contribs to the Closure Compiler project (replicated wih identical structure in js directory)

So, in the gen directory, you will see that successful transpiling back to Java for various small Javascript is achieved : GeoJson, Async-2.0, es3, etc.

But, our final targets is bigger libraries like Google Maps (prio 1), jQuery, Ace, Angular, etc. For those, the list of dependency is bigger.
For example, you will see that Google Maps requires 27 dependencies (see src/test/java/oss/jsinterop/cl2jsi/test/TestConverterGmaps.java)

As they use many browser features, those large libraries end up (see src/test/java/oss/jsinterop/cl2jsi/test/TestConverterFailure.java) all involving html5.js to solve their dependencies.

html5.js (see /js/google-closure-compiler/externs/browser/html5.js) comes from Google Closure Compiler contribs.

At this point in time, when its isolated transpiling is tried, JSInterop Genarator seems to go into an infinite loop (please, run src/test/java/oss/jsinterop/cl2jsi/test/TestConverterHtml5.java - The jar of Generator is embarked, so it should run).

Same thing with the transpiling of all large libraries requiring it: when we introduce html5.js to complete the needs, the transpiler loops forever. Its Jar was created from master of March, 21st (commit: e68a27e)

The debug mode of the Generator doesn't say anything user about this loop.

Is the error on our side?

Thanks!

Didier

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions