changing make_{immtable,mutable} to return 1
[gitmo/Class-MOP.git] / Changes
1 Revision history for Perl extension Class-MOP.
2
3 0.54
4     * Class::MOP::Class
5       - make_{immutable,mutable} now return 1
6         (cause Sartak asked)
7  
8     * t/
9       - fixed the filename length on several 
10         test files so we install on VMS better
11         (RT #32295)
12       - fixed incorrect use of catdir when it 
13         should be catfile (RT #32385)
14
15 0.53 Thurs. Feb. 14, 1008
16     ~~ several doc. fixes and updates ~~
17         
18     * Class::MOP::Class
19       Class::MOP::Method::Constructor
20       Class::MOP::Attribute
21         - making init_arg accept an undefined value
22           to indicate that no constructor args can 
23           be passed (thanks to nothingmuch)
24           - added tests for this
25         - added attribute initializer attribute (rjbs)
26           
27     * Class::MOP.
28         - making this use the new init_arg => undef
29           feature instead of the silly hack from 
30           before (thanks to nothingmuch)
31
32 0.52 Tues. Jan. 22, 2008
33     * Class::MOP::Class
34       - fixed bug in rebless_instance 
35         (discovered by ash)
36
37     * Class::MOP::Method::Constructor
38       - removed assumptions about the existence of 
39         a &meta method
40
41 0.51 Mon. Jan. 14, 2008
42     ~~~ some misc. doc. fixes ~~~
43     ~~ updated copyright dates ~~
44     
45     * Class::MOP
46       - now sets the IS_RUNNING_ON_5_10 
47         constant so that we can take advantage
48         of some of the nice bits of 5.10
49     
50     * Class::MOP::Class
51       - uses the IS_RUNNING_ON_5_10 flag to 
52         optimize the &linearized_isa method 
53         and avoid the hack/check for circular
54         inheritence in &class_precedence_list 
55       - added rebless_instance method (Sartak)
56         - added tests for this
57     
58     * Class::MOP::Immutable 
59       - the immutable class now keeps track of 
60         the transformer which immutablized it
61
62     * Class::MOP::Instance
63       - added rebless_instance_structure method (Sartak)
64         - added tests for this
65
66 0.50 Fri. Dec. 21, 2007
67     * Class::MOP::Class
68       - fixed bug in immutable to make sure that 
69         transformation arguments are saved 
70         correctly (mst)
71         - added tests for this
72         
73     * Class::MOP::Immutable
74       - fixed a bug (see above)
75       
76     * Class::MOP::Attribute
77       - some doc updates
78
79 0.49 Fri. Dec. 14, 2007
80     !! Class::MOP now loads 2 x faster  !!
81     !! with XS speedups (thanks konobi) !!
82         
83     * Class::MOP
84       - removed the dependency on B
85       - added two XS functions (thanks konobi)
86         - get_code_info($code) which replaces all
87           the B fiddling we were doing with
88           faster/leaner XS level fiddling
89         - check_package_cache_flag($pkg_name) which 
90           returns the PL_sub_generation variable to 
91           be used to help manage method caching.
92           
93           NOTE: 
94           In 5.10 or greater this will actually 
95           use the mro::get_pkg_gen instead to give 
96           even more accurate caching information. 
97           blblack++ for that stuff :)
98           
99     * Class::MOP::Class
100       - added the &subclasses method (thanks rlb)
101       - added the update_package_cache_flag and 
102         reset_package_cache_flag which help keep 
103         track of when we need to re-fetch the 
104         method map. 
105       - Several small improvements to take advantage
106         of the new method map caching features
107
108 0.48 Mon. Nov. 26, 2007
109     * Class::MOP::Attribute
110       - fixed get_read/write_method to handle the 
111         HASH ref case, which makes the 
112         get_read/write_method_ref handle it too.
113         - added more tests for this
114
115 0.47 Sat. Nov. 24, 2007
116     * Class::MOP::Attribute
117       - fixed misspelling in get_write_method_ref
118         - added more tests for this
119
120 0.46 Fri. Nov. 23, 2007
121     * Class::MOP::Class
122       - added the linearized_isa method instead of constantly 
123         pruning duplicate classes (this will be even more 
124         useful in the 5.10-compat version coming soon)
125     
126     * Class::MOP::Attribute
127       - added the get_read_method_ref and get_write_method_ref
128         methods which allow you to retrieve a CODE ref which 
129         can always be used to read or write an attribute.
130
131 0.45 Thurs. Nov. 13, 2007
132     * Class::MOP::Attribute
133       - Fix error message on confess (groditi)
134
135 0.44 Thurs. Nov. 13, 2007
136     - Apparently I didn't make dist correctly (groditi)
137
138 0.43 Thurs. Nov. 13, 2007
139     * Class::MOP
140       - Add support for the 'builder' attribute (groditi)
141
142     * Class::MOP::Class
143       - optimise metaclass-already-exists check in 
144         construct_class_instance (groditi)
145       - duplicate check into initialize to save a 
146         call through (groditi)
147
148     * Class::MOP::Attribute
149       - Add support for the 'builder' attribute (groditi)
150       - Make predicates check for the existence of a value, not whether 
151         it is defined (groditi)
152
153     * Class::MOP::Instance
154       - Make predicates check for the existence of a value, not whether 
155         it is defined (groditi)
156
157     * Class::MOP::Method::Accessor 
158       - made this a subclass of Class::MOP::Method::Generated
159         - removed the relevant attributes
160
161     * Class::MOP::Method::Constructor
162       - fixed the cached values we had to be more sane
163       - made this a subclass of Class::MOP::Method::Generated
164       - fixed generated constructor so it properly handles 
165         subclasses now.
166         - added tests for this
167       - added the option to allow for both inlined and 
168         non-inlined constructors.
169       - Update inlined methods for builder and predicate changes (groditi)
170
171     * Class::MOP::Method::Generated
172       - added this class as an abstract base for the 
173         Class::MOP::Method::{Constructor,Accessor} classes
174         - added tests for this
175
176     *t/
177       - Alter tests (005, 014 020, 021) for new builder addition (groditi)
178       - Tests for new predicate behavior (and corrections to old tests) (groditi)
179
180     *examples/
181       - Update ArrayRef based class example to work with predicate changes
182
183 0.42 Mon. July 16, 2007
184     !!! Horray for mst, he fixed it !!!
185
186     * Class::MOP::Package
187       - alter symbol table handling to deal with 5.8.x and 5.9.x
188       
189     * t/
190       - Get rid of the crappy workaround from 0.40/41
191
192 0.41 Sun. July 15, 2007
193     * t/
194         Arghh!!! My TODO test didn't work, so I handle
195         it manually now so that people can use this 
196         with 5.9.5/bleadperl without issue.
197
198 0.40 Tues, July 3, 2007
199     * t/
200       ~ marked a test in 003_methods.t as TODO 
201         for perl 5.9.5 (this test is irrelvant to 
202         the module functioning on 5.9.5 for the most 
203         part anyway)
204
205 0.39 Mon. June 18, 2007
206     * Class::MOP::Immutable
207       - added make_metaclass_mutable + docs (groditi)
208       - removed unused variable
209       - added create_immutable_transformer
210         necessary for sane overloading of immutable behavior
211          - tests for this (groditi) 
212
213     * Class::MOP::Class
214       - Immutability can now be undone,
215         added make_mutable + tests + docs (groditi)
216       - Massive changes to the way Immutable is done
217         for details see comments next to make_immutable
218         This fixes a bug where custom metaclasses broke
219         when made immutable. We are now keeping one immutable 
220         metaclass instance per metaclass instead of just one 
221         to prevent isa hierarchy corruption. Memory use will go
222         up, but I suspect it will be neglible.
223          - New tests added for this behavior.  (groditi)
224
225 0.38 Thurs. May 31, 2007
226     ~~ More documentation updates ~~
227     
228     * Class::MOP::Package
229       - we now deal with stub methods properly
230         - added tests for this
231       - fixed some tests failing on 5.9.5 (thanks blblack)
232         
233     * Class::MOP::Attribute
234       - added get_read_method and get_write_method
235         thanks to groditi for this code, tests 
236         and docs.
237         - added tests and POD for this
238     
239     * Class::MOP::Class
240       - fixed RT issue #27329, clone object now 
241         handles undef values correctly.
242         - added tests for this
243       - Corrected anon-class handling so that they 
244         will not get reaped when instances still 
245         exist which need to reference them. This is 
246         the correct behavior, hopefully this is an 
247         obscure enough feature that there are not too 
248         many work arounds out in the wild.
249         - added tests for this by groditi   
250         - updated docs to explain this
251
252     * metaclass
253       - load custom metaclasses automatically (thanks groditi)
254         - added tests for this behavior
255
256 0.37 Sat. March 10, 2007
257     ~~ Many, many documentation updates ~~
258     
259     * Class::MOP
260       - added &load_class and &is_class_loaded 
261         - added tests and docs for these
262
263     * Class::MOP::Attribute
264       - default now checks the instance with defined to 
265         avoid setting off bool-overloads (found by Carl Franks)
266
267 0.37_002
268     * /t 
269       - bad name in a test, causing meaningless failuress. 
270         No other changes.
271
272 0.37_001
273     
274     ~~ GLOBAL CHANGES ~~
275     - All attribute names are now consistent and follow Perl 6 
276       style (prefixed with the sigil, and ! as the twigil for 
277       private attrs). This should not affect any code, unless 
278       you broke encapsulation, in which case, it is your problem 
279       anyway.
280       
281     !! Class::MOP::Class::Immutable has been removed
282     
283     * Class::MOP::Method::Constructor
284       - this has been moved out of Class::MOP::Class::Immutable 
285         and is a proper subclass of Class::MOP::Method now.
286         
287     * Class::MOP::Class
288       - this module now uses Class::MOP::Immutable for the 
289         immutable transformation instead of 
290         Class::MOP::Class::Immutable.
291         
292     + Class::MOP::Immutable 
293       - this module now controls the transformation from a mutable 
294         to an immutable version of the class. Docs for this will 
295         be coming eventually.
296     
297
298 0.36 Sun. Nov. 5, 2006
299     * Class::MOP::Class
300       - added a few 'no warnings' lines to keep annoying 
301         (and meaningless) warnings from chirping during 
302         global destruction.
303           
304     * Class::MOP
305       - some more bootstrapping is now done on the new 
306         classes
307     
308     * Class::MOP::Class::Immutable
309       *** API CHANGE ***    
310       - constructor generation is now handled by 
311         the Class::MOP::Method::Constructor class
312      
313     * Class::MOP::Method::Constructor
314       - created this to handle constructor generation 
315         in Class::MOP::Class::Immutable
316     
317     * Class::MOP::Attribute
318       *** API CHANGE ***    
319       - attributes now delegate to the 
320         Class::MOP::Method::Accessor to generate 
321         accessors
322     
323     * Class::MOP::Method::Accessor
324       - all accessor generation functions from 
325         Class::MOP::Attribute have been moved here
326
327 0.35 Sat. Sept. 30, 2006
328
329     * scripts/class_browser.pl
330       - initial prototype of a class browser, more 
331         on this to come. Comments and patches are 
332         very much welcome.
333
334     * Class::MOP
335       - All Class::MOP::* accessors are no longer 
336         re-generated in the bootstrap, instead 
337         they are aliased from the originals
338         - fixed tests to reflect
339       - added Class::MOP::Method (and its subclasses) 
340         to the bootstrap
341         - adjusted tests for this
342       - added the Class::MOP::Instance attributes
343         to the bootstrap
344     
345     * Class::MOP::Method
346       *** API CHANGE ***
347       - methods are no longer blessed CODE refs
348         but are actual objects which can be CODE-ified
349         - adjusted tests to compensate
350         - adjusted docs for this        
351
352     * Class::MOP::Class
353       - changed how methods are dealt with to 
354         encapsulate most of the work into the 
355         &get_method_map method
356       - made several adjustments for the change
357         in Class::MOP::Method
358       - &add_attribute now checks if you are adding 
359         a duplicate name, and properly removes the 
360         old one before installing the new one
361         - added tests for this
362         - adjusted docs for this
363     
364     * Class::MOP::Class::Immutable
365       - added caching of &get_method_map
366       - fixed issue with &get_package_symbol
367       - cleaned up the methods that die (patch by David Wheeler)
368     
369     * Class::MOP::Package
370       - added filtering capabilities to 
371         &list_all_package_symbols
372
373 0.34 Sat. Aug. 26, 2006
374     * Class::MOP::Class
375       - added the %:methods attribute, which like
376         the $:version and such just actually goes 
377         to the symbol table to get it's stuff. 
378         However, it makes the MOP more complete.
379      ** API CHANGE **
380       - The &create method now requires that all 
381         but the package name now is passed in as 
382         named parameters. See docs for more info.
383         - updated docs and tests for this
384         
385     * Class::MOP::Object
386       - added &dump method to easily Data::Dumper 
387         an object
388         
389     * Class::MOP
390       - cleaned up the initialization of attributes 
391         which do not store things in the instance 
392       - added the %:methods attribute definition to
393         the bootstrap
394         
395     ~ lots of misc. test cleanup
396
397 0.33 Sat. Aug. 19, 2006
398     * Class::MOP::Class
399       - moved the metaclass cache out of here 
400         and it is now in Class::MOP itself.
401         
402     * Class::MOP
403       - moved all the metaclass cache stuff here
404         - fixed all tests for this
405
406     * Class::MOP::Attribute
407       - reference values (other than CODE refs) 
408         are no longer allowed for defaults
409         - added tests for this
410     
411     * Class::MOP::Package
412       - fixed an issue with perl 5.8.1 and how it deals 
413         with symbol tables. The namespace hash is now 
414         always reloaded from the symbol table. 
415
416     ~ lots of misc. documentation cleanup
417
418 0.32 Sat. Aug. 12, 2006
419     + added Class::MOP::Object so that the 
420       metamodel is more complete (and closer
421       to what Perl 6 will probably be).
422
423     * Class::MOP::Package
424       - refactored entire class, this is now 
425         the primary gateway between the metaclass
426         and the Perl 5 symbol table
427         - added many tests for this
428       - this class is now a subclass of 
429         Class::MOP::Object
430         - added some tests to reflect this
431         
432     * Class::MOP::Class
433       - refactored all symbol table access to 
434         use Class::MOP::Package methods instead
435         
436     * Class::MOP::Module
437       - adding the $:version attribute in the bootstrap
438         so that Module has a version as an attribute
439         - see comment in Class::MOP for details
440       - added the $:authority attribute to this module 
441         as well as an &identifier method, to bring us 
442         ever closer to Perl 6 goodness 
443         - I have added $AUTHORITY to all the modules 
444         - added tests for this
445       
446     * Class::MOP::Instance
447       - added &deinitialize_slot for removing slots 
448         from an instance
449         - added tests for this      
450       
451     * Class::MOP::Attribute 
452       - added support for &deinitialize_slot for removing
453         slots from an instance
454         - added tests for this
455
456 0.31 Sat. July 15, 2006
457
458     * Class::MOP::Class
459       - added &find_method_by_name to locate a method
460         anywhere within the class hierarchy   
461         
462     * Class::MOP::Attribute
463       - added &set_value and &get_value for getting 
464         the value of the attribute for a particular 
465         instance.
466
467 0.30 Wed. July 5, 2006
468     ---------------------------------------
469     This is the first version of Class::MOP 
470     to introduce the immutable features which
471     will be used for optimizating the MOP. 
472     This support should still be considered
473     experimental, but moving towards stability.
474     ---------------------------------------
475     
476     * Created Class::MOP::Class::Immutable  
477     
478     * Created the Class::MOP::Package and 
479       Class::MOP::Module classes to more 
480       closely conform to Perl 6's meta-model
481
482     * Class::MOP::Class
483       - now inherits from Class::MOP::Module
484       - several methods moved to ::Module and 
485         ::Package and now inherited
486         - added tests for this
487       
488     * Class::MOP::Instance
489       - added an is_inlinable method to allow other 
490         classes to check before they attempt to optimize.
491       - added an inline_create_instance to inline 
492         instance creation (of course) 
493         
494     ** API CHANGE **
495       - the Class::MOP::Class::*_package_variable 
496         methods are all now methods of Class::MOP::Package
497         and called *_package_symbol instead. This is 
498         because they are now more general purpose symbol 
499         table manipulation methods.        
500
501 0.29_02 Thurs. June 22, 2006
502     ++ DEVELOPER RELEASE ++
503     * Class::MOP::Class
504       - small change in &create so that it behaves 
505         properly when inherited
506       - small fix to &clone_instance
507
508 0.29_01 Fri. May 12, 2006
509     ++ DEVELOPER RELEASE ++
510       - This release works in combination with 
511         Moose 0.09_01, it is a developer release
512         because it introduces a new instance 
513         sub-protocol and has not yet been 
514         optimized.  
515
516     * Class::MOP::Class
517       - anon-classes are now properly garbage collected
518         - added tests for this 
519       - improved method modifier wrapping 
520
521     * Class::MOP::Instance
522       - added new instance protocol
523         - added tests for this
524       - changed all relevant modules and examples
525         - Class::MOP::Class
526         - Class::MOP::Attribute
527         - examples/*
528
529     * metaclass
530       - you no longer need to specify the metaclass
531         itself, if it is not there, Class::MOP::Class
532         is just assumed
533         - updated tests for this
534
535     * examples/
536       - added ArrayBasedStorage example to show 
537         instance storage using ARRAY refs instead of
538         HASH refs. 
539         - added tests for this
540       - InsideOutClass is totally revised using the 
541         new instance protocol
542         - added more tests for this
543
544 0.26 Mon. April 24, 2006
545     * Class::MOP::Class
546       - added find_attribute_by_name method
547         - added tests and docs for this
548       - some small optimizations
549
550     * Class::MOP::Attribute
551       - some small optimizations
552
553 0.25 Thurs. April 20, 2006
554     * Class::MOP::Class
555       - added create_anon_class for creating anonymous classes
556         - added tests for this
557       - added get_all_metaclasses, get_all_metaclass_names
558         and get_all_metaclass_instances method to allow
559         access to all the cached metaclass objects.
560       - attribute slot initialization is now the responsibility
561         of the attribute itself, and construct_instance now 
562         delegates appropriately
563         
564     * Class::MOP::Attribute
565       - attribute slot initialization is now the responsibility
566         of the attribute itself, so we added a method for it
567         called initialize_instance_slot
568     
569     * examples/
570       - adjusted all the examples to use the new attribute 
571         initialize_instance_slot method 
572
573 0.24 Tues. April 11, 2006
574     * Class::MOP::Class
575       - cleaned up how the before/after/around method 
576         modifiers get named with Sub::Name
577
578 0.23 Thurs. March 30, 2006
579         * Class::MOP::Class
580           - fixed the way attribute defaults are handled 
581             during instance construction (bug found by chansen)
582             
583         * Class::MOP::Attribute
584           - read-only accessors ('reader') will now die if 
585             passed more than one argument (attempting to write
586             to them basically)
587               - added tests for this
588               - adjusted all /example files to comply 
589
590 0.22 Mon. March 20, 2006
591     * Class::MOP::Class
592       - localized $@ in the *_package_variable functions
593         because otherwise, it does ugly things in Moose.
594           - added test case for this
595
596 0.21 Wed. March 15, 2006
597     * Class::MOP::Class
598       - fixed issue where metaclasses are reaped from 
599         our cache in global destruction, and so are not
600         available in DESTORY calls
601
602 0.20 Thurs. March 2, 2006
603     - removed the dependency for Clone since 
604       we no longer to deep-cloning by default.
605     
606     * Class::MOP::Method
607       - added &package_name, &name and 
608         &fully_qualified_name methods, some of 
609         which were formerly private subs in 
610         Class::MOP::Class
611       
612     * Class::MOP::Method::Wrapped
613       - allows for a method to be wrapped with 
614         before, after and around modifiers 
615           - added tests and docs for this feature
616
617     * Class::MOP::Class
618       - improved &get_package_symbol
619           - &version and &superclasses now use it
620       - methods are now blessed into Class::MOP::Method
621         whenever possible
622       - added methods to install CLOS-style method modifiers 
623          - &add_before_method_modifier
624          - &add_after_method_modifier         
625          - &add_around_method_modifier
626              - added tests and docs for these
627       - added &find_next_method_by_name which finds the 
628         equivalent of SUPER::method_name
629
630 0.12 Thurs. Feb 23, 2006
631     - reduced the dependency on B, no need to always 
632       have the latest
633
634     * examples/
635       - added docs to the C3 method dispatch order test
636       - fixed missing Algorithm::C3 dependency by making 
637         the test skip if it is not installed
638
639 0.11 Mon Feb. 20, 2006
640     * examples/
641       - added example of changing method dispatch order to C3
642       
643     * Class::MOP::Class
644       - changed how clone_instance behaves, it now only does a
645         shallow clone (see docs for more details)
646         - added docs and tests
647
648 0.10 Tues Feb. 14, 2006
649     ** This release was mostly about writing more tests and 
650        cleaning out old and dusty code, the MOP should now 
651        be considered "ready to use".
652
653     - adding more tests to get coverage up a little higher,
654       mostly testing errors and edge cases.
655       - test coverage is now at 99%
656       
657     * Class::MOP
658       - no longer optionally exports to UNIVERSAL::meta or
659         creates a custom metaclass generator, use the 
660         metaclass pragma instead.
661
662     * Class::MOP::Class  
663       - fixed a number of minor issues which came up in the 
664         error/edge-case tests
665         
666     * Class::MOP::Attribute 
667       - fixed a number of minor issues which came up in the 
668         error/edge-case tests        
669      
670     * examples/
671       - fixing the AttributesWithHistory example, it was broken.
672
673 0.06 Thurs Feb. 9, 2006
674     * metaclass
675       - adding new metaclass pragma to make setting up the 
676         metaclass a little more straightforward
677         
678     * Class::MOP
679       - clean up bootstrapping to include more complete 
680         attribute definitions for Class::MOP::Class and 
681         Class::MOP::Attribute (accessors, readers, writers, 
682         etc.) ... it is redundant, but is useful meta-info
683         to have around.
684
685     * Class::MOP::Class
686       - fixing minor meta-circularity issue with &meta, it 
687         is now more useful for subclasses
688       - added &get_attribute_map as an accessor for the 
689         hash of attribute meta objects
690       - &compute_all_applicable_attributes now just returns
691         the attribute meta-object, rather than the HASH ref
692         since all the same info can be gotten from the 
693         attribute meta-object itself
694           - updated docs & tests to reflect
695       - added &clone_instance method which does a deep clone
696         of the instance structure created by &construct_instance
697           - added docs & tests for this
698           - added Clone as a dependency
699       - added &new_object and &clone_object convience methods to
700         return blessed new or cloned instances
701           - they handle Class::MOP::Class singletons correctly too
702           - added docs & tests for this
703       - cleaned up the &constuct_class_instance so that it behaves
704         more like &construct_instance (and managed the singletons too)
705       - added the &check_metaclass_compatibility method to make sure
706         that metaclasses are upward and downward compatible.
707           - added tests and docs for this
708           
709     * examples/
710       - adjusting code to use the &Class::MOP::Class::meta
711         fix detailed above
712       - adjusting code to use the metaclass pragma
713       
714 0.05 Sat Feb. 4, 2006
715     * Class::MOP::Class
716       - added the &attribute_metaclass and &method_metaclass
717         attributes which contain a metaclass name to use for 
718         attributes/methods respectively
719     
720     * Class::MOP
721       - bootstrap additional attributes for Class::MOP::Class 
722         
723     * examples/
724       - adjusted the example code and tests to use the new
725         &attribute_metaclass feature of Class::MOP::Class
726       - added new example:
727         - LazyClass
728
729 0.04 Fri Feb. 3, 2006
730     * Class::MOP::Class
731       - some documentation suggestions from #perl6
732     
733     * Class::MOP::Attribute
734       - improved error messages    
735     
736     * examples/
737       - added new examples:
738         - AttributesWithHistory
739         - ClassEncapsultedAttributes
740
741 0.03 Fri Feb. 3, 2006
742     - converted to Module::Build instead of EU::MM
743     
744     * Class::MOP::Attribute
745       - refactored method generation code
746       - attributes are now associated with class directly
747     
748     * examples/
749       - refactored the InsideOut example to take advantage 
750         of the Class::MOP::Attribute refactoring
751       - changed example files to .pod files and hide thier
752         package names from PAUSE (I don't want to own these
753         namespaces really, they are just examples)
754
755 0.02 Thurs Feb. 2, 2006
756     - moving examples from t/lib/* to examples/*
757         - adding POD documentation to the examples
758
759 0.01 Thurs Feb. 2, 2006
760     - Initial release