PROTOTYPE:

Derek Foster vapor1 at teleport.com
Mon Apr 20 21:37:52 PDT 2009


Hi, Bruce!

I just wanted to offer a huge "THANK YOU!!!" for following up on this and doing actual implementation work. I have had a product release at work, as well as some challenges in my personal life, that have pretty much occupied all of my free time and have made it all but impossible over the last few weeks for me to do any more with Project Coin than to try to read the emails as they come in. Doing compiler implementation work was pretty much out of the question. It has been tremendously helpful that you have been continuing to work on these proposals in my absence. (I am now trying to work through the backlog of Coin-related emails that I wanted to answer but did not have time to, and I will try to update my proposals with the results of various list conversations regarding them ASAP.)

Anyway, in reply to your earlier question about whether or not it was necessary to support underscores at the beginning or end of sequences of digits... I don't have a firm opinion on this. My proposal was written to allow it because I saw no particular reason to disallow it, but I must admit I can't think of any particularly compelling use cases for this behavior. I am considering rewriting my proposal to disallow it and instead go with your suggestion that underscores only be allowed within sequences of digits, instead of around them as well. (However, as I mentioned, I am somewhat short on time, although not as short as I was recently.)

Do others have opinions as to whether this feature (the ability to put underscores at the beginning or end of sequences of digits within a number, such as "0x_5", "0x5_" or "52_") is either desirable or problematic? It seems that Bruce is feeling that it's unnecessary and possibly confusing, and I am now finding myself leaning somewhat towards that opinion myself, although if someone were to present a good example of a case where it might be useful, I might change my mind.

Derek



-----Original Message-----
>From: Bruce Chapman <brucechapman at paradise.net.nz>
>Sent: Apr 20, 2009 6:37 AM
>To: coin-dev at openjdk.java.net
>Cc: Derek Foster <vapor1 at teleport.com>
>Subject: PROTOTYPE:
>
>A prototype compiler for the follow proposals
>
>Underscores in numbers
>Narrow Hexadecimal and Binary Integer Literals
>Byte and Short Integer Literal Suffixes
>
>is now available at
>https://kijaro.dev.java.net/servlets/ProjectDocumentList?folderID=11247&expandFolder=11247&folderID=8804
>
>I have bundled them altogether so that the interaction between 
>underscores and the others can be assessed and so that the two new 
>literal forms can be compared side by side.
>
>There is one fault in the test class, fix that and it should compile and 
>run.
>
>-- Joe, should we update the proposals with this information or is this 
>email sufficient?
>
>
>Bruce




More information about the coin-dev mailing list