New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Default Stringification of Objects #186
Comments
From @chromaticFrom masak in IRC today: class A {}; say A.new The attached patch fixes that, but it doesn't work yet due to some sneaky -- c |
From @chromaticclass_get_string.patch=== languages/perl6/src/classes/Object.pir
==================================================================
--- languages/perl6/src/classes/Object.pir (revision 29799)
+++ languages/perl6/src/classes/Object.pir (local)
@@ -87,6 +87,18 @@
.return $P0.'hash'()
.end
+.sub 'get_string' :vtable :method
+ .local string what
+ what = self.'WHAT'()
+
+ .local string name
+ name = '<obj:'
+ name .= what
+ name .= '>'
+
+ .return( name )
+.end
+
=item item()
Return the scalar component of the invocant. For most objects,
|
From @jnthnOn Sat Jul 26 12:28:54 2008, chromatic@wgz.org wrote:
pmichaud has done this in r32373, so I think this ticket is now Thanks, Jonathan |
The RT System itself - Status changed from 'new' to 'open' |
@jnthn - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#57310 (status was 'resolved')
Searchable as RT57310$
The text was updated successfully, but these errors were encountered: