in reply to Re^2: (P6) Why the tilde makes sense
in thread (P6) Why the tilde makes sense

The thing about it is that the rest of computerdom interprets 0777 as an octal number. I'm not saying that what's happening here is bad, but I don't understand the drive break convention.

thor

Feel the white light, the light within
Be your own disciple, fan the sparks of will
For all of us waiting, your kingdom will come

Replies are listed 'Best First'.
Re^4: (P6) Why the tilde makes sense
by TimToady (Parson) on Sep 09, 2005 at 20:39 UTC
    There is no drive to break convention. There is only the drive to Do It Right this time, which incidentally breaks convention where convention is suboptimal. But all other things being equal, we'll still pick the conventional solution, or something close to it. Often, however, there are several conflicting conventions to pick from.

    In this case, leading zero meaning octal is originally only a Unix convention, not a computerdom convention, and it's a bad convention because the Real World uses leading zeroes on decimal numbers all the time. Why just this morning my daughter was pissed off at a Web form that required her to specify the month as 09 rather than 9. Stupid, but that's the way the Real World thinks...

Re^4: (P6) Why the tilde makes sense
by chester (Hermit) on Sep 09, 2005 at 19:51 UTC
    But in all of mathdom, 0777 = 777. I can see reasons to break convention. The consistency is nice; everything without a prefix is decimal. Easy to avoid hard-to-spot errors.

    I deal with decimal data on a daily basis that has leading zeroes (input from non-Perl sources). I have more use for fixed-width columns of decimal numbers padded with zeroes so things line up (for example) than for octal numbers.