Re: Namespaces (At Long Last)

2006-02-27 Thread Chip Salzenberg
On Mon, Dec 05, 2005 at 04:41:21PM +0100, Leopold Toetsch wrote: > On Dec 5, 2005, at 5:55, Matt Diephouse wrote: > >>- perl5: sometimes (via sigil, but $ref_tosub) > >>- perl6: maybe (sigil is part of the symbol name, but $ref) > > > >Functions, variables, and namespaces _are_ separate here. Don'

Re: Namespaces (At Long Last)

2005-12-05 Thread Leopold Toetsch
On Dec 5, 2005, at 5:55, Matt Diephouse wrote: Leopold Toetsch <[EMAIL PROTECTED]> wrote: Of course, now that I think about it more, it's possible that nothing else will be adding namespaces for Python. Or: only python itself can create Python namespaces. In which case I'd advocate havin

Re: Namespaces (At Long Last)

2005-12-05 Thread Roger Browne
On Sun, 2005-12-04 at 12:25 +0100, Leopold Toetsch wrote: > And it doesn't answer my question at all, sorry. Which HLLs are able to > divide their symbols into above categories? Ah, maybe I see what you're getting at. At compile-time, a HLL knows whether it is compiling a sub or a variable. But

Re: Namespaces (At Long Last)

2005-12-04 Thread Matt Diephouse
Leopold Toetsch <[EMAIL PROTECTED]> wrote: > And it doesn't answer my question at all, sorry. Which HLLs are able to > divide their symbols into above categories? Further: as this proposals > deals with the managment of namespaces, a special typed interface for a > 'namespace' symbol name seems not

Re: Namespaces (At Long Last)

2005-12-04 Thread Bob Rogers
From: Matt Fowles <[EMAIL PROTECTED]> Date: Sun, 4 Dec 2005 12:35:24 -0500 . . . On 12/4/05, Leopold Toetsch <[EMAIL PROTECTED]> wrote: > > . . . Which HLLs are able to > divide their symbols into above categories? . . . > > Remaining for me is the distiction between a

Re: Namespaces (At Long Last)

2005-12-04 Thread Matt Fowles
Leo~ On 12/4/05, Leopold Toetsch <[EMAIL PROTECTED]> wrote: > > On Dec 4, 2005, at 5:57, Matt Diephouse wrote: > > > Roger Browne <[EMAIL PROTECTED]> wrote: > >> Leopold Toetsch wrote: > >> > add_sub($S0, $P0) > >>> > add_namespace($S0, $P0) > >>> > add_var($S0, $P0) > >

Re: Namespaces (At Long Last)

2005-12-04 Thread Leopold Toetsch
On Dec 4, 2005, at 5:57, Matt Diephouse wrote: Roger Browne <[EMAIL PROTECTED]> wrote: Leopold Toetsch wrote: add_sub($S0, $P0) add_namespace($S0, $P0) add_var($S0, $P0) Which HLLs would use these interfaces? Maybe I'm missing the point, but I see these being used in th

Re: Namespaces (At Long Last)

2005-12-03 Thread Matt Diephouse
Roger Browne <[EMAIL PROTECTED]> wrote: > Leopold Toetsch wrote: > > > > add_sub($S0, $P0) > > > > > add_namespace($S0, $P0) > > > > > add_var($S0, $P0) > > > > Which HLLs would use these interfaces? > > Maybe I'm missing the point, but I see these being used in the > implementation of

Re: Namespaces (At Long Last)

2005-12-03 Thread Roger Browne
Leopold Toetsch wrote: > > add_sub($S0, $P0) > > > add_namespace($S0, $P0) > > > add_var($S0, $P0) > > Which HLLs would use these interfaces? Maybe I'm missing the point, but I see these being used in the implementation of "import_into" as a way for the source HLL to tell the targe

Re: Namespaces (At Long Last)

2005-12-03 Thread Leopold Toetsch
On Dec 2, 2005, at 7:31, Matt Diephouse wrote: Typed Interface add_sub($S0, $P0) add_namespace($S0, $P0) add_var($S0, $P0) Which HLLs would use these interfaces? Can you please provide some examples of HLLs with the usage of these interfaces. Thanks, leo

Re: Namespaces (At Long Last)

2005-12-03 Thread Leopold Toetsch
On Dec 2, 2005, at 19:44, Matt Diephouse wrote: Leopold Toetsch <[EMAIL PROTECTED]> wrote: I'm missing the policy in this proposal, e.g. what is allowed to be a top-level global, how are HLL namespaces organized. And of course: where is the Parrot namespace for it's PMCs. I don't think I f

