Moose itself uses Moose::Exporter 'has' is a thin wrapper around __PACKAGE__->meta->add_attribute read the source to Moose.pm, it's pretty simple