develooper Front page | perl.perl6.language | Postings from June 2005

Re: proposal: binding with a function

Thread Previous | Thread Next
From:
Brent 'Dax' Royal-Gordon
Date:
June 20, 2005 10:43
Subject:
Re: proposal: binding with a function
Message ID:
b8b9a51105062010434310aa19@mail.gmail.com
On 6/20/05, BÁRTHÁZI András <andras@barthazi.hu> wrote:
> - in natural languages, synonims are very often - alias is a synonim

Perl is modeled on natural languages, but that doesn't mean it is one.
 At its core, Perl is a limited, artificial language being explicitly
designed with certain goals.  One of those goals is that it should be
as small as possible given the feature set we want it to support; an
`alias` built-in that essentially duplicates an existing feature goes
against that goal.

> - in Perl 6, currently there's no way to create a reference to a
>    variable, _with the context of the variable_, too (binding just give
>    me possibility to bind a variable into another, but the new variable
>    won't be automatically have the same context, as the binded one)

I'm not sure what you mean by "context" here.  Context has a very
specific meaning in Perl, representing the type a function's caller is
expecting; this doesn't seem to be what you're talking about here.

> alias kilobytes, kilobyte;

This is a couple punctuation symbols short of:
    &kilobytes := &kilobyte;
Or maybe:
    &kilobytes ::= &kilobyte;
I'm not really sure what behavior you have in mind for alias.

(By the way, a simple name like "alias" is ambiguous about argument
order, where an operator isn't.)

-- 
Brent 'Dax' Royal-Gordon <brent@brentdax.com>
Perl and Parrot hacker

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