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