Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!feeder2.ecngs.de!ecngs!feeder.ecngs.de!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.bt.com!news.bt.com.POSTED!not-for-mail NNTP-Posting-Date: Sun, 28 Apr 2013 08:54:46 -0500 Date: Sun, 28 Apr 2013 14:54:42 +0100 From: lipska the kat <"nospam at neversurrender dot co dot uk"> Organization: Trollbusters 3 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130308 Thunderbird/17.0.4 MIME-Version: 1.0 Newsgroups: comp.lang.java.programmer Subject: Re: A small exercise References: <5172e967$0$32109$14726298@news.sunsite.dk> <517b3461$0$32112$14726298@news.sunsite.dk> <2rWdnWTV7bz8FubMnZ2dnUVZ7qGdnZ2d@bt.com> <517c8241$0$32104$14726298@news.sunsite.dk> <2fednevwr_TPZuHMnZ2dnUVZ8uCdnZ2d@bt.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Message-ID: Lines: 47 X-Usenet-Provider: http://www.giganews.com X-AuthenticatedUsername: NoAuthUser X-Trace: sv3-EtNvCHMdohNyTR2UEs6KMXBO6m6bp2Rmfti0cyRR+iXJYzElBqNSKo23kM5p8k6poqiCWu3axP2Z5bu!Tv6k+Qq51uAqe+NPaGHWWmHK0PmyHJ26316qYmzsa/oRpKt4s4wKu9Mkxo2bjJ3NsPybOjc81Ms= X-Complaints-To: abuse@btinternet.com X-DMCA-Complaints-To: abuse@btinternet.com X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 3078 Xref: csiph.com comp.lang.java.programmer:23699 On 28/04/13 14:14, Sven Köhler wrote: > On 04/28/2013 04:05 PM, lipska the kat wrote: >> Not sure what you mean here as Eclipse can be configured to use >> different compilers > > Eclipse only has one compiler. It's specially written by IBM for > Eclipse, and it's not based on javac as far as I know. > >> independently of the version of Java used to run the >> application (Eclipse) >> >> I configured Eclipse to compile against >> >> java-7-openjdk >> and, separately >> java version 1.6.0_35 > > But each time, you're using Eclipse's compiler, and not the javac of the > JDK. OK, well, I'm no Eclipse expert so I'll have to look into that, in the meantime apologies to Chris Uppal, it appears he was correct and I was wrong. For the time being let's call it the Eclipse compiler compliance level then, with compliance set to 1.6 or 1.7 the same error occurs also, and independently of Eclipse /usr/lib/jvm/java-7-openjdk-amd64/bin/javac Main.java Main.java:10: error: cannot assign a value to final variable b Main.this.b = 0; /opt/java/jdk1.6.0_35/bin/javac Main.java Main.java:10: cannot assign a value to final variable b Main.this.b = 0; ^ None of which changes my thought that "it's not a *bug* but a poorly understood (by me) application of the rules of the language by the compiler" lipska -- Lipska the Kat©: Troll hunter, sandbox destroyer and farscape dreamer of Aeryn Sun