be6bf34bf63ecf66d582548cb3813f610b7ff4bf
[gitmo/Moose.git] / Changes
1 Revision history for Perl extension Moose
2
3 0.23 Mon. June 18, 2007
4     * Moose::Meta::Method::Constructor
5       - fix inlined constructor for hierarchy with multiple BUILD methods (mst)
6     * Moose::Meta::Class
7       - Modify make_immutable to work with the new Class::MOP immutable
8         mechanism + POD + very basic test (groditi)
9     * Moose::Meta::Attribute
10       - Fix handles to use goto() so that caller() comes out properly on 
11         the other side (perigrin)
12
13 0.22 Thurs. May 31, 2007
14     * Moose::Util::TypeConstraints
15       - fix for prototype undeclared issue when Moose::Util::TypeConstraints 
16         loaded before consumers (e.g. Moose::Meta::Attribute) by predeclaring
17         prototypes for functions
18       - added the ClassName type constraint, this checks for strings 
19         which will respond true to ->isa(UNIVERSAL). 
20         - added tests and docs for this
21       - subtyping just in name now works correctly by making the 
22         default for where be { 1 }
23         - added test for this 
24
25     * Moose::Meta::Method::Accessor
26       - coerce and lazy now work together correctly, thanks to 
27         merlyn for finding this bug
28         - tests added for this
29       - fix reader presedence bug in Moose::Meta::Attribute + tests
30
31     * Moose::Object
32       - Foo->new(undef) now gets ignored, it is assumed you meant to pass
33         a HASH-ref and missed. This produces better error messages then 
34         having it die cause undef is not a HASH.
35         - added tests for this
36
37 0.21 Thursday, May 2nd, 2007
38     * Moose
39       - added SUPER_SLOT and INNER_SLOT class hashes to support unimport
40       - modified unimport to remove super and inner along with the rest
41         - altered unimport tests to handle this
42
43     * Moose::Role
44       - altered super export to populate SUPER_SLOT
45
46     * Moose::Meta::Class
47       - altered augment and override modifier application to use *_SLOT
48         - modified tests for these to unimport one test class each to test
49
50     * Moose::Meta::Role
51       - fixed issue where custom attribute metaclasses
52         where not handled correctly in roles
53         - added tests for this
54     
55     * Moose::Meta::Class
56       - fixed issue where extending metaclasses with 
57         roles would blow up. Thanks to Aankhen`` for
58         finding this insidious error, and it's solution.
59         
60     ~~ lots of spelling and grammer fixes in the docs, 
61        many many thanks to rlb3 and Aankhen for these :)
62
63 0.20 Friday, April 6th, 2007
64     >> I messed up the SKIP logic in one test
65        so this release is just to fix that.
66
67     * Moose
68       - 'has' now also accepts an ARRAY ref
69         to create multiple attrs (see docs)
70         (thanks to konobi for this)
71          - added tests and docs 
72
73 0.19 Thurs. April 5th, 2007
74     ~~ More documentation updates ~~
75
76     * Moose::Util::TypeConstraints
77       - 'type' now supports messages as well
78         thanks to phaylon for finding this
79         - added tests for this
80       - added &list_all_type_constraints and 
81         &list_all_builtin_type_constraints
82         functions to facilitate introspection.
83     
84     * Moose::Meta::Attribute
85       - fixed regexp 'handles' declarations 
86         to build the list of delegated methods
87         correctly (and not override important 
88         things like &new) thanks to ashleyb 
89         for finding this
90         - added tests and docs for this
91       - added the 'documentation' attributes
92         so that you can actually document your 
93         attributes and inspect them through the 
94         meta-object.
95         - added tests and docs for this
96
97     * Moose::Meta::Class
98       - when loading custom attribute metaclasses
99         it will first look in for the class in the 
100         Moose::Meta::Attribute::Custom::$name, and 
101         then default to just loading $name.
102         - added tests and docs for this
103
104     * Moose::Meta::TypeConstraint
105       - type constraints now stringify to their names.
106         - added test for this
107
108     * misc.
109       - added tests to assure we work with Module::Refresh 
110       - added stricter test skip logic in the Moose POOP 
111         test, ask Rob Kinyon why.
112         - *cough* DBM::Deep 1.0 backwards compatability sucks *cough* ;)
113
114 0.18 Sat. March 10, 2007
115     ~~ Many, many documentation updates ~~
116
117     * misc.
118       - We now use Class::MOP::load_class to 
119         load all classes.    
120       - added tests to show types and subtypes 
121         working with Declare::Constraints::Simple
122         and Test::Deep as constraint engines.
123
124 0.18_001
125     !! You must have Class::MOP 0.37_001  !!
126     !! for this developer release to work !!
127
128     This release was primarily adding the immutable
129     feature to Moose. An immutable class is one which 
130     you promise not to alter. When you set the class 
131     as immutable it will perform various bits of 
132     memoization and inline certain part of the code
133     (constructors, destructors and accessors). This 
134     minimizes (and in some cases totally eliminates)
135     one of Moose's biggest performance hits. This 
136     feature is not on by default, and is 100% optional.
137     It has several configurable bits as well, so you 
138     can pick and choose to your specific needs.
139     
140     The changes involved in this were fairly wide and 
141     highly specific, but 100% backwards compatible, so 
142     I am not going to enumerate them here. If you are 
143     truely interested in what was changed, please do 
144     a diff :)
145
146 0.17 Tues. Nov. 14, 2006
147     * Moose::Meta::Method::Accessor
148       - bugfix for read-only accessors which 
149         are have a type constraint and lazy.
150         Thanks to chansen for finding it.
151
152 0.16 Tues. Nov. 14, 2006
153     ++ NOTE ++
154     There are some speed improvements in this release, 
155     but they are only the begining, so stay tuned.
156     
157     * Moose::Object
158       - BUILDALL and DEMOLISHALL no longer get 
159         called unless they actually need to be.
160         This gave us a signifigant speed boost
161         for the cases when there is no BUILD or 
162         DEMOLISH method present.
163         
164     * Moose::Util::TypeConstraints
165     * Moose::Meta::TypeConstraint
166       - added an 'optimize_as' option to the 
167         type constraint, which allows for a
168         hand optimized version of the type 
169         constraint to be used when possible.
170       - Any internally created type constraints
171         now provide an optimized version as well.
172
173 0.15 Sun. Nov. 5, 2006
174     ++ NOTE ++
175     This version of Moose *must* have Class::MOP 0.36 in order 
176     to work correctly. A number of small internal tweaks have 
177     been made in order to be compatible with that release.
178
179     * Moose::Util::TypeConstraints
180       - added &unimport so that you can clean out 
181         your class namespace of these exported 
182         keywords
183     
184     * Moose::Meta::Class
185       - fixed minor issue which occasionally 
186         comes up during global destruction 
187         (thanks omega)
188       - moved Moose::Meta::Method::Overriden into 
189         its own file.
190       
191     * Moose::Meta::Role      
192       - moved Moose::Meta::Role::Method into 
193         its own file.
194               
195     * Moose::Meta::Attribute
196       - changed how we do type checks so that 
197         we reduce the overall cost, but still 
198         retain correctness.
199        *** API CHANGE ***
200       - moved accessor generation methods to 
201         Moose::Meta::Method::Accessor to 
202         conform to the API changes from 
203         Class::MOP 0.36
204           
205     * Moose::Meta::TypeConstraint
206       - changed how constraints are compiled
207         so that we do less recursion and more
208         iteration. This makes the type check 
209         faster :)
210       - moved Moose::Meta::TypeConstraint::Union
211         into its own file
212     
213     * Moose::Meta::Method::Accessor
214       - created this from methods formerly found in 
215         Moose::Meta::Attribute
216     
217     * Moose::Meta::Role::Method
218       - moved this from Moose::Meta::Role
219           
220     * Moose::Meta::Method::Overriden
221       - moved this from Moose::Meta::Class
222       
223     * Moose::Meta::TypeConstraint::Union
224       - moved this from Moose::Meta::TypeConstraint
225
226 0.14 Mon. Oct. 9, 2006
227
228     * Moose::Meta::Attribute
229       - fixed lazy attributes which were not getting 
230         checked with the type constraint (thanks ashley)
231         - added tests for this
232       - removed the over-enthusiastic DWIMery of the 
233         automatic ArrayRef and HashRef defaults, it 
234         broke predicates in an ugly way.
235         - removed tests for this
236
237 0.13 Sat. Sept. 30, 2006
238     ++ NOTE ++
239     This version of Moose *must* have Class::MOP 0.35 in order 
240     to work correctly. A number of small internal tweaks have 
241     been made in order to be compatible with that release.
242
243     * Moose
244       - Removed the use of UNIVERSAL::require to be a better
245         symbol table citizen and remove a dependency 
246         (thanks Adam Kennedy)
247
248       **~~ removed experimental & undocumented feature ~~**
249       - commented out the 'method' and 'self' keywords, see the 
250         comments for more info.
251
252     * Moose::Cookbook
253       - added a FAQ and WTF files to document frequently 
254         asked questions and common problems
255         
256     * Moose::Util::TypeConstraints
257       - added GlobRef and FileHandle type constraint
258         - added tests for this
259         
260     * Moose::Meta::Attribute
261       - if your attribute 'isa' ArrayRef of HashRef, and you have
262         not explicitly set a default, then make the default DWIM.
263         This will also work for subtypes of ArrayRef and HashRef 
264         as well.
265       - you can now auto-deref subtypes of ArrayRef or HashRef too.
266         - new test added for this (thanks to ashley)
267         
268     * Moose::Meta::Role
269       - added basic support for runtime role composition
270         but this is still *highly experimental*, so feedback 
271         is much appreciated :)
272         - added tests for this
273
274     * Moose::Meta::TypeConstraint
275       - the type constraint now handles the coercion process
276         through delegation, this is to support the coercion 
277         of unions
278         
279     * Moose::Meta::TypeConstraint::Union
280       - it is now possible for coercions to be performed 
281         on a type union
282         - added tests for this (thanks to konobi)
283
284     * Moose::Meta::TypeCoercion
285       - properly capturing error when type constraint 
286         is not found
287
288     * Build.PL
289       - Scalar::Util 1.18 is bad on Win32, so temporarily
290         only require version 1.17 for Win32 and cygwin.
291         (thanks Adam Kennedy)        
292
293 0.12 Sat. Sept. 1, 2006
294     * Moose::Cookbook
295       - Recipe5 (subtypes & coercion) has been written
296       
297     * Moose
298       - fixed "bad meta" error message to be more descriptive      
299       - fixed &unimport to not remove the &inner and &super  
300         keywords because we need to localize them.
301       - fixed number of spelling/grammer issues, thanks Theory :)
302       
303       **~~ experimental & undocumented feature ~~**
304       - added the method and self keywords, they are basically 
305         just sugar, and they may not stay around.
306         
307     * Moose::Object
308       - added &dump method to easily Data::Dumper 
309         an object
310         
311     * Moose::Meta::TypeConstraint
312       - added the &is_a_type_of method to check both the current
313         and the subtype of a method (similar to &isa with classes)
314
315     * Moose::Meta::Role
316       - this is now a subclass of Class::MOP::Module, and no longer
317         creates the _role_meta ugliness of before. 
318         - fixed tests to reflect this change
319     
320 0.11 Wed. July 12, 2006
321     * Moose
322       - added an &unimport method to remove all the keywords
323         that Moose will import, simply add 'no Moose' to the 
324         bottom of your class file. 
325         
326     * t/
327       - fixed some test failures caused by a forgotten test 
328         dependency.
329
330 0.10 Thurs. July 6, 2006
331     * Moose
332       - improved error message when loading modules so
333         it is less confusing when you load a role.
334       - added &calculate_all_roles method to 
335         Moose::Meta::Class and Moose::Meta::Role
336         
337     NOTE:
338     This module has been tested against Class::MOP 0.30
339     but it does not yet utilize the optimizations 
340     it makes available. Stay tuned for that ;)
341     
342 0.09_03 Fri. June 23, 2006
343     ++ DEVELOPER RELEASE ++
344     * Moose
345       - 'use strict' and 'use warnings' are no longer
346          needed in Moose classes, Moose itself will 
347          turn them on for you.
348          - added tests for this
349       - moved code from exported subs to private methods
350         in Moose::Meta::Class
351          
352     * Moose::Role
353       - as with Moose, strict and warnings are 
354         automatically turned on for you.
355          - added tests for this        
356         
357     * Moose::Meta::Role
358       - now handles an edge case for override errors
359         - added tests for this
360       - added some more edge case tests
361
362 0.09_02 Tues. May 16, 2006
363     ++ DEVELOPER RELEASE ++
364     * Moose
365       - added prototypes to the exported subs
366       - updated docs
367       
368     * Moose::Role
369       - added prototypes to the exported subs      
370       - updated docs
371       
372     * Moose::Util::TypeConstraints
373       - cleaned up prototypes for the subs      
374       - updated docs      
375
376 0.09_01 Fri. May 12, 2006
377     ++ DEVELOPER RELEASE ++
378       - This release works in combination with 
379         Class::MOP 0.29_01, it is a developer 
380         release because it uses the a new 
381         instance sub-protocol and a fairly
382         complete Role implementation. It has 
383         not yet been optimized, so it slower
384         the the previous CPAN version. This 
385         release also lacks good updated docs, 
386         the official release will have updated docs.
387
388     * Moose 
389       - refactored the keyword exports
390         - 'with' now checks Role validaity and 
391           accepts more than one Role at a time
392         - 'extends' makes metaclass adjustments as 
393            needed to ensure metaclass compatability
394           
395     * Moose::Role
396       - refactored the keyword exports
397         - 'with' now checks Role validaity and 
398           accepts more than one Role at a time
399           
400     * Moose::Util::TypeConstraints
401       - added the 'enum' keyword for simple 
402         string enumerations which can be used as 
403         type constraints
404         - see example of usage in t/202_example.t
405         
406     * Moose::Object
407       - more careful checking of params to new()
408       
409     * Moose::Meta::Role
410       - much work done on the role composition
411         - many new tests for conflict detection 
412           and composition edge cases
413         - not enough documentation, I suggest 
414           looking at the tests    
415       
416     * Moose::Meta::Instance
417       - added new Instance metaclass to support 
418         the new Class::MOP instance protocol
419         
420     * Moose::Meta::Class
421       - some small changes to support the new 
422         instance protocol
423       - some small additions to support Roles
424         
425     * Moose::Meta::Attribute
426       - some improvements to the accessor generation code
427         by nothingmuch
428       - some small changes to support the new 
429         instance protocol
430       - (still somewhat) experimental delegation support 
431         with the 'handles' option
432         - added several tests for this
433         - no docs for this yet
434
435 0.05 Thurs. April 27, 2006
436     * Moose
437       - keywords are now exported with Sub::Exporter
438         thanks to chansen for this commit
439       - has keyword now takes a 'metaclass' option 
440         to support custom attribute meta-classes 
441         on a per-attribute basis
442         - added tests for this  
443       - the 'has' keyword not accepts inherited slot
444         specifications (has '+foo'). This is still an 
445         experimental feature and probably not finished
446         see t/038_attribute_inherited_slot_specs.t for 
447         more details, or ask about it on #moose
448         - added tests for this
449         
450     * Moose::Role
451       - keywords are now exported with Sub::Exporter
452
453     * Moose::Utils::TypeConstraints
454       - reorganized the type constraint hierarchy, thanks
455         to nothingmuch and chansen for his help and advice 
456         on this
457         - added some tests for this
458       - keywords are now exported with Sub::Exporter
459         thanks to chansen for this commit
460
461     * Moose::Meta::Class
462       - due to changes in Class::MOP, we had to change
463         construct_instance (for the better)
464         
465     * Moose::Meta::Attribute
466       - due to changes in Class::MOP, we had to add the 
467         initialize_instance_slot method (it's a good thing)
468         
469     * Moose::Meta::TypeConstraint
470       - added type constraint unions 
471         - added tests for this
472       - added the is_subtype_of predicate method
473         - added tests for this
474
475 0.04 Sun. April 16th, 2006
476     * Moose::Role
477       - Roles can now consume other roles
478         - added tests for this
479       - Roles can specify required methods now with 
480         the requires() keyword
481         - added tests for this
482
483     * Moose::Meta::Role
484       - ripped out much of it's guts ,.. much cleaner now
485       - added required methods and correct handling of 
486         them in apply() for both classes and roles
487         - added tests for this
488       - no longer adds a does() method to consuming classes 
489         it relys on the one in Moose::Object
490       - added roles attribute and some methods to support 
491         roles consuming roles
492
493     * Moose::Meta::Attribute
494       - added support for triggers on attributes
495         - added tests for this
496       - added support for does option on an attribute 
497         - added tests for this
498         
499     * Moose::Meta::Class
500       - added support for attribute triggers in the 
501         object construction
502         - added tests for this
503     
504     * Moose
505       - Moose no longer creates a subtype for your class 
506         if a subtype of the same name already exists, this 
507         should DWIM in 99.9999% of all cases
508         
509     * Moose::Util::TypeConstraints
510       - fixed bug where incorrect subtype conflicts were 
511         being reported
512         - added test for this
513         
514     * Moose::Object
515       - this class can now be extended with 'use base' if
516         you need it, it properly loads the metaclass class now
517         - added test for this
518
519 0.03_02 Wed. April 12, 2006
520     * Moose
521       - you must now explictly use Moose::Util::TypeConstraints
522         it no longer gets exported for you automatically
523         
524     * Moose::Object
525       - new() now accepts hash-refs as well as key/value lists
526       - added does() method to check for Roles
527         - added tests for this
528
529     * Moose::Meta::Class
530       - added roles attribute along with the add_role() and 
531         does_role() methods
532         - added tests for this 
533
534     * Moose::Meta::Role
535       - now adds a does() method to consuming classes 
536         which tests the class's hierarchy for roles
537         - added tests for this
538
539 0.03_01 Mon. April 10, 2006
540     * Moose::Cookbook
541       - added new Role recipe (no content yet, only code)
542       
543     * Moose
544       - added 'with' keyword for Role support
545         - added test and docs for this
546       - fixed subtype quoting bug
547         - added test for this 
548
549     * Moose::Role
550       - Roles for Moose
551         - added test and docs
552
553     * Moose::Util::TypeConstraints
554       - added the message keyword to add custom
555         error messages to type constraints        
556       
557     * Moose::Meta::Role
558       - the meta role to support Moose::Role
559         - added tests and docs
560         
561     * Moose::Meta::Class
562       - moved a number of things from Moose.pm 
563         to here, they should have been here 
564         in the first place
565
566     * Moose::Meta::Attribute
567       - moved the attribute option macros here
568         instead of putting them in Moose.pm
569
570     * Moose::Meta::TypeConstraint
571       - added the message attributes and the 
572         validate method
573         - added tests and docs for this
574
575 0.03 Thurs. March 30, 2006
576     * Moose::Cookbook
577       - added the Moose::Cookbook with 5 recipes, 
578         describing all the stuff Moose can do.
579
580     * Moose
581       - fixed an issue with &extends super class loading
582         it now captures errors and deals with inline 
583         packages correctly (bug found by mst, solution 
584         stolen from alias)
585       - added super/override & inner/augment features
586         - added tests and docs for these
587     
588     * Moose::Object
589       - BUILDALL now takes a reference of the %params 
590         that are passed to &new, and passes that to 
591         each BUILD as well.
592         
593     * Moose::Util::TypeConstraints
594       - Type constraints now survive runtime reloading
595         - added test for this
596
597         * Moose::Meta::Class
598           - fixed the way attribute defaults are handled 
599             during instance construction (bug found by chansen)
600
601     * Moose::Meta::Attribute
602       - read-only attributes now actually enforce their
603         read-only-ness (this corrected in Class::MOP as 
604         well)
605
606 0.02 Tues. March 21, 2006
607     * Moose
608       - many more tests, fixing some bugs and  
609         edge cases
610       - &extends now loads the base module with
611         UNIVERSAL::require 
612         - added UNIVERSAL::require to the 
613           dependencies list
614       ** API CHANGES **
615       - each new Moose class will also create 
616         and register a subtype of Object which 
617         correspond to the new Moose class.      
618       - the 'isa' option in &has now only 
619         accepts strings, and will DWIM in 
620         almost all cases
621     
622     * Moose::Util::TypeConstraints
623       - added type coercion features
624         - added tests for this
625         - added support for this in attributes 
626           and instance construction
627       ** API CHANGES **
628       - type construction no longer creates a 
629         function, it registers the type instead.
630         - added several functions to get the 
631           registered types 
632
633     * Moose::Object
634       - BUILDALL and DEMOLISHALL were broken 
635         because of a mis-named hash key, Whoops :)
636     
637     * Moose::Meta::Attribute
638       - adding support for coercion in the
639         autogenerated accessors
640         
641     * Moose::Meta::Class
642       - adding support for coercion in the
643         instance construction  
644
645     * Moose::Meta::TypeConstraint
646     * Moose::Meta::TypeCoercion
647           - type constraints and coercions are now 
648             full fledges meta-objects
649
650 0.01 Wed. March 15, 2006
651     - Moooooooooooooooooose!!!