Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6246713
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T12:44:31+00:00 2026-05-24T12:44:31+00:00

During compilation of a GWT class I got some compiler exception. I filed a

  • 0

During compilation of a GWT class I got some compiler exception. I filed a bug report for that here: http://code.google.com/p/google-web-toolkit/issues/detail?id=6623

Now I found how to make it compile anyway, by using “draftCompile”. However, the generated JavaScript code doesn’t work when executed.

The Java source files are available from the bug tracker, and the compiled project is here: http://clientssh1.rbg.informatik.tu-darmstadt.de:9000/war/Gwittest.html

The error is: (Chrome) “Uncaught TypeError: Cannot read property ‘testpackage_shared_ship_Level_boards’ of null”. In Firefox its another error.

The code works in Dev Mode (from Eclipse).

How do I work around this error? Is it related to the compilation/optimization bug? How do I work around it? If it is a bug in and of itself, I should report this too, no?

Edit: the class in question is here: https://gist.github.com/1139147

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T12:44:32+00:00Added an answer on May 24, 2026 at 12:44 pm

    The error sounds like the compiled javascript contains code like:

    null.testpackage_shared_ship_Level_boards
    

    This would happen if the GWT optimizer believes that your variable of type “Level” which has its field “boards” read, must be null. The optimizer is usually right about that.

    So, an approach is to:
    Compile the code into human readable javascript (-style pretty). Get the javascript error and find the line that caused it. Find the corresponding line your Java source, and trace back where the value of your variable comes from. You will likely find that the variable was not initialized.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am exporting a C++ class to Python and I noticed that during compilation,
I've got as far as telling VC++ to generate ASM files during compilation, which
sometimes i see that certain projects write something to the output during compilation. how
Is there a function which would return (during compilation of metaprogram) in some form
what is wrong about the following code? I get this error during compilation: The
How can I make the following code work? During compilation I get an error
I'm including a rather large JAR file during compilation that I'm generating using Altova
How to make Error List window automatically active during compilation in visual studio instead
Is there an environment variable for GCC/G++ to look for .h files during compilation?
During a typical day programming, I implement functions in a way that I would

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.