Is the world coming to an end?
Daniel Gibson
metalcaedes at gmail.com
Sun Apr 3 14:05:35 PDT 2011
Am 03.04.2011 22:47, schrieb Walter Bright:
> On 4/3/2011 1:42 PM, Daniel Gibson wrote:
>> Am 03.04.2011 22:38, schrieb Walter Bright:
>>> On 4/3/2011 1:23 PM, Dan Olson wrote:
>>>> Thought I'd test drive octal!. I'm still on v2.051 though.
>>>>
>>>> writefln("%o", octal!777); -> 777
>>>> writefln("%o", octal!0777); -> 511 (0ops)
>>>>
>>>> Maybe in a new version the second line will generate a error for the
>>>> leading zero on the second line?
>>>>
>>>
>>> Yes, it will.
>>
>> What about octal!"0777"?
>
> No.
>
>> I'm not even sure what it should do (ignore 0?
>> complain? behave like the old 0777?)
>
> It's seems clear to me. octal!"0777" should generate 777 octal.
>
Hm yes, you're right. I think I was having a knot in my brain from octal!0777 ;)
More information about the Digitalmars-d
mailing list