All,
I believe that there is some room for adding several new convenience
operators or functions to Perl 6 that are used with Mapping and Hash
values.
Or getting more to the point, I believe that the need for the
relational data model concept of a tuple (a "tuple" where elements
are address
On 2/24/07, Jonathan Lang wrote:
In effect, using * as an array of indices gives us the ordinals
notation that has been requested on occasion: '*[0]' means 'first
element', '*[1]' means 'second element', '*[-1]' means 'last
element',
'*[0..2]' means 'first three elements', and so on - and this
Darren Duncan writes:
> I believe that there is some room for adding several new convenience
> operators or functions to Perl 6 that are used with Mapping and Hash
> values.
> I also want to emphasize that I see this functionality being generally
> useful, and that it shouldn't just be shunted off
I'd like to request that num16 and therefore complex16 be added to S09,
and made optional just as num128 and complex128 are. The half-sized
floating point type is commonly used in computer graphics and widely
supported by GPUs and High Dynamic Range image formats such as OpenEXR.
-'f
How are the bitwise shifts defined on low level types? In particular,
for right shift, does high bit extension or zero fill occur? Does the
answer depend on whether the low level type is signed or not?
On the flip side, it seems more useful if we have both operators
available for either signed o
Does Perl 6 have (bit/string) rotation ops? Especially bit rotation on
low-level integer types would be Nifty for making some numeric
algorithms cleaner, more self documenting, and potentially faster than
forcing the use of a combination of other bitwise ops to do the same
thing.
-'f
What happens when a low-level type overflows or underflows? For
example, if you decrement an int1 twice, what happens?
If you increment a uint8 past 255, do you get:
1. A uint8 with value 0?
2. A uint16 with value 256?
3. A failure?
What about incrementing an int8 past 127? Do you get:
1. An
What happens when you cast between low-level types? If the source value
is out of range of the destination type, do you get:
1. An exception?
2. Clip to finite range always?
3. Clip to finite range for ints, clip to infinities for nums?
4. Exception when dest is int, clip to infinities when dest
How do you specify that you want to byte-stringify a compact struct,
rather than "normal" stringify it?
Does the byte-stringified version include internal and/or trailing
alignment padding? How do you specify the other choices?
Whether or not trailing padding is included when byte-stringifying a
On Tue, Feb 27, 2007 at 12:18:20AM -0800, Darren Duncan wrote:
> 4. rename():
>
> function rename of Mapping (Mapping $m, Str $old_k, Str $new_k) {
> ... }
>
> This operator takes one Mapping argument and derives another
rename is a Perl 5 builtin. I didn't think that it ha
How is casting and coersion handled with expressions involving mixed low
and high level types?
For example, what is the output of this?
my Int $ten = 10;
my int4 $a = 0;
my int4 $b;
$b = ($a + 2.4 * $ten) / 4;
say $b;
The answers to the above questions may alter my view o
On Tue, 2007-02-27 at 09:20 -0800, Geoffrey Broadwell wrote:
> How is casting and coersion handled with expressions involving mixed low
> and high level types?
>
> For example, what is the output of this?
>
> my Int $ten = 10;
> my int4 $a = 0;
> my int4 $b;
>
> $b = ($a + 2.4
Darren Duncan writes:
> I believe that ... some common relational operations would be a lot
> easier to express if Perl 6 had a few more operators that make them
> concise.
I am prepared to believe that. But what I'm unclear on is when I'd want
to perform a common relational operation.
Please c
Geoffrey Broadwell writes:
> How are the bitwise shifts defined on low level types? In particular,
> for right shift, does high bit extension or zero fill occur? Does the
> answer depend on whether the low level type is signed or not?
>
> On the flip side, it seems more useful if we have both o
On Tue, Feb 27, 2007 at 06:31:31PM +, Smylers wrote:
> Geoffrey Broadwell writes:
>
> > How are the bitwise shifts defined on low level types? In particular,
> > for right shift, does high bit extension or zero fill occur? Does the
> > answer depend on whether the low level type is signed or
On Tue, Feb 27, 2007 at 06:31:31PM +, Smylers wrote:
> Geoffrey Broadwell writes:
>
> > Perhaps having both +> and ?> operators? Since "coerce to boolean and
> > then right shift" is meaningless, ...
>
> It's useless, rather than meaningless; you've neatly defined what the
> meaning of that
David Green wrote:
On 2/24/07, Jonathan Lang wrote:
>In effect, using * as an array of indices gives us the ordinals
>notation that has been requested on occasion: '*[0]' means 'first
>element', '*[1]' means 'second element', '*[-1]' means 'last
>element',
>'*[0..2]' means 'first three elements',
Author: larry
Date: Tue Feb 27 15:41:10 2007
New Revision: 13706
Modified:
doc/trunk/design/syn/S09.pod
Log:
Some clarifications requested by Geoffrey Broadwell++.
Modified: doc/trunk/design/syn/S09.pod
==
--- doc/tr
At 4:45 PM + 2/27/07, Nicholas Clark wrote:
> 4. rename():
rename is a Perl 5 builtin. I didn't think that it had been dropped for
Perl 6.
At 6:22 PM + 2/27/07, Smylers wrote:
> 1. join() aka natural_join():
Remember that Perl already has a C function, for joining strings.
To b
At 6:15 AM -0800 2/27/07, Geoffrey Broadwell wrote:
What happens when a low-level type overflows or underflows? For
example, if you decrement an int1 twice, what happens?
If you increment a uint8 past 255, do you get:
1. A uint8 with value 0?
2. A uint16 with value 256?
3. A failure?
What ab
Author: larry
Date: Tue Feb 27 15:56:44 2007
New Revision: 13707
Modified:
doc/trunk/design/syn/S03.pod
Log:
Modifiers on bit shifts.
Modified: doc/trunk/design/syn/S03.pod
==
--- doc/trunk/design/syn/S03.pod
On Tue, Feb 27, 2007 at 09:35:49AM -0800, Geoffrey Broadwell wrote:
: On Tue, 2007-02-27 at 09:20 -0800, Geoffrey Broadwell wrote:
: > How is casting and coersion handled with expressions involving mixed low
: > and high level types?
: >
: > For example, what is the output of this?
: >
: > my
On Tue, Feb 27, 2007 at 06:54:50AM -0800, Geoffrey Broadwell wrote:
: How do you specify that you want to byte-stringify a compact struct,
: rather than "normal" stringify it?
Coerce to a buffer type rather than using ~.
: Does the byte-stringified version include internal and/or trailing
: align
On Tue, Feb 27, 2007 at 06:26:18AM -0800, Geoffrey Broadwell wrote:
: What happens when you cast between low-level types? If the source value
: is out of range of the destination type, do you get:
:
: 1. An exception?
: 2. Clip to finite range always?
: 3. Clip to finite range for ints, clip to i
Author: larry
Date: Tue Feb 27 17:00:09 2007
New Revision: 13708
Modified:
doc/trunk/design/syn/S03.pod
Log:
Better writing requested by John Macdonald++
Modified: doc/trunk/design/syn/S03.pod
==
--- doc/trunk/design
Author: larry
Date: Tue Feb 27 17:01:23 2007
New Revision: 13709
Modified:
doc/trunk/design/syn/S03.pod
Log:
gah
Modified: doc/trunk/design/syn/S03.pod
==
--- doc/trunk/design/syn/S03.pod(original)
+++ doc/tr
On 2/26/07, Geoffrey Broadwell <[EMAIL PROTECTED]> wrote:
Hmmm. Let's see if there is a way I can help to get what I want
Assuming that the answer to my question in the other thread is "packed
arrays aren't implemented anywhere yet", are any implementations close
enough that I can trade te
27 matches
Mail list logo