develooper Front page | perl.perl6.language.data | Postings from August 2000

Re: 122 (v1): types and structures

Thread Previous | Thread Next
From:
Nathan Wiger
Date:
August 24, 2000 08:54
Subject:
Re: 122 (v1): types and structures
Message ID:
39A5432E.A4E1354C@wiger.org
How is RFC 122 different from RFC 15? Seems like they accomplish a
similar thing but RFC 15 is a much more Perlish approach. The problem
with RFC 15 is that it's titled "stronger typing though tie", which
implies that tie should be used, but it probably shouldn't be.

As to the struct syntax, I believe the Perl equivalent should look more
like:

        use types;
        $rec = struct {
            int($a, $b, $c);
            float($d, $e, $f);
        };

Since Perl variables aren't barewords and I would assume that int()
would bind as tightly as my(). Also note I threw in a 'use types' pragma
there.

-Nate

> =head1 TITLE
> 
> types and structures
> 
> =head1 VERSION
> 
>   Maintainer: David Nicol <perl6rfc@davidnicol.com>
>   Date: 17 Aug 2000
>   Version: 1
>   Mailing List: perl6-language@perl.org
>   Number: 122
> 
> =head1 ABSTRACT
> 
> We adopt C base types, and C structure syntax.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About