Skip Menu |

This queue is for tickets about the Moose CPAN distribution.

Report information
The Basics
Id: 34313
Status: resolved
Priority: 0/
Queue: Moose

People
Owner: stevan.little [...] gmail.com
Requestors: mschwern [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: 0.40
Fixed in: (no value)



Subject: Make C<< has "thing"; >> DWIM
I figure this would DWIM. package Foo; has "thing"; my $foo = Foo->new( thing => 42 ); $foo->thing; but no accessor was generated. jrockway on #moose explained that it declared an attribute without an accessor, and I understand why they're differentiated. jrockway also explained the aim was to be explicit, but if that were so "is" would be a required parameter and you'd have to set it to "none". As it stands right now the above is a trap as it silently does an unexpected, fairly obscure (from a new Moose user standpoint) thing. It would be nice if it DWIM, and WIM is rarely "make me an attribute without an accessor". I've been writing Moose for 10 minutes and already I'm sick of writing, C<< is => "rw" >>. Simple Huffman encoding says that should be the default.
RT is not the right place for this. Please either send an email to the list or discuss this on IRC. Thanks, - Stevan