use Moose 1.23 ();
use Moose::Exporter;
+use Moose::Util;
use MooseX::ClassAttribute::Trait::Class;
use MooseX::ClassAttribute::Trait::Role;
use MooseX::ClassAttribute::Trait::Application::ToClass;
sub class_has {
my $meta = shift;
my $name = shift;
- my %options = @_;
my $attrs = ref $name eq 'ARRAY' ? $name : [$name];
+ my %options = ( definition_context => Moose::Util::_caller_info(), @_ );
+
$meta->add_class_attribute( $_, %options ) for @{$attrs};
}