RE: [Java Spec Report] Constants (fields declared final) versus "inlined constants"

"Roly Perera" <[email protected]> Sat, 21 Aug 2004 13:12:42 +0100
Newsgroups gmane.comp.java.spec-report
Message-ID <[email protected]>
Given the forthcoming 3rd Edition of the JLS I've decided to take the
Java Spec Report offline, as it will no longer be up to date enough to
be relevant.

This Yahoo group will continue to exist as it occasionally proves a
useful discussion forum for language spec issues.  However I personally
no longer plan to maintain any public errata lists.

cheers,
Roly

Roly Perera
[email protected]

+-----------------------------------------------------------------------
+
| Ergnosis Ltd                  www.ergnosis.com
|
| Third Floor                   the art of the science of software
|
| 14 King Square
|
| Bristol BS2 8JJ, U.K.         See us in  Vancouver at OOPSLA 2004:
|
| +44 117 924 8915 (telephone)  www.oopsla.org/2004/ShowEvent.do?id=651
|
| +44 870 421 1389 (fax)        www.oopsla.org/2004/ShowEvent.do?id=595
|
+-----------------------------------------------------------------------
+


> -----Original Message-----
> From: dunn [mailto:[email protected]] 
> Sent: 20 August 2004 20:37
> To: [email protected]
> Subject: [Java Spec Report] Constants (fields declared final) 
> versus "inlined constants"
> 
> 
> 
> 
> Eric Blake made me aware of the posting at 
> http://ergnosis.com/java-spec-report/java-language/jls-9.3.htm
> l ("9.3 Field
> (Constant) Declarations
> Interface fields are not constants"). I respectfully 
> disagree, and think you should remove this page and replace 
> it with one that argues for a formal definition of "inlined 
> constants" in the JLS. I can't help but to think that if the 
> Java Spec Report formally objected to "constant variable" as 
> proposed in 
> http://java.sun.com/docs/books/jls/clarifications-2-2nd-ed.htm
> l that there may yet be time to "call a thing what it is."
> 
> The argument in 9.3 is predicated on the basis that inlining 
> defines what is a constant. That is not true. The final 
> keyword defines what is a constant. Furthermore, the 
> distinction between an "interface field" and an (inlined) 
> constant would be lost on the rank and file given the 
> overwhelming weight of tutorials and other works that define 
> "constants" as fields declared final. In my view, the 
> existence of "9.3 Field (Constant) Declarations Interface 
> fields are not constants" is yet another example of why the 
> JLS should "call a thing what it is" and formally define 
> "inlined constant" instead of "primitive constant," 
> "compile-time primitive constant," "compile-time constant," 
> "compile-time constant field," or the latest "constant 
> variable," all of which are more or less meaningless to 
> anyone who is not staring at the definition. 
> 
> Please reconsider your position on this before the Third 
> Edition is published. It is the source of a great deal of confusion.
> 
> Regards,
> Doug Dunn
> Mastering the Fundamentals of the Java Programming Language 
www.javarules.com 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.721 / Virus Database: 477 - Release Date: 16/07/2004
 



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/5cFolB/TM
--------------------------------------------------------------------~-> 

To unsubscribe from this mailing list, send an email to:
[email protected]
 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/java-spec-report/

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/