Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
NoSuchFieldError after code changes
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  7 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
sschaef  
View profile   Translate to Translated (View Original)
 More options Aug 16 2012, 7:09 am
From: sschaef <m...@antoras.de>
Date: Thu, 16 Aug 2012 13:09:59 +0200
Local: Thurs, Aug 16 2012 7:09 am
Subject: NoSuchFieldError after code changes
After some edits to code completion I got the following exception after
running core inside of eclipse to test the changes:

2012-08-16 12:49:27,791 DEBUG [main] - System.out -
java.lang.NoSuchFieldError: block$3
        at
scala.tools.eclipse.ui.ScalaCompletionProposal.apply(ScalaCompletionProposa l.scala:107)
        at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.insertProposal (CompletionProposalPopup.java:933)
        at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.insertSelected ProposalWithMask(CompletionProposalPopup.java:881)
        at
org.eclipse.jface.text.contentassist.CompletionProposalPopup.verifyKey(Comp letionProposalPopup.java:1307)
        at
org.eclipse.jface.text.contentassist.ContentAssistant$InternalListener.veri fyKey(ContentAssistant.java:807)
...

It looks like binary incompatibility. Interestingly all works fine after
a clean and rebuild of the project, but with each new change it is
broken again. How can that be?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mirco Dotta  
View profile  
 More options Aug 18 2012, 1:33 pm
From: Mirco Dotta <mirco.do...@typesafe.com>
Date: Sat, 18 Aug 2012 19:33:07 +0200
Local: Sat, Aug 18 2012 1:33 pm
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes
Hey Simon,

That is weird, can you tell us how to reproduce it?

-- Mirco

On Aug 16, 2012, at 1:09 PM, sschaef wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
sschaef  
View profile   Translate to Translated (View Original)
 More options Aug 18 2012, 3:42 pm
From: sschaef <m...@antoras.de>
Date: Sat, 18 Aug 2012 21:42:12 +0200
Local: Sat, Aug 18 2012 3:42 pm
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes
I did a change in the body of foreach
https://github.com/scala-ide/scala-ide/blob/master/org.scala-ide.sdt....

After compiling I started core (in Run or Debug mode; it doesn't
matter) and tried to do some code completion. After choosing one of the
methods, suggested by the completion pop-up, the exception occurs when
control flow arrives at the changed foreach block.

On Sa 18 Aug 2012 19:33:07 CEST, Mirco Dotta wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mirco Dotta  
View profile  
 More options Aug 18 2012, 4:28 pm
From: Mirco Dotta <mirco.do...@typesafe.com>
Date: Sat, 18 Aug 2012 22:28:00 +0200
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes

And what did you change (or is it irrelevant?)

> After compiling I started core (in Run or Debug mode; it doesn't matter) and tried to do some code completion. After choosing one of the methods, suggested by the completion pop-up, the exception occurs when control flow arrives at the changed foreach block.

The linked EditorHelpers is used only by refactoring, and it shouldn't be triggered during code completion, so how is the change in EditorHelpers relevant?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Simon Schäfer  
View profile  
 More options Aug 18 2012, 5:01 pm
From: Simon Schäfer <m...@antoras.de>
Date: Sat, 18 Aug 2012 23:01:34 +0200
Local: Sat, Aug 18 2012 5:01 pm
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes

On Sa 18 Aug 2012 22:28:00 CEST, Mirco Dotta wrote:

>> I did a change in the body of foreach https://github.com/scala-ide/scala-ide/blob/master/org.scala-ide.sdt....

> And what did you change (or is it irrelevant?)

It is irrelevant. The only thing which should be achieved is a
recompile.

>> After compiling I started core (in Run or Debug mode; it doesn't matter) and tried to do some code completion. After choosing one of the methods, suggested by the completion pop-up, the exception occurs when control flow arrives at the changed foreach block.

> The linked EditorHelpers is used only by refactoring, and it shouldn't be triggered during code completion, so how is the change in EditorHelpers relevant?

The error occurs after code completion (I think). Debugger said me that
code completion is used to construct the items which can be completed
and refactoring to insert this items into the sources (the error occurs
not while constructing the list of items to complete, but while trying
to execute one specific completion).


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
iulian dragos  
View profile  
 More options Aug 21 2012, 8:23 am
From: iulian dragos <jagua...@gmail.com>
Date: Tue, 21 Aug 2012 14:23:03 +0200
Local: Tues, Aug 21 2012 8:23 am
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes

On Sat, Aug 18, 2012 at 9:42 PM, sschaef <m...@antoras.de> wrote:
> I did a change in the body of foreach https://github.com/scala-ide/**
> scala-ide/blob/master/org.**scala-ide.sdt.core/src/scala/**
> tools/eclipse/refactoring/**EditorHelpers.scala#L127<https://github.com/scala-ide/scala-ide/blob/master/org.scala-ide.sdt....>

> After compiling I started core (in Run or Debug mode; it doesn't matter)
> and tried to do some code completion. After choosing one of the methods,
> suggested by the completion pop-up, the exception occurs when control flow
> arrives at the changed foreach block.

Are you using -optimize? Are you using Scala 2.9 or 2.10? If you're using
the optimizer, it might be that some method in EditorHelpers is inlined at
the call site, including the access to that field. After recompiling
EditorHelpers, that field may have been renamed (looks synthetic anyway),
but de call-site is not recompiled (since the incremental compiler only
recompiles calling code if *signatures* change -- meaning it's not
-optimize proof).

iulian

--
« Je déteste la montagne, ça cache le paysage »
Alphonse Allais

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Simon Schäfer  
View profile   Translate to Translated (View Original)
 More options Aug 25 2012, 4:49 pm
From: Simon Schäfer <m...@antoras.de>
Date: Sat, 25 Aug 2012 22:49:56 +0200
Local: Sat, Aug 25 2012 4:49 pm
Subject: Re: [scala-ide-dev] NoSuchFieldError after code changes
Thanks for the help, Iulian. After deactivating -optimise the exception
is gone and the code change can be succesfuly used.
I think this issue should be go into the FAQ or at least somewhere else
in the documentation, shouldn't it?

On Di 21 Aug 2012 14:23:03 CEST, iulian dragos wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »