merge meta-role-helper branch and update changes
[gitmo/Moose.git] / Changes
CommitLineData
e522431d 1Revision history for Perl extension Moose
2
6ae2afc2 30.55_04 Sat August 30, 2008
3f567f44 4 * Moose::Util::MetaRole
6ae2afc2 5 * Moose::Cookbook::Extending::Recipe2
3f567f44 6 - This simplifies the application of roles to any meta class, as
7 well as the base object class. Reimplemented metaclass traits
8 using this module. (Dave Rolsky)
9
6ae2afc2 10 * Moose::Cookbook::Extending::Recipe1
11 - This a new recipe, an overview of various ways to write Moose
12 extensions (Dave Rolsky)
13
14 * Moose::Cookbook::Extending::Recipe3
15 * Moose::Cookbook::Extending::Recipe4
16 - These used to be Extending::Recipe1 and Extending::Recipe2,
17 respectively.
18
975411b2 190.55_03 Fri August 29, 2008
20 * No changes from 0.55_02 except increasing the Class::MOP
21 dependency to 0.64_07.
22
23045c64 230.55_02 Fri August 29, 2008
c068e9a0 24 * Makefile.PL and Moose.pm
25 - explicitly require Perl 5.8.0+ (Dave Rolsky)
26
9758af8a 27 * Moose::Util::TypeConstraints
28 - Fix warnings from find_type_constraint if the type is not
29 found (t0m).
30
31 * Moose::Meta::TypeConstraint
23045c64 32 - Predicate methods (equals/is_a_type_of/is_subtype_of) now
9758af8a 33 return false if the type you specify cannot be found in the
23045c64 34 type registry, rather than throwing an unhelpful and
35 coincidental exception. (t0m).
9758af8a 36 - added docs & test for this (t0m)
37
38 * Moose::Meta::TypeConstraint::Registry
39 - add_type_constraint now throws an exception if a parameter is
40 not supplied (t0m).
41 - added docs & test for this (t0m)
23045c64 42
43 * Moose::Cookbook::FAQ
44 - Added a faq entry on the difference between "role" and "trait"
45 (t0m)
46
47 * Moose::Meta::Role
48 - Fixed a bug that caused role composition to not see a required
49 method when that method was provided by another role being
50 composed at the same time. (Dave Rolsky)
51 - test and bug finding (tokuhirom)
9758af8a 52
0d87d86c 530.55_01 Wed August 20, 2008
b3a7e860 54
55 !! Calling Moose::init_meta as a function is now !!
56 !! deprecated. Please see the Moose.pm docs for details. !!
57
c7a43a7a 58 * Moose::Meta::Method::Constructor
59 - Fix inlined constructor so that values produced by default
b3a7e860 60 or builder methods are coerced as required. (t0m)
61 - added test for this (t0m)
c7a43a7a 62
f92cd300 63 * Moose::Meta::Attribute
b3a7e860 64 - A lazy attribute with a default or builder did not attempt to
65 coerce the default value. The immutable code _did_
66 coerce. (t0m)
67 - added test for this (t0m)
f92cd300 68
5e6c2b88 69 * Moose::Exporter
70 - This is a new helper module for writing "Moose-alike"
71 modules. This should make the lives of MooseX module authors
72 much easier. (Dave Rolsky)
73
ce265cc3 74 * Moose
d190db8b 75 * Moose::Cookbook::Meta::Recipe5
76 - Implemented metaclass traits (and wrote a recipe for it):
d5c18ef0 77
78 use Moose -traits => 'Foo'
79
80 This should make writing small Moose extensions a little
81 easier (Dave Rolsky)
82
b3a7e860 83 * Moose::Cookbook::Basics::Recipe1
84 - Removed any examples of direct hashref access, and applied an
85 editorial axe to reduce verbosity. (Dave Rolsky)
86
87 * Moose::Cookbook::Basics::Recipe1
88 - Also applied an editorial axe here. (Dave Rolsky)
89
d5c18ef0 90 * Moose
3e1e774e 91 * Moose::Cookbook::Extending::Recipe1
ce265cc3 92 * Moose::Cookbook::Extending::Recipe2
3e1e774e 93 - Rewrote extending and embedding moose documentation and
94 recipes to use Moose::Exporter (Dave Rolsky)
95
7ff56534 96 * Moose
3e1e774e 97 * Moose::Role
98 - These two modules now warn when you load them from the main
99 package "main" package, because we will not export sugar to
100 main. Previously it just did nothing. (Dave Rolsky)
7ff56534 101
b3a7e860 102 * Moose::Role
103 - Now provide an init_meta method just like Moose.pm, and you
104 can call this to provide an alternate role metaclass. (Dave
105 Rolsky and nothingmuch)
4f136178 106 - get_method_map now respects the package cache flag (nothingmuch)
b3a7e860 107
108 * Moose::Meta::Role
109 - Two new methods - add_method and wrap_method_body
110 (nothingmuch)
111
112 * many modules
113 - Optimizations including allowing constructors to accept hash
114 refs, making many more classes immutable, and making
115 constructors immutable. (nothingmuch)
116
7e8c0685 1170.55 Sun August 3, 2008
330dbb07 118 * Moose::Meta::Attribute
7e8c0685 119 - breaking down the way 'handles' methods are
120 created so that the process can be more easily
330dbb07 121 overridden by subclasses (stevan)
122
d5598ade 123 * Moose::Meta::TypeConstraint
7e8c0685 124 - fixing what is passed into a ->message with
d5598ade 125 the type constraints (RT #37569)
126 - added tests for this (Charles Alderman)
127
470b518a 128 * Moose::Util::TypeConstraints
7e8c0685 129 - fix coerce to accept anon types like subtype can (mst)
470b518a 130
021b8139 131 * Moose::Cookbook
f254fa03 132 - reorganized the recipes into sections - Basics, Roles, Meta,
133 Extending - and wrote abstracts for each section (Dave Rolsky)
134
135 * Moose::Cookbook::Basics::Recipe10
136 - A new recipe that demonstrates operator overloading
137 in combination with Moose. (bluefeet)
021b8139 138
7c36d1d5 139 * Moose::Cookbook::Meta::Recipe1
140 - an introduction to what meta is and why you'd want to make
141 your own metaclass extensions (Dave Rolsky)
142
f254fa03 143 * Moose::Cookbook::Meta::Recipe4
144 - a very simple metaclass example (Dave Rolsky)
145
d5e84b86 146 * Moose::Cookbook::Extending::Recipe1
147 - how to write a Moose-alike module to use your own object base
148 class (Dave Rolsky)
149
f254fa03 150 * Moose::Cookbook::Extending::Recipe2
151 - how to write modules with an API just like C<Moose.pm> (Dave
152 Rolsky)
c2a0627f 153
7e8c0685 154 * all documentation
155 - Tons of fixes, both syntactical and grammatical (Dave
156 Rolsky, Paul Fenwick)
157
713b0244 1580.54 Thurs. July 3, 2008
159 ... this is not my day today ...
160
161 * Moose::Meta::Attribute
162 - fixed legal_options_for_inheritance such that
163 clone_and_inherit options still works for
164 Class::MOP::Attribute objects and therefore
165 does not break MooseX::AttributeHelpers
166 (stevan)
93cc8330 167
6d20aa6d 1680.53 Thurs. July 3, 2008
169 * Whoops, I guess I should run 'make manifest' before
170 actually releasing the module. No actual changes
171 in this release, except the fact that it includes
172 the changes that I didn't include in the last
173 release. (stevan--)
03e7dbec 174
68b6146c 1750.52 Thurs. July 3, 2008
47b19570 176 * Moose
177 - added "FEATURE REQUESTS" section to the Moose docs
977a86ba 178 to properly direct people (stevan) (RT #34333)
179 - making 'extends' croak if it is passed a Role since
180 this is not ever something you want to do
181 (fixed by stevan, found by obra)
182 - added tests for this (stevan)
19fabdd3 183
68b6146c 184 * Moose::Object
185 - adding support for DOES (as in UNIVERSAL::DOES)
186 (nothingmuch)
187 - added test for this
188
189 * Moose::Meta::Attribute
190 - added legal_options_for_inheritance (wreis)
191 - added tests for this (wreis)
192
193 * Moose::Cookbook::Snacks::*
194 - removed some of the unfinished snacks that should
195 not have been released yet. Added some more examples
196 to the 'Keywords' snack. (stevan)
197
47b19570 198 * Moose::Cookbook::Style
199 - added general Moose "style guide" of sorts to the
200 cookbook (nothingmuch) (RT #34335)
19fabdd3 201
977a86ba 202 * t/
203 - added more BUILDARGS tests (stevan)
204
07b0f1a5 2050.51 Thurs. Jun 26, 2008
d31f9614 206 * Moose::Role
0db4f1d7 207 - add unimport so "no Moose::Role" actually does
208 something (sartak)
209
db9476b1 210 * Moose::Meta::Role::Application::ToRole
211 - when RoleA did RoleB, and RoleA aliased a method from RoleB in
212 order to provide its own implementation, that method still got
213 added to the list of required methods for consumers of
214 RoleB. Now an aliased method is only added to the list of
215 required methods if the role doing the aliasing does not
216 provide its own implementation. See Recipe 11 for an example
6164d955 217 of all this. (Dave Rolsky)
db9476b1 218 - added tests for this
0db4f1d7 219
93e98578 220 * Moose::Meta::Method::Constructor
221 - when a single argument that wasn't a hashref was provided to
222 an immutabilized constructor, the error message was very
223 unhelpful, as opposed to the non-immutable error. Reported by
6164d955 224 dew. (Dave Rolsky)
225 - added test for this (Dave Rolsky)
d31f9614 226
0db4f1d7 227 * Moose::Meta::Attribute
228 - added support for meta_attr->does("ShortAlias") (sartak)
229 - added tests for this (sartak)
17ee2ee0 230 - moved the bulk of the `handles` handling to the new
d3e7fe85 231 install_delegation method (Stevan)
0db4f1d7 232
233 * Moose::Object
210caeb6 234 - Added BUILDARGS, a new step in new()
235
0206f6d6 236 * Moose::Meta::Role::Application::RoleSummation
237 - fix typos no one ever sees (sartak)
0db4f1d7 238
17ee2ee0 239 * Moose::Util::TypeConstraints
240 * Moose::Meta::TypeConstraint
241 * Moose::Meta::TypeCoercion
242 - Attempt to work around the ??{ } vs. threads issue
47b19570 243 (not yet fixed)
17ee2ee0 244 - Some null_constraint optimizations
245
eaa35e6e 2460.50 Thurs. Jun 11, 2008
247 - Fixed a version number issue by bumping all modules
248 to 0.50.
249
4cf89c74 2500.49 Thurs. Jun 11, 2008
eaa35e6e 251 !! This version now approx. 20-25% !!
252 !! faster with new Class::MOP 0.59 !!
253
21f1e231 254 * Moose::Meta::Attribute
255 - fixed how the is => (ro|rw) works with
256 custom defined reader, writer and accessor
257 options.
258 - added docs for this (TODO).
259 - added tests for this (Thanks to Penfold)
260 - added the custom attribute alias for regular
261 Moose attributes which is "Moose"
09b8cb41 262 - fix builder and default both being used
263 (groditi)
21f1e231 264
265 * Moose
266 Moose::Meta::Class
267 Moose::Meta::Attribute
268 Moose::Meta::Role
269 Moose::Meta::Role::Composite
270 Moose::Util::TypeConstraints
f93f7be9 271 - switched usage of reftype to ref because
272 it is much faster
273
8371f6e1 274 * Moose::Meta::Role
275 - changing add_package_symbol to use the new
276 HASH ref form
277
f93f7be9 278 * Moose::Object
279 - fixed how DEMOLISHALL is called so that it
280 can be overrided in subclasses (thanks to Sartak)
281 - added test for this (thanks to Sartak)
21f1e231 282
e151db23 283 * Moose::Util::TypeConstraints
284 - move the ClassName type check code to
285 Class::MOP::is_class_loaded (thanks to Sartak)
286
09b8cb41 287 * Moose::Cookbook::Recipe11
288 - add tests for this (thanks to tokuhirom)
289
695d1c68 2900.48 Thurs. May 29, 2008
291 (early morning release engineering)--
292
293 - fixing the version in Moose::Meta::Method::Destructor
294 which was causing the indexer to choke
295
2391ba89 2960.47 Thurs. May 29, 2008
297 (late night release engineering)--
298
299 - fixing the version is META.yml, no functional
300 changes in this release
301
bd364604 3020.46 Wed. May 28, 2008
303 !! This version now approx. 20-25% !!
304 !! faster with new Class::MOP 0.57 !!
305
306 * Moose::Meta::Class
307 - some optimizations of the &initialize method
308 since it is called so often by &meta
309
0addec44 310 * Moose::Meta::Class
311 Moose::Meta::Role
312 - now use the get_all_package_symbols from the
313 updated Class::MOP, test suite is now 10 seconds
314 faster
d3308256 315
316 * Moose::Meta::Method::Destructor
bd364604 317 - is_needed can now also be called as a class
318 method for immutablization to check if the
319 destructor object even needs to be created
320 at all
321
322 * Moose::Meta::Method::Destructor
d3308256 323 Moose::Meta::Method::Constructor
324 - added more descriptive error message to help
325 keep people from wasting time tracking an error
326 that is easily fixed by upgrading.
0addec44 327
c998012c 3280.45 Saturday, May 24, 2008
1b2aea39 329 * Moose
330 - Because of work in Class::MOP 0.56, all
331 XS based functionality is now optional
332 and a Pure Perl version is supplied
333 - the CLASS_MOP_NO_XS environment variable
334 can now be used to force non-XS versions
335 to always be used
336 - several of the packages have been tweaked
337 to take care of this, mostly we added
338 support for the package_name and name
339 variables in all the Method metaclasses
408f2665 340 - before/around/after method modifiers now
341 support regexp matching of names
342 (thanks to Takatoshi Kitano)
343 - tests added for this
088f372b 344 - NOTE: this only works for classes, it
345 is currently not supported in roles,
346 but, ... patches welcome
b8926b8c 347 - All usage of Carp::confess have been replaced
348 by Carp::croak in the "keyword" functions since
349 the stack trace is usually not helpful
350
351 * Moose::Role
352 - All usage of Carp::confess have been replaced
353 by Carp::croak in the "keyword" functions since
354 the stack trace is usually not helpful
355 - The 'has' keyword for roles now accepts the
356 same array ref form that Moose.pm does
357 (has [qw/foo bar/] => (is => 'rw', ...))
358 - added test for this
359
0b7df53c 360 * Moose::Meta::Attribute
361 - trigger on a ro-attribute is no longer an
362 error, as it's useful to trigger off of the
363 constructor
364
8453c358 365 * Moose::Meta::Class
366 - added same 'add_package_symbol' fix as in
367 Class::MOP 0.56
368
369 * Moose::Util
370 - does_role now handles non-Moose classes
371 more gracefully
372 - added tests for this
408f2665 373 - added the 'add_method_modifier' function
374 (thanks to Takatoshi Kitano)
8453c358 375
a84a89ba 376 * Moose::Util::TypeConstraints
377 - subtypes of parameterizable types now are
378 themselves parameterizable types
379
1b55c340 380 * Moose::Meta::Method::Constructor
381 - fixed bug where trigger was not being
382 called by the inlined immutable
383 constructors
384 - added test for this (thanks to Caelum)
385
386 * Moose::Meta::Role::Application::ToInstance
387 - now uses the metaclass of the instance
388 (if possible) to create the anon-class
389 (thanks Jonathan Rockway)
390
b8926b8c 391 * Moose::Cookbook::Recipe22
392 - added the meta-attribute trait recipe
393 (thanks to Sartak)
394
1b55c340 395 * t/
396 - fixed hash-ordering test bug that was
b8926b8c 397 causing occasional cpantester failures
398 - renamed the t/000_recipe/*.t tests to be
399 more descriptive (thanks to Sartak)
1b55c340 400
3a0c064a 4010.44 Sat. May 10, 2008
c0b37457 402 * Moose
3a0c064a 403 - made make_immutable warning cluck to
ca0e380d 404 show where the error is (thanks mst)
3a0c064a 405
406 * Moose::Object
407 - BUILDALL and DEMOLISHALL now call
408 ->body when looping through the
409 methods, to avoid the overloaded
410 method call.
ca0e380d 411 - fixed issue where DEMOLISHALL was
412 eating the $@ values, and so not
413 working correctly, it still kind of
414 eats them, but so does vanilla perl
415 - added tests for this
3a0c064a 416
ceb8945d 417 * Moose::Cookbook::Recipe7
3a0c064a 418 - added new recipe for immutable
419 functionality (thanks Dave Rolsky)
420
ceb8945d 421 * Moose::Cookbook::Recipe9
3a0c064a 422 - added new recipe for builder and
423 lazy_build (thanks Dave Rolsky)
424
37332f31 425 * Moose::Cookbook::Recipe11
3a0c064a 426 - added new recipe for method aliasing
427 and exclusion with Roles (thanks Dave Rolsky)
428
429 * t/
ca0e380d 430 - fixed Win32 test failure (thanks spicyjack)
ceb8945d 431
1a28289d 432 ~ removed Build.PL and Module::Build compat
433 since Module::Install has done that.
434
27cabcda 4350.43 Wed. April, 30, 2008
cbd141ca 436 * NOTE TO SELF:
437 drink more coffee before
438 doing release engineering
439
440 - whoops, forgot to do the smolder tests,
441 and we broke some of the custom meta-attr
442 modules. This fixes that.
443
c93e8e7d 4440.42 Mon. April 28, 2008
445 - some bad tests slipped by, nothing else
446 changed in this release (cpantesters++)
447
448 - upped the Class::MOP dependency to 0.55
449 since we have tests which need the C3
450 support
451
a5e883ae 4520.41 Mon. April 28, 2008
004222dc 453 ~~ numerous documentation updates ~~
547dda77 454
455 - Changed all usage of die to Carp::croak for better
456 error reporting (initial patch by Tod Hagan)
004222dc 457
c2922d69 458 ** IMPORTANT NOTE **
459 - the make_immutable keyword is now deprecated, don't
460 use it in any new code and please fix your old code
461 as well. There will be 2 releases, and then it will
462 be removed.
463
6c36eeaa 464 * Moose
465 Moose::Role
466 Moose::Meta::Class
467 - refactored the way inner and super work to avoid
468 any method/@ISA cache penalty (nothingmuch)
469
4078709c 470 * Moose::Meta::Class
471 - fixing &new_object to make sure trigger gets the
472 coerced value (spotted by Charles Alderman on the
473 mailing list)
474 - added test for this
475
51c107ef 476 * Moose::Meta::Method::Constructor
477 - immutable classes which had non-lazy attributes were calling
478 the default generating sub twice in the constructor. (bug
479 found by Jesse Luehrs, fixed by Dave Rolsky)
480 - added tests for this (Dave Rolsky)
ae8d63f2 481 - fix typo in initialize_body method (nothingmuch)
482
483 * Moose::Meta::Method::Destructor
484 - fix typo in initialize_body method (nothingmuch)
51c107ef 485
6c36eeaa 486 * Moose::Meta::Method::Overriden
487 Moose::Meta::Method::Augmented
488 - moved the logic for these into their own
489 classes (nothingmuch)
490
5e98d2b6 491 * Moose::Meta::Attribute
aed87761 492 - inherited attributes may now be extended without
2ea379cb 493 restriction on the type ('isa', 'does') (Sartak)
cf12a691 494 - added tests for this (Sartak)
547dda77 495 - when an attribute property is malformed (such as lazy without
496 a default), give the name of the attribute in the error
497 message (Sartak)
88f23977 498 - added the &applied_traits and &has_applied_traits methods
499 to allow introspection of traits
500 - added tests for this
37905a64 501 - moved 'trait' and 'metaclass' argument handling to here from
502 Moose::Meta::Class
503 - clone_and_inherit_options now handles 'trait' and 'metaclass' (has
504 '+foo' syntax) (nothingmuch)
505 - added tests for this (t0m)
7c60f730 506
507 * Moose::Object
508 - localize $@ inside DEMOLISHALL to avoid it
509 eating $@ (found by Ernesto)
510 - added test for this (thanks to Ernesto)
cf12a691 511
ae8d63f2 512 * Moose::Util::TypeConstraints
513 - &find_type_constraint now DWIMs when given an
6c36eeaa 514 type constraint object or name (nothingmuch)
37905a64 515 - &find_or_create_type_constraint superseded with a number of more
516 specific functions:
517 - find_or_create_{isa,does}_type_constraint
518 - find_or_parse_type_constraint
ae8d63f2 519
520 * Moose::Meta::TypeConstraint
4078709c 521 Moose::Meta::TypeConstraint::Class
37905a64 522 Moose::Meta::TypeConstraint::Role
4078709c 523 Moose::Meta::TypeConstraint::Enum
524 Moose::Meta::TypeConstraint::Union
525 Moose::Meta::TypeConstraint::Parameterized
526 - added the &equals method for comparing two type
527 constraints (nothingmuch)
528 - added tests for this (nothingmuch)
529
530 * Moose::Meta::TypeConstraint
ae8d63f2 531 - add the &parents method, which is just an alias to &parent.
37905a64 532 Useful for polymorphism with TC::{Class,Role,Union} (nothingmuch)
ae8d63f2 533
534 * Moose::Meta::TypeConstraint::Class
ae8d63f2 535 - added the class attribute for introspection purposes
536 (nothingmuch)
537 - added tests for this
4078709c 538
539 * Moose::Meta::TypeConstraint::Enum
6c36eeaa 540 Moose::Meta::TypeConstraint::Role
37905a64 541 - broke these out into their own classes (nothingmuch)
ae8d63f2 542
543 * Moose::Cookbook::Recipe*
544 - fixed references to test file locations in the POD
545 and updated up some text for new Moose features
37905a64 546 (Sartak)
547
548 * Moose::Util
549 - Added &resolve_metaclass_alias, a helper function for finding an actual
550 class for a short name (e.g. in the traits list)
ae8d63f2 551
52338af5 5520.40 Fri. March 14, 2008
6e2840b7 553 - I hate Pod::Coverage
554
e0328ed4 5550.39 Fri. March 14, 2008
8d62bf6d 556 * Moose
557 - documenting the use of '+name' with attributes
558 that come from recently composed roles. It makes
559 sense, people are using it, and so why not just
560 officially support it.
9c10b5ad 561 - fixing the 'extends' keyword so that it will not
562 trigger Ovid's bug (http://use.perl.org/~Ovid/journal/35763)
94075501 563
1321f087 564 * oose
565 - added the perl -Moose=+Class::Name feature to allow
566 monkeypatching of classes in one liners
567
9c10b5ad 568 * Moose::Util
569 - fixing the 'apply_all_roles' keyword so that it will not
570 trigger Ovid's bug (http://use.perl.org/~Ovid/journal/35763)
8d62bf6d 571
48045612 572 * Moose::Meta::Class
573 - added ->create method which now supports roles (thanks to jrockway)
574 - added tests for this
6d5cbd2b 575 - added ->create_anon_class which now supports roles and caching of
576 the results (thanks to jrockway)
577 - added tests for this
81c3738f 578 - made ->does_role a little more forgiving when it is
579 checking a Class::MOP era metaclasses.
48045612 580
94075501 581 * Moose::Meta::Role::Application::ToInstance
582 - it is now possible to pass extra params to be used when
583 a role is applied to an the instance (rebless_params)
584 - added tests for this
585
9f4334a1 586 * Moose::Util::TypeConstraints
4ab662d6 587 - class_type now accepts an optional second argument for a
588 custom message. POD anotated accordingly (groditi)
589 - added tests for this
9f4334a1 590 - it is now possible to make anon-enums by passing 'enum' an
591 ARRAY ref instead of the $name => @values. Everything else
592 works as before.
593 - added tests for this
594
8d62bf6d 595 * t/
596 - making test for using '+name' on attributes consumed
597 from a role, it works and makes sense too.
598
80d955e4 599 * Moose::Meta::Attribute
600 - fix handles so that it doesn't return nothing
601 when the method cannot be found, not sure why
f4f3e701 602 it ever did this originally, this means we now
603 have slightly better support for AUTOLOADed
604 objects
605 - added more delegation tests
587e457d 606 - adding ->does method to this so as to better
607 support traits and their introspection.
608 - added tests for this
1a386a6c 609
610 * Moose::Object
611 - localizing the Data::Dumper configurations so
612 that it does not pollute others (RT #33509)
9b1aa0c3 613 - made ->does a little more forgiving when it is
614 passed Class::MOP era metaclasses.
80d955e4 615
6160.38 Fri. Feb. 15, 2008
c3b81505 617 * Moose::Meta::Attribute
618 - fixed initializer to correctly do
619 type checking and coercion in the
620 callback
621 - added tests for this
622
1a740d8a 623 * t/
624 - fixed some finicky tests (thanks to konobi)
625
80d955e4 6260.37 Thurs. Feb. 14, 2008
688fcdda 627 * Moose
628 - fixed some details in Moose::init_meta
629 and its superclass handling (thanks thepler)
630 - added tests for this (thanks thepler)
a28fe77b 631 - 'has' now dies if you don't pass in name
632 value pairs
2a5e59d0 633 - added the 'make_immutable' keyword as a shortcut
9df136d0 634 to make_immutable
688fcdda 635
636 * Moose::Meta::Class
637 Moose::Meta::Method::Constructor
638 Moose::Meta::Attribute
649b9340 639 - making (init_arg => undef) work here too
640 (thanks to nothingmuch)
be771c43 641
642 * Moose::Meta::Attribute
643 Moose::Meta::Method::Constructor
644 Moose::Meta::Method::Accessor
5fec9b97 645 - make lazy attributes respect attr initializers (rjbs)
be771c43 646 - added tests for this
688fcdda 647
648 * Moose::Util::TypeConstraints
649 Moose::Util::TypeConstraints::OptimizedConstraints
c14746bc 650 Moose::Meta::TypeConstraints
688fcdda 651 Moose::Meta::Attribute
652 Moose::Meta::Method::Constructor
653 Moose::Meta::Method::Accessor
649b9340 654 - making type errors use the
655 assigned message (thanks to Sartak)
656 - added tests for this
657
658 * Moose::Meta::Method::Destructor
659 - making sure DESTROY gets inlined properly
660 with successive DEMOLISH calls (thanks to manito)
688fcdda 661
ab76842e 662 * Moose::Meta::Attribute
663 Moose::Meta::Method::Accessor
664 - fixed handling of undef with type constraints
665 (thanks to Ernesto)
666 - added tests for this
c14746bc 667
668 * Moose::Util
669 - added &get_all_init_args and &get_all_attribute_values
670 (thanks to Sartak and nothingmuch)
ab76842e 671
e472c9a5 6720.36 Sat. Jan. 26, 2008
238b424d 673 * Moose::Role
674 Moose::Meta::Attribute
675 - role type tests now support when roles are
676 applied to non-Moose classes (found by ash)
677 - added tests for this (thanks to ash)
e472c9a5 678 - couple extra tests to boost code coverage
238b424d 679
680 * Moose::Meta::Method::Constructor
681 - improved fix for handling Class::MOP attributes
682 - added test for this
683
684 * Moose::Meta::Class
685 - handled the add_attribute($attribute_meta_object)
686 case correctly
687 - added test for this
688
3285fae9 6890.35 Tues. Jan. 22, 2008
45fd4af3 690 * Moose::Meta::Method::Constructor
691 - fix to make sure even Class::MOP attributes
472b7401 692 are handled correctly (Thanks to Dave Rolsky)
c3b35392 693 - added test for this (also Dave Rolsky)
4498537c 694
695 * Moose::Meta::Class
696 - improved error message on _apply_all_roles,
697 you should now use Moose::Util::apply_all_roles
698 and you shouldnt have been using a _ prefixed
699 method in the first place ;)
45fd4af3 700
fe05ce9c 7010.34 Mon. Jan. 21, 2008
778db3ac 702 ~~~ more misc. doc. fixes ~~~
703 ~~ updated copyright dates ~~
9b28d20b 704
705 Moose is now a postmodern object system :)
8bdc7f13 706 - (see the POD for details)
ccf49e80 707
708 * <<Role System Refactoring>>
709 - this release contains a major reworking and
710 cleanup of the role system
9b28d20b 711 - 100% backwards compat.
712 - Role application now restructured into seperate
713 classes based on type of applicants
714 - Role summation (combining of more than one role)
ccf49e80 715 is much cleaner and anon-classes are no longer
9b28d20b 716 used in this process
ccf49e80 717 - new Composite role metaclass
9b28d20b 718 - runtime application of roles to instances
719 is now more efficient and re-uses generated
720 classes when applicable
ccf49e80 721
9b28d20b 722 * <<New Role composition features>>
ccf49e80 723 - methods can now be excluded from a given role
9b28d20b 724 during composition
ccf49e80 725 - methods can now be aliased to another name (and
726 still retain the original as well)
4734114b 727
728 * Moose::Util::TypeConstraints::OptimizedConstraints
729 - added this module (see above)
730
d7d8a8c7 731 * Moose::Meta::Class
732 - fixed the &_process_attribute method to be called
4734114b 733 by &add_attribute, so that the API is now correct
734
e7c06c1e 735 * Moose::Meta::Method::Accessor
4734114b 736 - fixed bug when passing a list of values to
e7c06c1e 737 an accessor would get (incorrectly) ignored.
738 Thanks to Sartak for finding this ;)
739 - added tests for this (Sartak again)
32dd4a95 740
a4e516f6 741 * Moose::Meta::Method::Accessor
742 Moose::Meta::Method::Constructor
28412c0b 743 Moose::Meta::Attribute
ccf49e80 744 Moose::Meta::TypeConstraint
745 Moose::Meta::TypeCoercion
746 - lots of cleanup of such things as:
28412c0b 747 - generated methods
748 - type constraint handling
ccf49e80 749 - error handling/messages
750 (thanks to nothingmuch)
a4e516f6 751
4734114b 752 * Moose::Meta::TypeConstraint::Parameterizable
753 - added this module to support the refactor
754 in Moose::Meta::TypeConstraint::Parameterized
755
756 * Moose::Meta::TypeConstraint::Parameterized
757 - refactored how these types are handled so they
758 are more generic and not confined to ArrayRef
759 and HashRef only
a4e516f6 760
2de7e794 761 * t/
762 - shortened some file names for better VMS support (RT #32381)
763
25374f01 7640.33 Fri. Dec. 14, 2007
32dd4a95 765 !! Moose now loads 2 x faster !!
766 !! with new Class::MOP 0.49 !!
25374f01 767
f7865ec8 768 ++ new oose.pm module to make command line
25374f01 769 Moose-ness easier (see POD docs for more)
4734114b 770
25374f01 771 * Moose::Meta::Class
772 * Moose::Meta::Role
4734114b 773 - several tweaks to take advantage of the
25374f01 774 new method map caching in Class::MOP
775
39aba5c9 776 * Moose::Meta::TypeConstraint::Parameterized
777 - allow subtypes of ArrayRef and HashRef to
acb8a5db 778 be used as a container (sartak)
4734114b 779 - added tests for this
acb8a5db 780 - basic support for coercion to ArrayRef and
781 HashRef for containers (sartak)
4734114b 782 - added tests for this
783
25374f01 784 * Moose::Meta::TypeCoercion
785 - coercions will now create subtypes as needed
786 so you can now add coercions to parameterized
787 types without having to explictly define them
788 - added tests for this
789
ac211120 790 * Moose::Meta::Method::Accessor
791 - allow subclasses to decide whether we need
792 to copy the value into a new variable (sartak)
39aba5c9 793
dc26a424 7940.32 Tues. Dec. 4, 2007
8de73ff1 795 * Moose::Util::TypeConstraints
796 - fixing how subtype aliases of unions work
797 they should inherit the parent's coercion
798 - added tests for this
4734114b 799 - you can now define multiple coercions on
41e007e4 800 a single type at different times instead of
801 having to do it all in one place
802 - added tests for this
4734114b 803
8de73ff1 804 * Moose::Meta::TypeConstraint
805 - there is now a default constraint of sub { 1 }
806 instead of Moose::Util::TypeConstraints setting
807 this for us
808
4734114b 809 * Moose::Meta::TypeCoercion
810 * Moose::Meta::TypeCoercion::Union
811 - added the &has_coercion_for_type and
812 &add_type_coercions methods to support the
41e007e4 813 new features above (although you cannot add
814 more type coercions for Union types)
815
ffcb48b4 8160.31 Mon. Nov. 26, 2007
f3c4e20e 817 * Moose::Meta::Attribute
4734114b 818 - made the +attr syntax handle extending types with
f3c4e20e 819 parameters. So "has '+foo' => (isa => 'ArrayRef[Int]')"
820 now works if the original foo is an ArrayRef.
821 - added tests for this.
822 - delegation now works even if the attribute does not
823 have a reader method using the get_read_method_ref
4734114b 824 method from Class::MOP::Attribute.
f3c4e20e 825 - added tests for this
826 - added docs for this
4734114b 827
f3c4e20e 828 * Moose::Util::TypeConstraints
4734114b 829 - passing no "additional attribute info" to
830 &find_or_create_type_constraint will no longer
831 attempt to create an __ANON__ type for you,
f3c4e20e 832 instead it will just return undef.
833 - added docs for this
834
1edfdf1c 8350.30 Fri. Nov. 23, 2007
ca168e89 836 * Moose::Meta::Method::Constructor
837 -builder related bug in inlined constructor. (groditi)
838
3822d5ee 839 * Moose::Meta::Method::Accessor
840 - genereate unnecessary calls to predicates and refactor
841 code generation for runtime speed (groditi)
842
5d776bdf 843 * Moose::Util::TypeConstraints
0e0709ea 844 - fix ClassName constraint to introspect symbol table (mst)
a0f8153d 845 - added more tests for this (mst)
846 - fixed it so that subtype 'Foo' => as 'HashRef[Int]' ...
847 with work correctly.
848 - added tests for this
5d776bdf 849
1edfdf1c 850 * Moose::Cookbook
851 - adding the link to Recipie 11 (written by Sartak)
852 - adding test for SYNOPSIS code
853
4734114b 854 * t/
ca168e89 855 - New tests for builder bug. Upon instantiation, if an
856 attribute had a builder, no value and was not lazy the
857 builder default was not getting run, oops. (groditi)
858
b97b9655 8590.29 Tues. Nov. 13, 2007
0b26305c 860 * Moose::Meta::Attribute
5d776bdf 861 - Fix error message on missing builder method (groditi)
0b26305c 862
863 * Moose::Meta::Method::Accessor
5d776bdf 864 - Fix error message on missing builder method (groditi)
0b26305c 865
4734114b 866 * t/
5d776bdf 867 - Add test to check for the correct error message when
868 builder method is missing (groditi)
0b26305c 869
98c4c382 8700.28 Tues. Nov. 13, 2007
4734114b 871 - 0.27 packaged incorrectly (groditi)
98c4c382 872
e134cd19 8730.27 Tues. Nov. 13, 2007
26fbace8 874 * Moose::Meta::Attribute
875 - Added support for the new builder option (groditi)
6af1a927 876 - Added support for lazy_build option (groditi)
1ed0b94f 877 - Changed slot initialization for predicate changes (groditi)
26fbace8 878
879 * Moose::Meta::Method::Accessor
6af1a927 880 - Added support for lazy_build option (groditi)
4734114b 881 - Fix inline methods to work with corrected predicate
28669f89 882 behavior (groditi)
26fbace8 883
7a5b07b3 884 * Moose::Meta::Method::Constructor
885 - Added support for lazy_build option (groditi)
886
26fbace8 887 * t/
28669f89 888 - tests for builder and lazy_build (groditi)
26fbace8 889
4734114b 890 * fixing some misc. bits in the docs that
28669f89 891 got mentioned on CPAN Forum & perlmonks
4734114b 892
e7f8d0c2 893 * Moose::Meta::Role
4734114b 894 - fixed how required methods are handled
e7f8d0c2 895 when they encounter overriden or modified
896 methods from a class (thanks to confound).
897 - added tests for this
5af6a16d 898
3796382a 899 * Moose::Util::TypeConstraint
4734114b 900 - fixed the type notation parser so that
901 the | always creates a union and so is
902 no longer a valid type char (thanks to
903 konobi, mugwump and #moose for working
3796382a 904 this one out.)
905 - added more tests for this
906
77a18c28 9070.26 Thurs. Sept. 27, 2007
908 == New Features ==
4734114b 909
77a18c28 910 * Parameterized Types
4734114b 911 We now support parameterized collection types, such as:
77a18c28 912 ArrayRef[Int] # array or integers
913 HashRef[Object] # a hash with object values
914 They can also be nested:
915 ArrayRef[HashRef[RegExpr]] # an array of hashes with regexpr values
916 And work with the type unions as well:
917 ArrayRef[Int | Str] # array of integers of strings
4734114b 918
77a18c28 919 * Better Framework Extendability
4734114b 920 Moose.pm is now "extendable" such that it is now much
921 easier to extend the framework and add your own keywords
77a18c28 922 and customizations. See the "EXTENDING AND EMBEDDING MOOSE"
923 section of the Moose.pm docs.
4734114b 924
77a18c28 925 * Moose Snacks!
4734114b 926 In an effort to begin documenting some of the various
927 details of Moose as well as some common idioms, we have
928 created Moose::Cookbook::Snacks as a place to find
77a18c28 929 small (easily digestable) nuggets of Moose code.
4734114b 930
77a18c28 931 ====
fb697a87 932 ~ Several doc updates/cleanup thanks to castaway ~
4734114b 933
934 - converted build system to use Module::Install instead of
e46f5cc2 935 Module::Build (thanks to jrockway)
fb697a87 936
d67145ed 937 * Moose
4734114b 938 - added all the meta classes to the immutable list and
d67145ed 939 set it to inline the accessors
4734114b 940 - fix import to allow Sub::Exporter like { into => }
e59a5c29 941 and { into_level => } (perigrin)
4734114b 942 - exposed and documented init_meta() to allow better
e59a5c29 943 embedding and extending of Moose (perigrin)
4734114b 944
e59a5c29 945 * t/
946 - complete re-organization of the test suite
4734114b 947 - added some new tests as well
77a18c28 948 - finally re-enabled the Moose::POOP test since
949 the new version of DBM::Deep now works again
950 (thanks rob)
b468a3d3 951
952 * Moose::Meta::Class
4734114b 953 - fixed very odd and very nasty recursion bug with
b468a3d3 954 inner/augment (mst)
955 - added tests for this (eilara)
d67145ed 956
3726f905 957 * Moose::Meta::Attribute
958 Moose::Meta::Method::Constructor
959 Moose::Meta::Method::Accessor
4734114b 960 - fixed issue with overload::Overloaded getting called
f1917f58 961 on non-blessed items. (RT #29269)
3726f905 962 - added tests for this
4734114b 963
3ccdc84a 964 * Moose::Meta::Method::Accessor
4734114b 965 - fixed issue with generated accessor code making
3ccdc84a 966 assumptions about hash based classes (thanks to dexter)
4734114b 967
3726f905 968 * Moose::Coookbook::Snacks
4734114b 969 - these are bits of documentation, not quite as big as
970 Recipes but which have no clear place in the module docs.
3726f905 971 So they are Snacks! (horray for castaway++)
972
07cde929 973 * Moose::Cookbook::Recipe4
974 - updated it to use the new ArrayRef[MyType] construct
975 - updated the accompanying test as well
976
3726f905 977 +++ Major Refactor of the Type Constraint system +++
978 +++ with new features added as well +++
979
22aed3c0 980 * Moose::Util::TypeConstraint
4734114b 981 - no longer uses package variable to keep track of
22aed3c0 982 the type constraints, now uses the an instance of
983 Moose::Meta::TypeConstraint::Registry to do it
f1917f58 984 - added more sophisticated type notation parsing
985 (thanks to mugwump)
986 - added tests for this
22aed3c0 987
d67145ed 988 * Moose::Meta::TypeConstraint
989 - some minor adjustments to make subclassing easier
4734114b 990 - added the package_defined_in attribute so that we
22aed3c0 991 can track where the type constraints are created
4734114b 992
d67145ed 993 * Moose::Meta::TypeConstraint::Union
4734114b 994 - this is now been refactored to be a subclass of
3726f905 995 Moose::Meta::TypeConstraint
4734114b 996
3726f905 997 * Moose::Meta::TypeCoercion::Union
998 - this has been added to service the newly refactored
4734114b 999 Moose::Meta::TypeConstraint::Union and is itself
3726f905 1000 a subclass of Moose::Meta::TypeCoercion
4734114b 1001
0fbd4b0a 1002 * Moose::Meta::TypeConstraint::Parameterized
d67145ed 1003 - added this module (taken from MooseX::AttributeHelpers)
1004 to help construct nested collection types
1005 - added tests for this
4734114b 1006
22aed3c0 1007 * Moose::Meta::TypeConstraint::Registry
1008 - added this class to keep track of type constraints
d67145ed 1009
887169d7 10100.25 Mon. Aug. 13, 2007
8eca434b 1011 * Moose
4734114b 1012 - Documentation update to reference Moose::Util::TypeConstraints
1013 under 'isa' in 'has' for how to define a new type
8eca434b 1014 (thanks to shlomif).
1015
ab859145 1016 * Moose::Meta::Attribute
4734114b 1017 - required attributes now will no longer accept undef
ab859145 1018 from the constructor, even if there is a default and lazy
1019 - added tests for this
4734114b 1020 - default subroutines must return a value which passes the
7a5ebc40 1021 type constraint
1022 - added tests for this
4734114b 1023
a909a4df 1024 * Moose::Meta::Attribute
1025 * Moose::Meta::Method::Constructor
4734114b 1026 * Moose::Meta::Method::Accessor
a909a4df 1027 - type-constraint tests now handle overloaded objects correctly
1028 in the error message
4734114b 1029 - added tests for this (thanks to EvanCarroll)
ab859145 1030
8eca434b 1031 * Moose::Meta::TypeConstraint::Union
4734114b 1032 - added (has_)hand_optimized_constraint to this class so that
8eca434b 1033 it behaves as the regular Moose::Meta::TypeConstraint does.
1034
5868294f 1035 * Moose::Meta::Role
887169d7 1036 - large refactoring of this code
4734114b 1037 - added several more tests
1038 - tests for subtle conflict resolition issues
7125b244 1039 added, but not currently running
1040 (thanks to kolibre)
1041
4734114b 1042 * Moose::Cookbook::Recipe7
1043 - added new recipe for augment/inner functionality
887169d7 1044 (still in progress)
7125b244 1045 - added test for this
5868294f 1046
24a8fe99 1047 * Moose::Spec::Role
7125b244 1048 - a formal definition of roles (still in progress)
24a8fe99 1049
9a641848 1050 * Moose::Util
887169d7 1051 - utilities for easier working with Moose classes
7125b244 1052 - added tests for these
9a641848 1053
1054 * Test::Moose
887169d7 1055 - This contains Moose specific test functions
7125b244 1056 - added tests for these
9a641848 1057
6b4c1bdd 10580.24 Tues. July 3, 2007
1059 ~ Some doc updates/cleanup ~
c84f324f 1060
1061 * Moose::Meta::Attribute
4734114b 1062 - added support for roles to be given as parameters
c84f324f 1063 to the 'handles' option.
1064 - added tests and docs for this
4734114b 1065 - the has '+foo' attribute form now accepts changes to
83cc9094 1066 the lazy option, and the addition of a handles option
1067 (but not changing the handles option)
1068 - added tests and docs for this
c84f324f 1069
1db8ecc7 1070 * Moose::Meta::Role
1071 - required methods are now fetched using find_method_by_name
1072 so that required methods can come from superclasses
1073 - adjusted tests for this
1074
81941e9b 10750.23 Mon. June 18, 2007
73b84d2e 1076 * Moose::Meta::Method::Constructor
1077 - fix inlined constructor for hierarchy with multiple BUILD methods (mst)
ac2dc464 1078 * Moose::Meta::Class
1079 - Modify make_immutable to work with the new Class::MOP immutable
1080 mechanism + POD + very basic test (groditi)
cbe25729 1081 * Moose::Meta::Attribute
4734114b 1082 - Fix handles to use goto() so that caller() comes out properly on
cbe25729 1083 the other side (perigrin)
ac2dc464 1084
db53853c 10850.22 Thurs. May 31, 2007
3969267d 1086 * Moose::Util::TypeConstraints
4734114b 1087 - fix for prototype undeclared issue when Moose::Util::TypeConstraints
db53853c 1088 loaded before consumers (e.g. Moose::Meta::Attribute) by predeclaring
1089 prototypes for functions
4734114b 1090 - added the ClassName type constraint, this checks for strings
1091 which will respond true to ->isa(UNIVERSAL).
9af1d28b 1092 - added tests and docs for this
4734114b 1093 - subtyping just in name now works correctly by making the
86629f93 1094 default for where be { 1 }
4734114b 1095 - added test for this
3969267d 1096
d7611a4a 1097 * Moose::Meta::Method::Accessor
4734114b 1098 - coerce and lazy now work together correctly, thanks to
d7611a4a 1099 merlyn for finding this bug
1100 - tests added for this
df492bba 1101 - fix reader presedence bug in Moose::Meta::Attribute + tests
d7611a4a 1102
86629f93 1103 * Moose::Object
1104 - Foo->new(undef) now gets ignored, it is assumed you meant to pass
4734114b 1105 a HASH-ref and missed. This produces better error messages then
86629f93 1106 having it die cause undef is not a HASH.
1107 - added tests for this
1108
74a0a945 11090.21 Thursday, May 2nd, 2007
52c7c330 1110 * Moose
1111 - added SUPER_SLOT and INNER_SLOT class hashes to support unimport
1112 - modified unimport to remove super and inner along with the rest
1113 - altered unimport tests to handle this
1114
1115 * Moose::Role
1116 - altered super export to populate SUPER_SLOT
1117
1118 * Moose::Meta::Class
1119 - altered augment and override modifier application to use *_SLOT
1120 - modified tests for these to unimport one test class each to test
1121
492d4d76 1122 * Moose::Meta::Role
1123 - fixed issue where custom attribute metaclasses
1124 where not handled correctly in roles
1125 - added tests for this
4734114b 1126
5cb193ed 1127 * Moose::Meta::Class
4734114b 1128 - fixed issue where extending metaclasses with
5cb193ed 1129 roles would blow up. Thanks to Aankhen`` for
1130 finding this insidious error, and it's solution.
4734114b 1131
1132 ~~ lots of spelling and grammer fixes in the docs,
0305961b 1133 many many thanks to rlb3 and Aankhen for these :)
492d4d76 1134
e518dfb4 11350.20 Friday, April 6th, 2007
a60285b3 1136 >> I messed up the SKIP logic in one test
1137 so this release is just to fix that.
1138
93c435b3 1139 * Moose
1140 - 'has' now also accepts an ARRAY ref
1141 to create multiple attrs (see docs)
1142 (thanks to konobi for this)
4734114b 1143 - added tests and docs
93c435b3 1144
cd7eeaf5 11450.19 Thurs. April 5th, 2007
1146 ~~ More documentation updates ~~
1147
c899258b 1148 * Moose::Util::TypeConstraints
c1935ade 1149 - 'type' now supports messages as well
ddbdc0cb 1150 thanks to phaylon for finding this
c899258b 1151 - added tests for this
4734114b 1152 - added &list_all_type_constraints and
c1935ade 1153 &list_all_builtin_type_constraints
943596a6 1154 functions to facilitate introspection.
4734114b 1155
d022f632 1156 * Moose::Meta::Attribute
4734114b 1157 - fixed regexp 'handles' declarations
d022f632 1158 to build the list of delegated methods
4734114b 1159 correctly (and not override important
1160 things like &new) thanks to ashleyb
ddbdc0cb 1161 for finding this
1162 - added tests and docs for this
c1935ade 1163 - added the 'documentation' attributes
4734114b 1164 so that you can actually document your
1165 attributes and inspect them through the
ddbdc0cb 1166 meta-object.
d022f632 1167 - added tests and docs for this
1168
c1935ade 1169 * Moose::Meta::Class
1170 - when loading custom attribute metaclasses
4734114b 1171 it will first look in for the class in the
1172 Moose::Meta::Attribute::Custom::$name, and
c1935ade 1173 then default to just loading $name.
1174 - added tests and docs for this
1175
900466d6 1176 * Moose::Meta::TypeConstraint
1177 - type constraints now stringify to their names.
1178 - added test for this
1179
d022f632 1180 * misc.
4734114b 1181 - added tests to assure we work with Module::Refresh
1182 - added stricter test skip logic in the Moose POOP
ddbdc0cb 1183 test, ask Rob Kinyon why.
1184 - *cough* DBM::Deep 1.0 backwards compatability sucks *cough* ;)
c899258b 1185
af5199c6 11860.18 Sat. March 10, 2007
1187 ~~ Many, many documentation updates ~~
ddbdc0cb 1188
1189 * misc.
4734114b 1190 - We now use Class::MOP::load_class to
1191 load all classes.
1192 - added tests to show types and subtypes
ddbdc0cb 1193 working with Declare::Constraints::Simple
1194 and Test::Deep as constraint engines.
b77fdbed 1195
587ae0d2 11960.18_001
d01f1dab 1197 !! You must have Class::MOP 0.37_001 !!
1198 !! for this developer release to work !!
1199
734d1752 1200 This release was primarily adding the immutable
4734114b 1201 feature to Moose. An immutable class is one which
1202 you promise not to alter. When you set the class
1203 as immutable it will perform various bits of
734d1752 1204 memoization and inline certain part of the code
4734114b 1205 (constructors, destructors and accessors). This
734d1752 1206 minimizes (and in some cases totally eliminates)
4734114b 1207 one of Moose's biggest performance hits. This
734d1752 1208 feature is not on by default, and is 100% optional.
4734114b 1209 It has several configurable bits as well, so you
734d1752 1210 can pick and choose to your specific needs.
4734114b 1211
1212 The changes involved in this were fairly wide and
1213 highly specific, but 100% backwards compatible, so
1214 I am not going to enumerate them here. If you are
1215 truely interested in what was changed, please do
734d1752 1216 a diff :)
587ae0d2 1217
12180.17 Tues. Nov. 14, 2006
1219 * Moose::Meta::Method::Accessor
4734114b 1220 - bugfix for read-only accessors which
587ae0d2 1221 are have a type constraint and lazy.
1222 Thanks to chansen for finding it.
1223
12240.16 Tues. Nov. 14, 2006
1225 ++ NOTE ++
4734114b 1226 There are some speed improvements in this release,
587ae0d2 1227 but they are only the begining, so stay tuned.
4734114b 1228
587ae0d2 1229 * Moose::Object
4734114b 1230 - BUILDALL and DEMOLISHALL no longer get
587ae0d2 1231 called unless they actually need to be.
1232 This gave us a signifigant speed boost
4734114b 1233 for the cases when there is no BUILD or
587ae0d2 1234 DEMOLISH method present.
4734114b 1235
587ae0d2 1236 * Moose::Util::TypeConstraints
1237 * Moose::Meta::TypeConstraint
4734114b 1238 - added an 'optimize_as' option to the
587ae0d2 1239 type constraint, which allows for a
4734114b 1240 hand optimized version of the type
587ae0d2 1241 constraint to be used when possible.
1242 - Any internally created type constraints
1243 now provide an optimized version as well.
1244
ecb59493 12450.15 Sun. Nov. 5, 2006
946289d1 1246 ++ NOTE ++
4734114b 1247 This version of Moose *must* have Class::MOP 0.36 in order
1248 to work correctly. A number of small internal tweaks have
946289d1 1249 been made in order to be compatible with that release.
571dd39f 1250
1251 * Moose::Util::TypeConstraints
4734114b 1252 - added &unimport so that you can clean out
1253 your class namespace of these exported
571dd39f 1254 keywords
4734114b 1255
37ee30c9 1256 * Moose::Meta::Class
4734114b 1257 - fixed minor issue which occasionally
1258 comes up during global destruction
37ee30c9 1259 (thanks omega)
4734114b 1260 - moved Moose::Meta::Method::Overriden into
946289d1 1261 its own file.
4734114b 1262
1263 * Moose::Meta::Role
1264 - moved Moose::Meta::Role::Method into
946289d1 1265 its own file.
4734114b 1266
43123819 1267 * Moose::Meta::Attribute
4734114b 1268 - changed how we do type checks so that
1269 we reduce the overall cost, but still
7623f774 1270 retain correctness.
946289d1 1271 *** API CHANGE ***
4734114b 1272 - moved accessor generation methods to
1273 Moose::Meta::Method::Accessor to
1274 conform to the API changes from
946289d1 1275 Class::MOP 0.36
4734114b 1276
43123819 1277 * Moose::Meta::TypeConstraint
1278 - changed how constraints are compiled
1279 so that we do less recursion and more
4734114b 1280 iteration. This makes the type check
43123819 1281 faster :)
946289d1 1282 - moved Moose::Meta::TypeConstraint::Union
1283 into its own file
4734114b 1284
946289d1 1285 * Moose::Meta::Method::Accessor
4734114b 1286 - created this from methods formerly found in
946289d1 1287 Moose::Meta::Attribute
4734114b 1288
946289d1 1289 * Moose::Meta::Role::Method
1290 - moved this from Moose::Meta::Role
4734114b 1291
946289d1 1292 * Moose::Meta::Method::Overriden
1293 - moved this from Moose::Meta::Class
4734114b 1294
946289d1 1295 * Moose::Meta::TypeConstraint::Union
1296 - moved this from Moose::Meta::TypeConstraint
37ee30c9 1297
3ec7b7a3 12980.14 Mon. Oct. 9, 2006
4fd69d6c 1299
1300 * Moose::Meta::Attribute
4734114b 1301 - fixed lazy attributes which were not getting
4fd69d6c 1302 checked with the type constraint (thanks ashley)
1303 - added tests for this
4734114b 1304 - removed the over-enthusiastic DWIMery of the
1305 automatic ArrayRef and HashRef defaults, it
3ec7b7a3 1306 broke predicates in an ugly way.
1307 - removed tests for this
4fd69d6c 1308
c0c41f76 13090.13 Sat. Sept. 30, 2006
093b12c2 1310 ++ NOTE ++
4734114b 1311 This version of Moose *must* have Class::MOP 0.35 in order
1312 to work correctly. A number of small internal tweaks have
093b12c2 1313 been made in order to be compatible with that release.
1314
3c2bc5e2 1315 * Moose
1316 - Removed the use of UNIVERSAL::require to be a better
4734114b 1317 symbol table citizen and remove a dependency
093b12c2 1318 (thanks Adam Kennedy)
3c2bc5e2 1319
2a0f3bd3 1320 **~~ removed experimental & undocumented feature ~~**
4734114b 1321 - commented out the 'method' and 'self' keywords, see the
2a0f3bd3 1322 comments for more info.
1323
e95c7c42 1324 * Moose::Cookbook
4734114b 1325 - added a FAQ and WTF files to document frequently
e95c7c42 1326 asked questions and common problems
4734114b 1327
3f7376b0 1328 * Moose::Util::TypeConstraints
0a5bd159 1329 - added GlobRef and FileHandle type constraint
3f7376b0 1330 - added tests for this
4734114b 1331
3f7376b0 1332 * Moose::Meta::Attribute
1333 - if your attribute 'isa' ArrayRef of HashRef, and you have
1334 not explicitly set a default, then make the default DWIM.
4734114b 1335 This will also work for subtypes of ArrayRef and HashRef
94b8bbb8 1336 as well.
1337 - you can now auto-deref subtypes of ArrayRef or HashRef too.
1338 - new test added for this (thanks to ashley)
4734114b 1339
b805c70c 1340 * Moose::Meta::Role
1341 - added basic support for runtime role composition
4734114b 1342 but this is still *highly experimental*, so feedback
0a5bd159 1343 is much appreciated :)
b805c70c 1344 - added tests for this
e95c7c42 1345
0a5bd159 1346 * Moose::Meta::TypeConstraint
1347 - the type constraint now handles the coercion process
4734114b 1348 through delegation, this is to support the coercion
0a5bd159 1349 of unions
4734114b 1350
0a5bd159 1351 * Moose::Meta::TypeConstraint::Union
4734114b 1352 - it is now possible for coercions to be performed
0a5bd159 1353 on a type union
1354 - added tests for this (thanks to konobi)
1355
e95c7c42 1356 * Moose::Meta::TypeCoercion
4734114b 1357 - properly capturing error when type constraint
e95c7c42 1358 is not found
1359
3c2bc5e2 1360 * Build.PL
1361 - Scalar::Util 1.18 is bad on Win32, so temporarily
1362 only require version 1.17 for Win32 and cygwin.
4734114b 1363 (thanks Adam Kennedy)
3c2bc5e2 1364
40e89659 13650.12 Sat. Sept. 1, 2006
2bdd01cd 1366 * Moose::Cookbook
1367 - Recipe5 (subtypes & coercion) has been written
4734114b 1368
2bdd01cd 1369 * Moose
4734114b 1370 - fixed "bad meta" error message to be more descriptive
1371 - fixed &unimport to not remove the &inner and &super
3279ab4a 1372 keywords because we need to localize them.
68efb014 1373 - fixed number of spelling/grammer issues, thanks Theory :)
4734114b 1374
0558683c 1375 **~~ experimental & undocumented feature ~~**
4734114b 1376 - added the method and self keywords, they are basically
68efb014 1377 just sugar, and they may not stay around.
4734114b 1378
f742dfef 1379 * Moose::Object
4734114b 1380 - added &dump method to easily Data::Dumper
68efb014 1381 an object
4734114b 1382
b26e162e 1383 * Moose::Meta::TypeConstraint
1384 - added the &is_a_type_of method to check both the current
1385 and the subtype of a method (similar to &isa with classes)
f008ac1f 1386
68efb014 1387 * Moose::Meta::Role
1388 - this is now a subclass of Class::MOP::Module, and no longer
4734114b 1389 creates the _role_meta ugliness of before.
68efb014 1390 - fixed tests to reflect this change
4734114b 1391
8c835eba 13920.11 Wed. July 12, 2006
31f8ec72 1393 * Moose
1394 - added an &unimport method to remove all the keywords
4734114b 1395 that Moose will import, simply add 'no Moose' to the
1396 bottom of your class file.
1397
31f8ec72 1398 * t/
4734114b 1399 - fixed some test failures caused by a forgotten test
31f8ec72 1400 dependency.
1401
864cd714 14020.10 Thurs. July 6, 2006
01a8e221 1403 * Moose
1404 - improved error message when loading modules so
1405 it is less confusing when you load a role.
4734114b 1406 - added &calculate_all_roles method to
2b14ac61 1407 Moose::Meta::Class and Moose::Meta::Role
4734114b 1408
2b14ac61 1409 NOTE:
1410 This module has been tested against Class::MOP 0.30
4734114b 1411 but it does not yet utilize the optimizations
2b14ac61 1412 it makes available. Stay tuned for that ;)
4734114b 1413
2b14ac61 14140.09_03 Fri. June 23, 2006
715ea0b7 1415 ++ DEVELOPER RELEASE ++
4276ccb4 1416 * Moose
1417 - 'use strict' and 'use warnings' are no longer
4734114b 1418 needed in Moose classes, Moose itself will
4276ccb4 1419 turn them on for you.
1420 - added tests for this
1341f10c 1421 - moved code from exported subs to private methods
1422 in Moose::Meta::Class
4734114b 1423
4276ccb4 1424 * Moose::Role
4734114b 1425 - as with Moose, strict and warnings are
4276ccb4 1426 automatically turned on for you.
4734114b 1427 - added tests for this
1428
e39d707f 1429 * Moose::Meta::Role
1430 - now handles an edge case for override errors
1431 - added tests for this
b7f2d25b 1432 - added some more edge case tests
1341f10c 1433
43d599e5 14340.09_02 Tues. May 16, 2006
715ea0b7 1435 ++ DEVELOPER RELEASE ++
2c0cbef7 1436 * Moose
1437 - added prototypes to the exported subs
43d599e5 1438 - updated docs
4734114b 1439
2c0cbef7 1440 * Moose::Role
4734114b 1441 - added prototypes to the exported subs
43d599e5 1442 - updated docs
4734114b 1443
2c0cbef7 1444 * Moose::Util::TypeConstraints
4734114b 1445 - cleaned up prototypes for the subs
1446 - updated docs
2c0cbef7 1447
72c4f6d1 14480.09_01 Fri. May 12, 2006
1449 ++ DEVELOPER RELEASE ++
4734114b 1450 - This release works in combination with
1451 Class::MOP 0.29_01, it is a developer
1452 release because it uses the a new
72c4f6d1 1453 instance sub-protocol and a fairly
4734114b 1454 complete Role implementation. It has
72c4f6d1 1455 not yet been optimized, so it slower
4734114b 1456 the the previous CPAN version. This
1457 release also lacks good updated docs,
72c4f6d1 1458 the official release will have updated docs.
1459
4734114b 1460 * Moose
98aae381 1461 - refactored the keyword exports
4734114b 1462 - 'with' now checks Role validaity and
db1ab48d 1463 accepts more than one Role at a time
4734114b 1464 - 'extends' makes metaclass adjustments as
98aae381 1465 needed to ensure metaclass compatability
4734114b 1466
72c4f6d1 1467 * Moose::Role
1468 - refactored the keyword exports
4734114b 1469 - 'with' now checks Role validaity and
72c4f6d1 1470 accepts more than one Role at a time
4734114b 1471
98aae381 1472 * Moose::Util::TypeConstraints
4734114b 1473 - added the 'enum' keyword for simple
1474 string enumerations which can be used as
98aae381 1475 type constraints
db1ab48d 1476 - see example of usage in t/202_example.t
4734114b 1477
98aae381 1478 * Moose::Object
1479 - more careful checking of params to new()
4734114b 1480
72c4f6d1 1481 * Moose::Meta::Role
1482 - much work done on the role composition
4734114b 1483 - many new tests for conflict detection
72c4f6d1 1484 and composition edge cases
4734114b 1485 - not enough documentation, I suggest
1486 looking at the tests
1487
98aae381 1488 * Moose::Meta::Instance
4734114b 1489 - added new Instance metaclass to support
98aae381 1490 the new Class::MOP instance protocol
4734114b 1491
98aae381 1492 * Moose::Meta::Class
4734114b 1493 - some small changes to support the new
98aae381 1494 instance protocol
72c4f6d1 1495 - some small additions to support Roles
4734114b 1496
98aae381 1497 * Moose::Meta::Attribute
1498 - some improvements to the accessor generation code
1499 by nothingmuch
4734114b 1500 - some small changes to support the new
98aae381 1501 instance protocol
4734114b 1502 - (still somewhat) experimental delegation support
98aae381 1503 with the 'handles' option
1504 - added several tests for this
db1ab48d 1505 - no docs for this yet
98aae381 1506
35c8b8f2 15070.05 Thurs. April 27, 2006
2d562421 1508 * Moose
1509 - keywords are now exported with Sub::Exporter
1510 thanks to chansen for this commit
4734114b 1511 - has keyword now takes a 'metaclass' option
1512 to support custom attribute meta-classes
590868a3 1513 on a per-attribute basis
4734114b 1514 - added tests for this
daea75c9 1515 - the 'has' keyword not accepts inherited slot
4734114b 1516 specifications (has '+foo'). This is still an
daea75c9 1517 experimental feature and probably not finished
4734114b 1518 see t/038_attribute_inherited_slot_specs.t for
daea75c9 1519 more details, or ask about it on #moose
fcb7afc2 1520 - added tests for this
4734114b 1521
2d562421 1522 * Moose::Role
1523 - keywords are now exported with Sub::Exporter
1524
5204cd52 1525 * Moose::Utils::TypeConstraints
cce8198b 1526 - reorganized the type constraint hierarchy, thanks
4734114b 1527 to nothingmuch and chansen for his help and advice
cce8198b 1528 on this
1529 - added some tests for this
7eaef7ad 1530 - keywords are now exported with Sub::Exporter
35c8b8f2 1531 thanks to chansen for this commit
5204cd52 1532
d500266f 1533 * Moose::Meta::Class
1534 - due to changes in Class::MOP, we had to change
1535 construct_instance (for the better)
4734114b 1536
d500266f 1537 * Moose::Meta::Attribute
4734114b 1538 - due to changes in Class::MOP, we had to add the
d500266f 1539 initialize_instance_slot method (it's a good thing)
4734114b 1540
cce8198b 1541 * Moose::Meta::TypeConstraint
4734114b 1542 - added type constraint unions
c07af9d2 1543 - added tests for this
cce8198b 1544 - added the is_subtype_of predicate method
1545 - added tests for this
d500266f 1546
02a0fb52 15470.04 Sun. April 16th, 2006
1331430a 1548 * Moose::Role
1549 - Roles can now consume other roles
1550 - added tests for this
4734114b 1551 - Roles can specify required methods now with
1331430a 1552 the requires() keyword
1553 - added tests for this
1554
bdabd620 1555 * Moose::Meta::Role
1556 - ripped out much of it's guts ,.. much cleaner now
4734114b 1557 - added required methods and correct handling of
fa1be058 1558 them in apply() for both classes and roles
1559 - added tests for this
4734114b 1560 - no longer adds a does() method to consuming classes
1331430a 1561 it relys on the one in Moose::Object
4734114b 1562 - added roles attribute and some methods to support
1331430a 1563 roles consuming roles
8c9d74e7 1564
1565 * Moose::Meta::Attribute
1566 - added support for triggers on attributes
1567 - added tests for this
4734114b 1568 - added support for does option on an attribute
02a0fb52 1569 - added tests for this
4734114b 1570
8c9d74e7 1571 * Moose::Meta::Class
4734114b 1572 - added support for attribute triggers in the
8c9d74e7 1573 object construction
1574 - added tests for this
4734114b 1575
256903b6 1576 * Moose
4734114b 1577 - Moose no longer creates a subtype for your class
1578 if a subtype of the same name already exists, this
256903b6 1579 should DWIM in 99.9999% of all cases
4734114b 1580
256903b6 1581 * Moose::Util::TypeConstraints
4734114b 1582 - fixed bug where incorrect subtype conflicts were
256903b6 1583 being reported
8c9d74e7 1584 - added test for this
4734114b 1585
8c9d74e7 1586 * Moose::Object
1587 - this class can now be extended with 'use base' if
1588 you need it, it properly loads the metaclass class now
1589 - added test for this
bdabd620 1590
0677220d 15910.03_02 Wed. April 12, 2006
05d9eaf6 1592 * Moose
1593 - you must now explictly use Moose::Util::TypeConstraints
1594 it no longer gets exported for you automatically
4734114b 1595
05d9eaf6 1596 * Moose::Object
1597 - new() now accepts hash-refs as well as key/value lists
0677220d 1598 - added does() method to check for Roles
1599 - added tests for this
05d9eaf6 1600
0677220d 1601 * Moose::Meta::Class
4734114b 1602 - added roles attribute along with the add_role() and
0677220d 1603 does_role() methods
4734114b 1604 - added tests for this
0677220d 1605
1606 * Moose::Meta::Role
4734114b 1607 - now adds a does() method to consuming classes
0677220d 1608 which tests the class's hierarchy for roles
1609 - added tests for this
1610
16110.03_01 Mon. April 10, 2006
e9ec68d6 1612 * Moose::Cookbook
76d37e5a 1613 - added new Role recipe (no content yet, only code)
4734114b 1614
e9ec68d6 1615 * Moose
1616 - added 'with' keyword for Role support
1617 - added test and docs for this
1618 - fixed subtype quoting bug
4734114b 1619 - added test for this
e9ec68d6 1620
1621 * Moose::Role
1622 - Roles for Moose
1623 - added test and docs
76d37e5a 1624
1625 * Moose::Util::TypeConstraints
1626 - added the message keyword to add custom
4734114b 1627 error messages to type constraints
1628
e9ec68d6 1629 * Moose::Meta::Role
1630 - the meta role to support Moose::Role
1631 - added tests and docs
4734114b 1632
e9ec68d6 1633 * Moose::Meta::Class
4734114b 1634 - moved a number of things from Moose.pm
1635 to here, they should have been here
e9ec68d6 1636 in the first place
1637
1638 * Moose::Meta::Attribute
1639 - moved the attribute option macros here
1640 instead of putting them in Moose.pm
e185c027 1641
76d37e5a 1642 * Moose::Meta::TypeConstraint
4734114b 1643 - added the message attributes and the
76d37e5a 1644 validate method
1645 - added tests and docs for this
1646
0ac928d2 16470.03 Thurs. March 30, 2006
e9bb8a31 1648 * Moose::Cookbook
4734114b 1649 - added the Moose::Cookbook with 5 recipes,
e9bb8a31 1650 describing all the stuff Moose can do.
1651
d7f17ebb 1652 * Moose
1653 - fixed an issue with &extends super class loading
4734114b 1654 it now captures errors and deals with inline
1655 packages correctly (bug found by mst, solution
d7f17ebb 1656 stolen from alias)
159da176 1657 - added super/override & inner/augment features
1658 - added tests and docs for these
4734114b 1659
d7f17ebb 1660 * Moose::Object
4734114b 1661 - BUILDALL now takes a reference of the %params
1662 that are passed to &new, and passes that to
d7f17ebb 1663 each BUILD as well.
4734114b 1664
471c4f09 1665 * Moose::Util::TypeConstraints
1666 - Type constraints now survive runtime reloading
1667 - added test for this
d7f17ebb 1668
8339fae2 1669 * Moose::Meta::Class
4734114b 1670 - fixed the way attribute defaults are handled
8339fae2 1671 during instance construction (bug found by chansen)
1672
d7f17ebb 1673 * Moose::Meta::Attribute
1674 - read-only attributes now actually enforce their
4734114b 1675 read-only-ness (this corrected in Class::MOP as
9deed647 1676 well)
d7f17ebb 1677
076c81ed 16780.02 Tues. March 21, 2006
fc5609d2 1679 * Moose
4734114b 1680 - many more tests, fixing some bugs and
b841b2a3 1681 edge cases
b841b2a3 1682 - &extends now loads the base module with
4734114b 1683 UNIVERSAL::require
1684 - added UNIVERSAL::require to the
b841b2a3 1685 dependencies list
6ba6d68c 1686 ** API CHANGES **
4734114b 1687 - each new Moose class will also create
1688 and register a subtype of Object which
1689 correspond to the new Moose class.
1690 - the 'isa' option in &has now only
1691 accepts strings, and will DWIM in
b841b2a3 1692 almost all cases
4734114b 1693
b841b2a3 1694 * Moose::Util::TypeConstraints
1695 - added type coercion features
1696 - added tests for this
4734114b 1697 - added support for this in attributes
b841b2a3 1698 and instance construction
6ba6d68c 1699 ** API CHANGES **
4734114b 1700 - type construction no longer creates a
b841b2a3 1701 function, it registers the type instead.
4734114b 1702 - added several functions to get the
1703 registered types
6ba6d68c 1704
1705 * Moose::Object
4734114b 1706 - BUILDALL and DEMOLISHALL were broken
6ba6d68c 1707 because of a mis-named hash key, Whoops :)
4734114b 1708
b841b2a3 1709 * Moose::Meta::Attribute
1710 - adding support for coercion in the
1711 autogenerated accessors
4734114b 1712
b841b2a3 1713 * Moose::Meta::Class
1714 - adding support for coercion in the
4734114b 1715 instance construction
6ba6d68c 1716
1717 * Moose::Meta::TypeConstraint
1718 * Moose::Meta::TypeCoercion
4734114b 1719 - type constraints and coercions are now
6ba6d68c 1720 full fledges meta-objects
fc5609d2 1721
e522431d 17220.01 Wed. March 15, 2006
900466d6 1723 - Moooooooooooooooooose!!!