pugs> %a
(('1' => 'a'), ('1 2' => 'both'), ('2' => 'b'))
pugs> %a{<1 2>}
'both'
pugs> %a{1,2}
('a', 'b')
pugs> %a{<1 2>,()}
('a', 'b')
I tried to look into things, and it seems that <1 2> acting like a scalar when
it's inside a hash subscript, but nowhere else; when I forced the final
parameter of doFetch to be False (Eval.hs line 402) I got the correct result.
I have no idea what's going on in there, so I thought I might throw this out
to whoever does. I'll try to go in deeper later, but sleep and homework await
me. (Also, I'm waiting for the repository to come back up, I want the
history).
Incidentally, %a<1 2> does work in the current version, but that's because
it's not a real quoting construct (which means it doesn't interpolate \>, for
example). I found the bug when I tried to make %a<1 2> act like "real" <>,
and broke it.
Oh, I'm on r2044. (Can't update, no svn.openfoundry.org)
--
-Roie
v2sw6+7CPhw5ln5pr4/6$ck2ma8+9u7/8LSw2l6Fi2e2+8t4TNDSb8/4Aen4+7g5Za22p7/8
[ http://www.hackerkey.com ]
You need to add a case to AST.hs line 580ish to tell it that <1 2>,
like (1,), /looks/ like a list, not a scalar.
> Oh, I'm on r2044. (Can't update, no svn.openfoundry.org)
Sorry for the downtime; it should be fixed in the next 18 hours or so...
Meanwhile, you can "svn switch" to this repository:
http://svn.perl.org/perl6/pugs/trunk/
and feel free to post patches on p6c, so I can apply them. :)
Thanks,
/Autrijus/