Re: Namespaces (At Long Last)

2005-12-02 Thread Matt Diephouse
Roger Browne <[EMAIL PROTECTED]> wrote: > 1. LANGUAGES AND NAMESPACES > > In my previous messages, I was concerned that languages were being > shoehorned too tightly into their own namespaces. > > But after a careful reading about "import_into", I am happy that each > language has sufficient abilit

Re: Namespaces (At Long Last)

2005-12-02 Thread Roger Browne
1. LANGUAGES AND NAMESPACES In my previous messages, I was concerned that languages were being shoehorned too tightly into their own namespaces. But after a careful reading about "import_into", I am happy that each language has sufficient ability to insert its symbols into the namespace of anothe

Re: Namespaces (At Long Last)

2005-12-02 Thread Matt Diephouse
Leopold Toetsch <[EMAIL PROTECTED]> wrote: > > On Dec 2, 2005, at 7:31, Matt Diephouse wrote: > > [ Just a few notes, more to come. I've to read it some more times. ] > > > Naming Conventions > > > HLL Private Namespaces > > HLLs should use a namespace with an underscore and the > > l

Re: Namespaces (At Long Last)

2005-12-02 Thread Leopold Toetsch
On Dec 2, 2005, at 7:31, Matt Diephouse wrote: [ Just a few notes, more to come. I've to read it some more times. ] Naming Conventions HLL Private Namespaces HLLs should use a namespace with an underscore and the lowercased name of the HLL to store any private items.

Re: Namespaces (At Long Last)

2005-12-02 Thread Nicholas Clark
On Fri, Dec 02, 2005 at 11:50:15AM -0500, Matt Diephouse wrote: > With that in mind, there are two possible ways to name namespaces and > compilers: > > 1. Lowercase or uppercase them all. The Pugs code works with little or > no effort. And always use Unicode Normalised form C? Nicholas Clark

Re: Namespaces (At Long Last)

2005-12-02 Thread Matt Diephouse
jerry gay <[EMAIL PROTECTED]> wrote: > On 12/1/05, Matt Diephouse <[EMAIL PROTECTED]> wrote: > > User Defined Namespaces > > All HLLs should prefix any namespaces with the lowercased name of > > the HLL (so there's no question of what to capitalize). So Perl 5's > > CGI

Re: Namespaces (At Long Last)

2005-12-02 Thread jerry gay
On 12/1/05, Matt Diephouse <[EMAIL PROTECTED]> wrote: > After many months and lots of work, I'm happy to present you with the > latest namespace spec draft. Comments are most welcome: to quote Chip, > "The rest of the discussion would benefit from more eyes." > yay! your hard work shows... this was

Re: Namespaces (At Long Last)

2005-12-02 Thread Michael Lacey
> As I see it, HLLs are just languages, and it's not the _language_ > that "stamps all over" the data. It's really the code-generating > tools that have the potential to mess about with data Quite so, tho I wasn't aware that the tools might not have a one-to-one relationship with languages. I was

Re: Namespaces (At Long Last)

2005-12-02 Thread Roger Browne
Michael Lacey wrote: > I'd want to be able to write/use code from multiple HLLs without any danger > of them stamping all over each other's data. As I see it, HLLs are just languages, and it's not the _language_ that "stamps all over" the data. It's really the code-generating tools that have the p

Re: Namespaces (At Long Last)

2005-12-02 Thread Michael Lacey
Pardon my ignorance here. >From an application programmer's (which is what I used to be) point of view I'd want to be able to write/use code from multiple HLLs without any danger of them stamping all over each other's data. I'd assumed Parrot would be enforcing namespace integrity and not assumin

Re: Namespaces (At Long Last)

2005-12-02 Thread Roger Browne
Thanks Matt and Chip. It's going to take a while to digest all that, but already I have a question: > Synopsis > - Languages should contain their namespaces Suppose my application is multi-HLL. For example, some parts of it are written in Python and some in Ruby. Suppose I take one small part

Namespaces (At Long Last)

2005-12-01 Thread Matt Diephouse
After many months and lots of work, I'm happy to present you with the latest namespace spec draft. Comments are most welcome: to quote Chip, "The rest of the discussion would benefit from more eyes." Thanks, -- matt diephouse http://matt.diephouse.com Synopsis - Languages should contain th