autarch/DateTime.pm — pull request #2 by preaction (2013-04-16 03:00:15+00:00)
Title: Croak when a constructor is called on an object

See: http://blogs.perl.org/users/preaction/2013/04/i-bless-you-in-the-name-of-the-stringified-object.html

TL;DR: If you accidentally call one of the constructors using an instance of an object, you get a confusing error message `Can't locate object method "_normalize_nanoseconds" via package "2013-04-15T00:00:00"`. The DateTime object gets stringified, and that used as the second argument to `bless` (the package argument).

This small check ensures that no references can be used to call the constructor. Tests were added to the other "new" checks. It seemed a good place.