Phoenix.pm: typesafety

Scott Walters scott at illogics.org
Fri Dec 5 13:26:05 CST 2003


Hi,

When I presented this (and did a horrible job presenting - the quickie
pre-presentation after Doug's was much better) I think it was on version 0.02.
It is 0.004 now - a lot has changed. It understands a lot more code constructs,
both specific code constructs and general things. Previous versions didn't
consider context, but context bits in ops make it clear whether an op
is leaving something on the stack and thus generating a value. This version
is almost threatening to be useful. 

The main thing that I consider to be missing is typing of hash keys
individually, which is needed to create objects without using Object::Lexical
(though I don't know why anyone would ever want to do that). O::L makes
instance data merely lexical data so reference to other objects and such
typed data is kept in scalars. The common way to write objects is to 
subscript $_[0] as a hash using fixed keys, where $self = shift; 
$self->{foo} is one field, $self->{bar} is another, and so on. Well,
typesafety doesn't understand that these are seperate from each other
and type them seperately right now. But it should. 

So, I'm mailing the list looking for feedback - what else do I need to do
to make this really usable? 

>From working on it for too long, I've developed developer myopia, where I'm
psychologically unable to see shortcomings of my own work because each time
I have in the past I've been punished by having to do work. You could say
that developers like myself become conditioned against seeing flaws in our
own work. 

If anyone on this list knows Perl 5's VM well, I wouldn't mind a code
review either =)

http://search.cpan.org/~swalters/typesafety-0.04/typesafety.pm

Thanks,
-scott





More information about the Phoenix-pm mailing list