X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=TODO;h=2fe9fb028f4e0c16238bbfeeee7a34183e39a853;hb=6e57504d833b252832d0f5306f0db97784647148;hp=81b803baa5fc1bb2314e635363b9b5e12d985f8f;hpb=5659d76e5bb87873fa7c80efdf1cce8c40d40237;p=gitmo%2FClass-MOP.git diff --git a/TODO b/TODO index 81b803b..2fe9fb0 100644 --- a/TODO +++ b/TODO @@ -2,73 +2,27 @@ TODO --------------------------------------------------------------------- -- have the init_arg be automagically filled in if it is not present +- check out what chromatic said: -(DONE) +I think you can check the class key <_ISA to see if it has expired. -This will simplify some code, and really is not very expensive anyway +- switch to Context::Handle for method modifiers -- clean up bootstrapping to include the accessors, etc for attributes +Should probably write some more tests to verify this works correctly +when we add it in, to make sure we don't break weird stuff. -(DONE) +- add ::Attribute::Collection types -Having all this meta-info is useful actually, so why not add it, and -let the methods get overwritten if they need to be, its a small price -to pay for what we get from it. +mugwump was working on this ... -- clean up all ->initialize($_[0]) handling +- do not bless methods unless asked -(DONE) - -We should always be sure that $_[0] is a package name, and not -a blessed intstance. +We should turn off automagic method blessing for classes which are +not explictly asking for a metaclass. -- make &compute_all_applicable_attributes not return a HASH - -(DONE) - -All the info in the HASH is discoverable through the meta-object. - -- General Purpose &clone_instance method - -(PARTIALLY DONE) - need to implement the deep cloning & tests - -It can be a method of the metaclass, like construct_instance is, -actually it should be called clone_instance, and it should -be thought of as a low-level cloning function, so it should not -do any blessing or anything of the sort. That is left for the -class to implement, as is the construct_instance. - -- General Purpose &new_object and &clone_object method - -(PARTIALLY DONE) - needs more tests - -I seem to be writing a new method each time, but since we dont -have a Object class to always inherit from, this is needed. -However, there is nothing to say that I cannot do something like: - - Foo->meta->new_object(%params) - -and ... - - $foo->meta->clone_object($foo, %params) - -Give it some more thought, but I think it is the best way to -approach this. - -- Role/Trait/Scalar-style mixin mechanism - -This is fairly simple with the MOP, but the trick comes with -any SUPER:: calls. This will be a very tricky problem I think. - -* see Class::Trait::Base, and maybe use anon-classes for this. -* review the Scalar model for mix-ins -* I like the Class does Role, Role isa Class from Perl 6 idea. - -- metaclass.pm - -Should handle metaclass incompatibility issue, and do it through -class mixin composition. +--------------------------------------------------------------------- +EXAMPLES TO WRITE +--------------------------------------------------------------------- - Prototype-style example @@ -85,10 +39,8 @@ I am not sure how we should handle non-method arguments, mostly because those would be static prototype variables, which would translate to class package variables. -- Make a Class::MOP::Package -Class::MOP::Class would be a subclass of this, but I am not sure -this is worth the time. +