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