On 12/03/2002 2:27 PM, Michael Lazzaro wrote:
I think we've been gravitating to a "language reference", geared primarily towards intermediate/advanced users. Something much more rigorous than beginners would be comfortable with (since it defines things in much greater detail than beginners would need) and written to assume *no* prior knowledge of Perl5. It will be useful to the developers -- in that it will describe required P6 behaviors in much greater detail than the Apocalypses and Exegesis -- but it will be written for users.
I quite agree... which still means we need more rigor then this document
has.  The defintion of a pair and the semantics of \c[ and friends is
important so that users know exactly what "\c~" means ('>',
C<<chr(ord('['-64))>> ), and if C<<qq◄some words here►>> will work (no,
those aren't a matched Pi/Pf or Pb/Pe pair, they're just Misc. Shapes
that have no direction information, and we can't do them reasonably
without looking at every character in Unicode visualy -- if somebody
wants to, be my guest!).

Do we want to change shorthand octal literal numbers to 0o123 (I don't like this, it's hard to read), change octal chars to \c123 (can't do this without getting rid of, or changing, \c for control-character), get rid of octal chars entirely, or somthing else? (Baring a good "somthing else", I vote for killing octal chars.)
As of Larry's last writings, there will definitely be an octal (it still has good uses), and it's syntax will definitely be 0o777 -- with an 'o', not a 'c'. The 'o' is a little hard to read, but the best anyone can come up with. It has to be lowercase 'o', not uppercase 'O', which helps *enormously*. :-)
Huh?  In that case, somebody should tell Angel Faus; "Numeric literals,
take 3" says 0c777, and nobody disented.  IIRC, in fact, nobody's
descented to 0c777 since it was first suggested.

(But since I assume you can use \d, \b, \h anywhere you use \o, you won't have to use octal at all if you don't want to.)
\d is pure speculation on my part.  (As is \0 == chr(0).)

In fact, for this, and \o777 vs. whatever, I'm cc-ing perl6-language on
this.


p6l guys and the Design Team, if you havn't been following the
conversation, here's how it goes:
In perl5, octal numbers are specified as 0101 -- with a leading zero,
and octal characters in strings are specified as "\0101".  In perl6, our
current documentation lists 0c101 as being the new way to write octal
numbers, because it lets people use leading zeros in numbers in an
intuitive way, and 0o101 was decided to be too difficult to read.  The
last writing of Larry to address this, as far as I (or anybody else who
I've noticed) knows, says 0o101.

It's generaly been agreed on, I think, that 0c101 is the way to go.

Now, we're working on string literals, and the question is how we write
octal character literals.  The current writer of the string literal spec
wants "\o101" to be the new way to write what is "\101" in perl5 (and
C).  I'd prefer this to be "\c101", to match up with how the current doc
says octal numerics are written.  Unfornatly, \c is taken for
control-characters (ie "\c[" eq chr(ord '[' - 64) eq ESC), which is a
more important use of \c.

What do we do, oh great and wonderful design team?

Numeric       String        Upside                    Downside
-------       ------        ------                    --------
0101          \101          p5/C compatable           Unintutive
0o101         \o101         Consistent                Hard to read
0c101         \o101         keeps \c for              Inconsistent
                            control-char
0c101         unsupported   Consistent                octal string chars
                                                      unsupported
0t101         \t101         Consistent                what's tab?

Or somthing else?
All choices are bad, which one is best?

	-=- James Mastros


Reply via email to