Skip Menu |
 

This queue is for tickets about the Hash-AsObject CPAN distribution.

Report information
The Basics
Id: 87989
Status: rejected
Priority: 0/
Queue: Hash-AsObject

People
Owner: Nobody in particular
Requestors: nebulous [...] crashed.net
Cc:
AdminCc:

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



Subject: TO_JSON
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Message-ID: <rt-4.0.16-16437-1377050631-854.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 320
Download (untitled) / with headers
text/plain 320b
It would be helpful to have TO_JSON defined so that the JSON modules can serialize directly as they do for hashrefs. Right now I'm monkeypatching TO_JSON = sub { {%$_[0]} }. Sure, I could subclass, but Hash::AsObject is all about being lazy with hashes. Subclassing would go against the very foundation of the module! :)
MIME-Version: 1.0
In-Reply-To: <rt-4.0.16-16437-1377050631-854.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.16-16437-1377050631-854.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.16-11725-1377536392-1552.87989-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 76
Sorry, this doesn't fall within my conception of what Hash::AsObject is for.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.