Summer of Perl | 6.2.12 released! | paste: sial.org/pbot/perl6 | pugs.blogs.com | pugscode.org | pugs.kwiki.org | www.treehugger.com/files/th_images/paradigm.jpg
Set by nothingmuch on 12 July 2006.
00:03 rodi joined 00:09 autark_ is now known as autark 00:30 Pietro_KC joined, nekokak joined 00:31 Pietro_KC left 00:32 lichtkind joined 00:47 diakopter joined 00:48 justatheory joined 00:54 toku_away is now known as tokuhirom
audreyt rehi 00:55
TreyHarris audreyt: hi... do you know anything about the svn outage?
audreyt openfoundry down but svn.perl.org/perl6/pugs/trunk/ seems to have the Pugs.Val branch intact
lambdabot Title: Revision 10680: /pugs/trunk
audreyt s/branch/work/ 00:56
TreyHarris: I know that it'll usually be back once someone shows up at work
which is soon (8:56am here)
TreyHarris ok, good :-)
audreyt once sussman implements svn:* propedit in his repo 00:57
I may seriously consider switch over to it
as the invitation system can be migrated rather easily
and he said "soon" so here's hope...
TreyHarris audreyt: is coercion documented anywhere? it's implied in several synopses, but other than being .as, i don't see it explicitly discussed 00:58
jmf hey did you guys see the "google hosting" announcement?
TreyHarris jmf: links are good :-)
audreyt jmf: sussman's repo is the google repo.
:)
jmf code.google.com/hosting/
lambdabot Title: Google Code - Project Hosting
jmf oh ok 00:59
lichtkind audreyt which licence for the doc? i would like dual license artistic/free wiki licence
audreyt lichtkind: I don't quite care, but for text, I usually prefer CC-by
TimToady jmf: did you ever get your commit bit? (not that it works at the moment...)
jmf nope ive been waiting for openfoundry to come back
lichtkind by what ?
jmf that sites been down since yesterday
audreyt lichtkind: creativecommons.org/licenses/by/2.5/ 01:00
lambdabot Title: Creative Commons Deed
audreyt jmf: yeah. the good part about openfoundry is when I'm in .tw, it's fast for me and the uptime during daytime is guaranteed 01:01
the bad part about openfoundry is for people in different time zones
TimToady heh, google is just across the street from me. :)
audreyt which is the majority, when it's down it takes an awful time to come back up..
jmf google would probably be fast everywhere 01:02
:)
TimToady plus we could start corrupting google from the inside. :)
audreyt TimToady: yeah, and because sussman & co ported svn to google's BigTable filesystem, GET operations is mirrored and very fast everywhere
however commits will probably take longer for me
but that's a small price to pay, esp. considering that it will still be faster for everyone else :) 01:03
TimToady just work offline with svk and then push it all every time you come to the U.S. :)
lichtkind audreyt yes its a lot saner decision than free wiki license which is far more complicated
audreyt lol
obra audreyt: does openfoundry not have 24x7 coverage these days?
clkao is the repostory back?
obra: they don't know how to run a site
TimToady not as of 5 minutes ago
audreyt obra: it should have, but the hardware situation is weird 01:04
clkao "no one gets paged if the site is down"
audreyt which is why I'd like to switch to google repo as soon as they allow us to backport svn:author
TimToady they probably define "down" as "can't ping". And since pings still work... 01:05
clkao audreyt: have you asked them about it?
jmf how come the perl foundation doesnt get listed here? code.google.com/organizations.html 01:06
audreyt ssh is down too
lambdabot Title: Google Code - Open Source Organizations and Affiliations
audreyt clkao: yes, sussman has a hiveminder ticket that he accepted.
clkao: it all ties together :)
TimToady Google CPAN. 01:07
Just hide it all in svn.
diakopter CPANG 01:08
audreyt indeed, an autoimport of CPAN to google svn 01:09
with PAUSE comaints automagically get commit bits
to their registered modules
is something I'd like to work on too
TimToady then a CP 01:10
a CPAN install bar in firefox...
then make perl6: a prefix like http: and off we go... 01:12
audreyt use perl.org/; 01:13
jmf well it could just be perl:
lambdabot Title: The Perl Directory - perl.org
obra talked to icann about URI schemes last week, actually
The terrifying thing is that the way registration works is "if the IETF doesn't object formally within two weeks, it's oked"
TimToady when do they go on vacation? 01:14
audreyt wow. does it work that way too for MIME types?
dduncan I almost finished writing some questions to p6l, but then realized that the answers may be somewhere in the Synopsis that I couldn't find, so I'll ask here first ... 01:15
if you say @foo = (1,2), then what is the type of @foo? 01:16
is it an Array or Seq?
if you say $foo instead, then the type of the value would carry on into $foo, but I'm wondering if the @ forces a coersion
audreyt @foo is bound to Array
lambdabot Maybe you meant: faq todo yow
audreyt Array's assignment method takes a slurpy *@ 01:17
TimToady array assignment implies a copy of the values.
audreyt so Seq is evaluated in slurpy (aka list) context
dduncan okay, so then the anonymous Seq was just copied into an Array
01:17 tokuhirom left
audreyt correct. 01:17
TimToady yes. Now := would be another story.
dduncan I asked this partly because I was looking at some tests yesterday, such as data_types/array.t and saw a lot of p5isms there 01:18
01:18 miyagawa joined
audreyt := will change @foo's underlying object from Array to Seq 01:18
dduncan ah, nice to know
I was trying to get an idea how many of the @foo = (1,2) were faulty, but it seems now that maybe none are
TimToady well, = is supposed to emulate p5 pretty closely.
that was the main point of keeping it and also having := 01:19
dduncan okay, so if I say @foo := (1,2), then I can keep the @ but have a Seq instead
next question ... 01:20
TimToady and push will fail.
dduncan yes
audreyt yes. and then @foo.push(1) will fail with no-such-method
TimToady great minds...
audreyt :D
dduncan on that note, I assume that Array.does(Seq) is true, but that Seq.does(Array) is false?
audreyt that would be correct, I think
dduncan next question ... 01:21
TimToady the binding would fail otherwise, presuming that @foo remembers it's an Array.
dduncan the syntax for declaring a Mapping ...
audreyt Mapping(x => 1, y => 2)
dduncan would it be reasonable to say $foo = (1=>2,3=>4); and that be unambiguous as a Mapping rather than a Seq?
audreyt is currently the less controvertial option
(unspecced)
dduncan its the same as a Hash, but parens instead 01:22
audreyt probably not -- you can legitimatlly have {}
but having () be a mapping is bad
dduncan btw, did you mean to say mapping(...)? lowercase
audreyt (1=>2, 3, 4) too
01:22 hikozaemon joined
audreyt no... it's Mapping() 01:23
class name used as function denotes class-specific constructor/coercer of some kind
Mapping.new() may work too
but the point is there's no surface syntax (yet)
one possibility is {x=>1,y=>2}:mapping 01:24
dduncan I'll have to check the synopsis again, but there seem to be some dis-similarities in style between that and some built-in shorthands
audreyt but not sure if it's common enough to warrant that
dduncan eg, I think it gives hash() as a shorthand for a Hash
er, long-hand 01:25
audreyt I wonder if Hash() works better there and is more consistent...
dduncan if that is true, I'm inclined to think it should be cased Hash() instead for consistency
TimToady that's kind of a leftover from when it was "hash" v "sub"
audreyt there's no array() either
dduncan but then, the lowercase for builtins seemed to be more consistent with 'sub' or 'class' etc 01:26
audreyt and scalar() doesn't give you a Scalar.
clkao last time someone mentioned if it's a single(?) pair in {} then it's a hash?
audreyt so it's quite inconsistent currently
dduncan and yes, if we have a hash(), we should have an array() too for consistency
TimToady well, we can't even decide if it's scalar() or item()...
dduncan and a Seq() etc
audreyt clkao:
If the closure
appears to delimit nothing but a comma-separated list starting with
a pair (counting a single pair as a list of one element), the closure
will be immediately executed as a hash composer.
TimToady: with the want-as-&return.signature view, the context will agree with the signature terminology... 01:27
dduncan the point is, it would be nice to have more consistency than I saw
clkao is this somewhere in perl6::spec ?
dduncan looking ...
audreyt i.e. if &return.signature is (*@) then it's slurpy array context; if it's (@) it's nonslurpy array context
if it's (@, *@), then we don't have an easy name for it
but even that could happen 01:28
(@_, *@x) := f();
dduncan ah, looking back at S02 now, I see title-case names for Scalar(), Array(), Hash() having some purpose 01:29
TimToady hmm, int() vs Int() might be useful.
dduncan refering to Captures though 01:30
indeed ... then the case matches the actual class name
audreyt clkao: line 748 in S04 "Statements" 01:31
dduncan here we go ... S04 has a hash() but S02 a Hash() ... something's inconsistent here
TimToady hash is the native type. :)
audreyt we have a machine-native hash now?
which chip is that? :)
clkao cool. i can refer there when i care next time 01:32
TimToady the Judy chip
audreyt lol
dduncan that's only the Haskell implementation ... not portable
TimToady they're not calling it the Haskell chip because that would scare people.
dduncan S06 also uses lowercase hash() as well as pair() 01:33
TimToady I have no problem with making those uppercase if we decide Foo() can do that consistently.
dduncan it mentions pair() being a list operator though, so may be different than a constructor 01:34
audreyt well, that's not a problem really
dduncan for consistency, if constructors match the class name, and non-constructors are spelled differently, it would clear some things up
audreyt hash() is also listop
the constructor just need to handle the (*@) cast 01:35
case
and/or the (*%) case
TimToady or it's just a capture...
01:35 diakopter left
dduncan I assume we're also treating a non-Junction Set like Mapping, so you declare it with Set() rather than some non-alpha syntax? 01:36
audreyt that seems prudent :)
dduncan okay, so if those are the plans, it will give me something more concrete to be consistent with in my own modules 01:37
01:37 diakopter joined
audreyt TimToady: hm, somehow S04 now doesn't have the 01:38
empty {} is a Hash
wording anymore 01:39
dduncan isn't that {,} now?
audreyt also, {%x,...} should also be a Hash, right?
oh, then maybe pugs needs changing :)
but why? {,} is far more useful than {;}...
TimToady I don't think anything's changed recently on that topic.
audreyt k. so {}, {%x} are still hash composers 01:40
dduncan okay, I wasn't thinking ... that was meant to be an extrapolation of {... ,} disambiguating as a hash
but whatever 01:41
01:42 christopher joined
diakopter yap6n00b here 01:42
TimToady would you like a commit bit?
diakopter sure, if I can ever register with openfoundry
dduncan which is down afaik 01:43
TreyHarris sorry to keep asking this... but is coercion discussed anywhere?
diakopter or did you mean for parrot ;)
TimToady I don't know how to hand out commit bits for parrot...
dduncan maybe ask on #parrot ?
audreyt TreyHarris: S02
TreyHarris: there are two kinds: implicit coercion takes place when the target is a builtin value type 01:45
the table is partially given out on S02
explicit coercion takes place with the .as() method
which the infix:<as> operator falls back to
or maybe the other way around, that havn't been decided yet
TimToady does an as declaration also create the corresponding constructor? 01:46
diakopter to get up to speed, do I need to read the entire log history of this channel?
TreyHarris audreyt: ok. does it use MMD?
TimToady presumably MMDable, so other explicit
constructors don't interfere
TreyHarris diakopter: yes. we'll see you back here in October. ;-)
audreyt TimToady: conceivably the Foo($x) form falls back to $x.as(Foo) if Foo doesn't handle it 01:47
TreyHarris diakopter: no, just listen and read the synopses and you'll get up to speed
audreyt hm
actually.
Foo($x) is parsed as $x.Foo
so maybe that's how .as is declared ;)
TimToady I thought we separated that out again.
audreyt (never mind that)
TimToady so that MMD would work right. 01:48
audreyt iirc it's partially separated
only for the f(g()) form
TreyHarris hmm... but are MMD right? it's kind of upside-down, isn't it? what one would like is if you say $foo.as(Bar), and there's no good candidate to turn a Foo directly into Bar, but there is one for turning Foo into SubclassOfBar, you want to call that one, because that'll do just fine... right?
audreyt if g() still returns a single something, that something is still used as invocant... 01:49
TreyHarris er, s:w/are MMD/are MMD semantics/
dduncan another question: since undef containers are meant to be prototype objects, is it generally reasonable to just start using a new undefined container as if it were an actual object whose current value equaled the prototype?
I have generally been treating them like that now
audreyt and disamig is f(g(),). if it's changed, I don't remember seeing that in spec
dduncan seems to work fine ...
and so Perl 6 is then effectively doing what I wanted, where all containers implicitly have a value of the requisite type all the time even if not explicitly given one 01:50
audreyt TreyHarris: that is correct. contravariant MMD at this point is not well defined :)
TreyHarris: so a better proposal is welcome
dduncan: code please 01:51
TimToady need to decommute to work &
audreyt my Dog $x; $x.bark
you mean this?
dduncan for example, yes
audreyt "my Dog $x" is sugar for "my $x is Scalar of Dog; $x = ::Dog" 01:52
dduncan but also, I can say: my Array $ary; $ary.[3] = 3;
or remove the .
TreyHarris audreyt: like i said last night, my red tape is about to be cut and i'll be able to actually use my commit bit, so I'll write some tests expressing how I think it should work for some common cases. if that helps. if what you're looking for is more theoretical....
audreyt that only works because of vivification
dduncan but either way, I assume that after the element assignment, $ary is no longer undefined
audreyt TreyHarris: test-driven is fine, sprinkled with comments :) 01:53
dduncan and contains an actual object rather than a prototype
audreyt correct. but again that's because Array does vivification
i.e. when you use a undefined Array in rw position
it mallocs an instance
dduncan then with strings ... eg: my Str $foo; $foo .= 'bar';
audreyt ~= you mean 01:54
dduncan yes, I meant that
audreyt ::Str stringifies to ''
so that falls out automatically
(currently not the case with pugs)
dduncan either way, I like what seems to be happening here ... its like all types can/do now autovivify
audreyt (but will be)
er, not so quick 01:55
dduncan and so if I want to ignore the .defined status of a variable, I can safely do so ... any use of it will act like that type's "default" value
audreyt my Point $p; say $p.x
that will die
not vivify
dduncan but all built-in types will vivify?
audreyt under "class Point is rw { has $.x; has $.y }"
no. Code also does not vivify
dduncan and I can declare that my own class will too?
audreyt my Code $x; $x.signature # dies 01:56
dduncan okay, but anything that is like a number or string or list will autovivify?
or boolean
they all have conceptual "empty" values
audreyt value types all have sane defaults
Array and Hash and Scalar vivify following p5
all other types there's no guarantee 01:57
in particular, I don't expect Buf, IO, Routine, Regex etc to vivify.
dduncan I would expect Buf to autovivify to a zero-length unit like Str does 01:58
audreyt my IO $fh; $fh.say(hi)
but Str is immutable
if you think Buf should vivify as per Array
that's a valid view
dduncan yes
01:58 dolmans joined
audreyt but that also means it better be resizable 01:58
which I guess it should
dduncan I thought it was?
audreyt so ok. why not :)
yeah.
dduncan buf is fixed size, but Buf isn't afaik 01:59
audreyt yup
as Pugs.Val.* is getting filled 02:00
dduncan so on that note, since I am creating an immutable type, I would like to know what to say in the class so it knows what its prototype is
audreyt you'll have access to those toys soon :)
the prototype is just the class name
if your methods do not use the structure fields
then those methods will continue to work on the prototype 02:01
as for autovivification, I don't think there's currently a syntax for that
will be great to have one though
dduncan fyi, the prototype for my classes are meant to be like those for Set ... an empty set
audreyt my Point $p; say $p.x; # 0
dduncan which is a reasonable default
audreyt is the use case
one way to think about it is 02:02
02:02 tup joined
dduncan I have to go to dinner ... will backlog 02:02
thank yu
s/s/o/
forget that 02:03
just thank you
audreyt class Point { has $.x=0; has $.y=0; multi Point () { Point.new } }
not sure
no prob :) thank you for doing something with this language...
I need to run for lunch too
bbia
02:04 neoesque joined 02:10 xinming joined
audreyt TimToady: perhaps "close f()" try sub dispatch first, then fallback to method 02:21
and f().close is the other way around
that will make "return f()" not be a special form 02:22
dduncan back 02:43
will try that Point example 02:44
02:54 lollan joined
dduncan ?eval class Bar { has $!baz = 3; } 02:55
02:55 evalbot_11967 is now known as evalbot_11982
evalbot_11982 Can't exec "./pugs": No such file or directory at examples/network/evalbot//evalhelper-p5.pl line 46. 02:55
dduncan anyway, my Pugs gives an error with that: unexpected "=" expecting comment, trait, "handles", ";" or "}" 02:56
I thought defaults assignment used to work, but if so, its broken now
svnbot6 r11983 | clkao++ | Merge Pugs-Compiler-{Rule,Perl6} from pX/Common/ to perl5/. 02:59
dduncan yay ... repo's back 03:04
svnbot6 r11984 | Darren_Duncan++ | ext/Set-Relation/ : minor updates to newest Relation.pm code 03:11
03:18 amnesiac joined
cmarcelo audreyt: ping? 03:22
TimToady audreyt: yes, we already decided to do it that way once. but we can decide it again if you like. :) 03:34
03:40 [particle] left 03:45 nirgle joined
cmarcelo why in t/operators/assign.t line 347 (it's the dwimming section), @a == 'S' and not @a == ('S') ? 03:48
nirgle t as in Turing O_o 03:49
cmarcelo t as in perl =)... i'm talking about the tests on pugs repo. 03:53
jmf i dont see what you're talking about 03:54
line 347: is(@a, 'S', 'lhs dwims @a[0] as scalar');
cmarcelo yes. and @a is defined by @a[0] = W, I don't get why @a isn't an array, or it is and i'm missing something? 03:55
jmf does that test pass for you? 03:57
cmarcelo yes it pass. but i'm trying to understand why it should pass. (i'm experimenting changing IArray implementation and it doesn't pass in my alternative impl.) 03:58
03:59 xdg joined
jmf ah 04:07
it is being called in scalar context
if you did () i think it would then return 'L'
cmarcelo jmf: if I did () where? scalar context shouldn't get me 1 instead of 'S' (first and only element in this case)? 04:10
jmf why 1? 04:12
cmarcelo jmf: (sorry, maybe i'm confusing things with perl 5)... +@a (forced scalar context in perl5) returns number of elements. but I just discovered ~@a, which gets me "S", which equals 'S'.. 04:15
jmf this is the assignment to @a correct? my @z = (@a[0] = W, W); 04:16
cmarcelo yes.
jmf in that context W is being called to return a scalar
since its just a 1 element slice
so it should return 'S'
even though @a is a list 04:17
here is the definition of W: my sub W () { substr(want, 0, 1) } 04:18
and want is explained here: dev.perl.org/perl6/rfc/21.pod
gaal mornin' 04:19
cmarcelo jmf: I get why W returns 'S'.. the problem is, after @a[0] = W, i expected @a = ('S'), ie. one-element array containing 'S'. what i didn't knew is that is(@a, 'S') is evaluating @a in some "string"-scalar context into 'S', so the test passes. is that right? 04:20
jmf yes @a[0] is evaluated as a scalar 04:21
PerlJam cmarcelo: is() uses the boolean ops doesn't it? They provide the scalar context.
jmf PerlJam: only because its 1 element though, if it were @a[0,] or such it would still be a list 04:23
actually i dont know about that - but it has already been evaluated before the is() 04:24
cmarcelo tks, i think i got the test.. but in is(+@a, 1), the "+" is forcing what context into @a evaluation?
PerlJam cmarcelo: numeric scalar 04:25
(thus yielding the number of elements in @a)
cmarcelo so @a in scalar context means by default ~@a ("string"-scalar context)? 04:26
PerlJam no
(except perhaps in a buggy pugs :) 04:27
gaal in Perl 6? @a in scalar context is @a as an object. 04:29
04:32 xinming joined
cmarcelo gaal: @a "as an object" for "my @a = ('S');" is just 'S'? 04:33
jmf cmarcelo: its what PerlJam said about eq
gaal that's not @a in scalar context :)
jmf is() is using eq not == 04:34
cmarcelo sorry.. now i see.. (the presence of both eq and == is new to me =o) ). @a in scalar means ~@a in that case because "eq" forced string "evaluation", then? 04:37
jmf right 04:38
cmarcelo gaal: what's "@a as an object"?
jmf apparently
gaal cmarcelo: well, if we still had references, $sc = @ar would cause $sc to have the reference to @ar 04:41
as opposed to @ar2 = @ar1 where you get a shallow copy 04:42
$sc[42] would modify @ar, where @ar2[42] would not modify @ar1[42] 04:43
cmarcelo gaal: I see, by default @a in scalar is a "kind of reference" to the array, but "operators" like == or eq can force specific contexts like numeric and string.. 04:45
04:47 nirgle left
gaal cmarcelo: and you can force subcontext yourself with ? + ~... 04:47
?eval 42
04:47 evalbot_11982 is now known as evalbot_11984
evalbot_11984 Can't exec "./pugs": No such file or directory at examples/network/evalbot//evalhelper-p5.pl line 46. 04:47
gaal ?eval ?42
evalbot_11984 Can't exec "./pugs": No such file or directory at examples/network/evalbot//evalhelper-p5.pl line 46.
gaal ?eval ~42
evalbot_11984 Can't exec "./pugs": No such file or directory at examples/network/evalbot//evalhelper-p5.pl line 46.
gaal beh.
cmarcelo gaal: i get it =) 04:48
gaal that would result in 42, True, "42"
jmf gaal: are you able to compile the latest revision?
gaal it's still running here
jmf oh ok 04:49
gaal why is the section on Built-in Types in S06, "Subroutines", and not somewhere more data oriented? 04:55
jmf: build fixed, committing. 04:57
svnbot6 r11985 | gaal++ | * unbreak the build 04:58
r11986 | gaal++ | * add svn:ignore prop
gaal is google hosting going to require a google account for ci? 05:00
obra yes 05:01
jmf nice,
thats what audrey is waiting for i think 05:02
to see if theres a workaround
gaal ah, thanks
jmf awesome it worked 05:04
gaal cool 05:06
05:08 kanru joined
gaal isn't Yuval's "weak roles" proposal talking about something that should already exist in roles? ie consumed method disambiguation 05:11
I consume two unrelated roles that define a method with the same name
when I view an object as doing one role, I'd like to get that method; when I view it as the other I'd like the other 05:12
assuming these are compile-time composed, it could be (I had thought it was?) that these methods are not conflated 05:13
jmf sorry, where is this from? 05:15
gaal jmf: p6-l
TreyHarris gaal: I think you're referring to "Conjectural: If the original invocant is in a variable that is constrained to be of one role or another, then that type could be used to dispatch to the correct role's method in cases where they can't be distinguished by differences in the actual argument types"? 05:22
gaal TreyHarris: I got that from the verbal tradition, not scripture, but yes. 05:23
the problem nothingmuch is discussing seems to be how to declare definitions of abstract methods in the consumer 05:24
TreyHarris right. i think it also touches on this sentence in S06: "If the roles forget to declare them as multi, you can force a multi on the roles' methods by installing a multi stub in the class being constructed" 05:25
it seems to me that yuval's proposal is doing much the same thing, but from the perspective of the role rather than the class 05:27
but from observing nothingmuch, i get the sense that he often prefers declaration in code to disambiguation at runtime 05:28
i'm but a bear of little brain in such matters, which i'll leave to TimToady and @Larry
gaal er, I think the proposal is about the consuming class.
TreyHarris oops, you're right. i read what i thought i was reading in Yuval's message rather than what i actually read. hrm. 05:29
yeah, i don't see any difference then
nothingmuch's syntax seems more explicit. i think the multi stub mechanism will need to be commented every time it's used, it seems semi-magical (even though it's not) 05:32
gaal does anyone know how, in vim, to limit filename completion? I'm sick of hitting :e src/Pugs/In<TAB> and getting the .hi file because it's lexically prior to .hs 05:33
05:34 [particle] joined
gaal cf. "Why C is Superior to Haskell: 'c' lt 'o'" 05:34
cmarcelo gaal: look for suffixes option 05:35
gaal cmarcelo: excellent, thanks!
maybe you also know, why is mapping things to function keys flaky? sometimes it works but sometimes it just resolves to ~~~. 05:47
eg. I just want :map <F3> :cn<CR> 05:48
TreyHarris gaal: sometimes meaning successive keypresses may act differently? or sometimes in the sense of different vim sessions or different logins? 05:49
gaal I think it's a terminal thing...
cmarcelo here in gnome-terminal that seems to work (mapping F3), what term are you using? via ssh or something? 05:50
gaal ah, yes, it's definitely my terminal messing with me. I use putty+ssh.
TreyHarris getting f-keys from keyboard to app under unix involves a frighteningly large number of layers of indirection 05:51
gaal aha! think I solved it. settings, terminal/keyboard, function keys, vt100+. 05:52
cmarcelo gaal: just to know, what was setted before you change to vt100+? 05:53
TreyHarris ansi, i'll bet, if you were getting tildes
gaal ESC[n~ -- which precisely explains why f3 was ~~~ and f2 was ~~ :)
and while I'm pulling a magnet over my vim nits, does anyone know why sometimes, when I view a source file, move to a buffer that has no syntax mode, then move back, my source is not hilighted and I have to syn on again? 05:57
cmarcelo gaal: do you use minibufexpl ? sometimes it happens to me too, and i read somewhere (maybe in the mbe source) that's a minibufexpl problem.. =P 05:58
05:58 weinig joined
cmarcelo (thinking better doesn't look like it's your case...) 05:59
pasteling "cmarcelo" at 200.232.237.151 pasted "Implement IArray and IHash using HsJudy, try #2. Tested against r11916." (539 lines, 22K) at sial.org/pbot/18841 06:01
gaal cmarcelo: no it is my case :)
maybe I should try the new tabbed mode I heard vim7 has? or is that just for gvim? (I never use gvim) 06:02
cmarcelo audreyt: the late corrected version for last patch. "./pugs -e 'my @a; @a[999999999] = 2; say @a[999999999];'" works here and didn't work with trunk... i'm running smoke on it but t/op/*.t and t/builtins/* t/data_types/* are coherent with trunk. 06:04
audreyt: and as I said before, both "pop @a" and [email@hidden.address] are calling something before getting into my implementations of array_fetchSize and array_pop, and this "something" is blocking the execution (for @a defined as my last msg).. 06:07
wolverian gaal, ot' 06:09
gaal, it's for all vim flavours
06:13 weinig_ joined 06:14 weinig_ is now known as weinig|sleep
gaal yay, I'll give it a look 06:19
btw all vim users, vim.sourceforge.net/scripts/script....ipt_id=294 is a nice plugin for aligning stuff.
lambdabot Title: Align - Provides commands and maps to help produce aligned text, eqns, declarati ...
svnbot6 r11987 | agentz++ | [TASKS] 06:29
r11987 | agentz++ | updated the description of the new TODO mechanism by merging good ideas from TimToady++, gaal++, and many others.
06:30 marmic joined
svnbot6 r11988 | agentz++ | TASKS - clarified the version number fed into &todo is optional. 06:30
06:32 weinig|sleep is now known as weinig 06:41 weinig is now known as weinig|sleep 06:47 hexmode joined 07:04 buetow joined 07:09 drrho joined 07:26 integral_ joined 07:27 integral_ is now known as integral
gaal audreyt: okay, I'm sufficiently awake and will now start writing up about Val 08:04
08:11 penk joined 08:18 elmex joined 08:22 crem joined
audreyt woot! 08:24
buetow w00t! :) 08:26
jmf does there exist a written grammar for valid syntax anywhere yet? 08:31
audreyt there is perl5/Pugs-Compiler-Perl6/lib/Pugs/Grammar/Perl6.pm 08:33
there is also a similar one in parrot tree 08:34
gaal audreyt: instance ((:>:) Id) NativeBuf where cast = MkId . NBuf 08:37
beautiful, but can't we get all of native all in one there?
instance ValNative a => ((:>:) Id) a where cast = MkId . {- hw -} 08:39
audreyt not seeing an easy way
hm
yeah, if you introduce a Native class
gaal why not? 08:40
audreyt no reason not to. :)
go ahead :)
gaal yay
audreyt goes installing xcode 2.4 08:42
...heh, the download link is broken. 08:47
oh well, back to PureStr
the idea is to do piggyback on the same places where PerlSV is handled specially 08:49
svnbot6 r11989 | audreyt++ | * Eval.hs: fix trivial typo
audreyt so we can override method dispatch to the new MOP 08:50
nothingmuch gaal: i'm not aware of the semantics of role disambiguation 08:51
the idea of this thing wwas that when it's too hard to disambiguate two roles that you want to 'do'
then you declare them as weak
gaal nothingmuch: you guys are nuts, that's about the first thing I asked about when I was introduced to roles
nothingmuch and you can only do one of them at a time
yes 08:52
i been wanting disambiguation forever too =)
the point is, when a conflict can't be statically resolved
because it's too difficult
you off load it to your consumer to say which role it wants for a given scope
making the behavior of the entire class context sensitive (but the context is explicit, not implicit) 08:53
gaal: does that make more sense? 08:57
gaal nothingmuch: sorry, not enough cycles at the moment. 08:59
nothingmuch the core idea is "sometimes you just can't disambiguate two roles"
but you may still want them
me wonders if mark "gets" that abstract base classes are just like roles except less useful 09:02
09:07 crem_ joined
audreyt hm. what we really want is a way to mark contravariant mmd 09:08
nothingmuch contravariant on whose side?
invoker or invokee?
audreyt $x.as(Moose)
now if you have defined both
as(SpecialMoose)
as(Animal)
you actually want the SpecialMoose to win
at this moment Animal wins 09:09
which is totally bogus.
nothingmuch fix mmd again? ;-)
audreyt just need an annotation
that says "reverse the narrowing rule for htis position" 09:10
nothingmuch within the class body? 09:12
audreyt in the proto
nothingmuch aye
does the invocant get any say?
if the invocant actually prefers Animal?
audreyt proto method as (::t --> t) {}
er, no way... you wouldn't say .as(Moose) and get back an elephant 09:13
if elephant doesn't do moose
nothingmuch wait wait wait 09:14
audreyt haskell has builtin
nothingmuch pressed audreyt's rewind button
audreyt asTypeOf :: a -> a -> a
oh ok.
nothingmuch a bit more examples this time =) 09:15
audreyt Point is Shape; 3DPoint is Point
er I mean Poind3d
Point3d
you have an object $o
you want to get back Point
say $o.as(Point).x
nothingmuch aye
audreyt $o is actually of class Moose 09:16
Moose has
multi method as (Shape)
multi method as (Point3d)
if we list "as" using the normal MMD rule
proto as ($) {}
then Point comes in and Shape is selected
but we want Point3d 09:17
not Shape, to win
nothingmuch isn't .as(Point) going to fail if it returns a Shape?
i mean
the rules here are reversed
Point is not a parameter to .as in the natural sense
audreyt it is going to fail only if we consider the return type
right
nothingmuch that's what I meant
isn't it more like $x.(as :: Point).x 09:18
mmd on the return value?
audreyt that's what I said.
nothingmuch so why is Point a param to .as?
audreyt because we currently has no capacity of annotating as return type
also there's no capacity of return type mmd.
nothingmuch wasn't return type mmd considered good up until a while ago? 09:19
audreyt it is good, but it's undecidable
nothingmuch wonders why he missed it becoming evil again =P
isn't it just contravariant mmd on the caller continuation's type annotation?
audreyt yes, but the caller itself may be waiting for you 09:20
to decide which variant to mick
nothingmuch "accept as a parameter a function whose first parameter is...."
audreyt multif(multig())
nothingmuch in this case the context is the proto of f
audreyt which is most of the time not going to help
nothingmuch right
but that's not for this case
it's for the case:
my Shape $x = $y; 09:21
and for simple methods
audreyt so syntax wise
I wonder if we can still model it as a method call
just dispatched contravariantly
proto method as (::t --> t) {}
nothingmuch if we introduce continuation passing style, of course =)
audreyt is my working hypothesis
but we do
TimToady said that "want" can simply be &return.signature 09:22
which will massively simplify things
nothingmuch aye
okay
audreyt the old idea of "context" is changed to simply "signature"
nothingmuch so CPS in env variables =)
gaal audreyt: can we still somehow do newtype Id deriving (:>:) ValNative now that there is no ValNative?
audreyt gaal: parse error
gaal "now" = when I change Native to a class
nothingmuch do we provide type annotations on arbitrary expressions yet? 09:23
audreyt then you can't
nothingmuch maybe we just want Moose( $x.as )
audreyt I think native should still be a variant
nothingmuch no wait
audreyt easier to manage
nothingmuch that's for the constructor
i kinda like the haskell way, it's very obvious
audreyt you can creaatee a helper class
gaal ugh, ok, undoing stuff then.
audreyt a variant _and_ a class :)
nothingmuch my $moose = ( $x :: Moose ); my Moose $moose = $x; ### the same
gaal ok, the class being just for things that have themseleves as Ids? 09:24
audreyt yeah
I almost beginto think that Id should be a new opaque type in surface land
but never mind me :) 09:25
i.e. maybe .valid on all value types should return themselves
instead of doing the force-to-true massage
nothingmuch ++ ++ ++ 09:26
audreyt and we distinguish the prototypes by saying that .valid is always Undef
since value types are never Undef
nothingmuch likes this ? :)
nothingmuch i don't like force-to-anything for DWIM's sake 09:27
gaal so what does this do? $x := (); undef $x
nothingmuch i'd much rather have the evaluating context have an easier way to specify what it means more accurately
audreyt gaal: unless Seq.undef is somehow defined
I imagine it to be method not found
it's "undefine" nowadays btw. 09:28
gaal interesting.
audreyt nothingmuch: I agree
gaal bottom does not inhabit perl 6 value types and trying to assign it yields an error :) 09:30
audreyt according to the spec, implicit coercion only happens for four types 09:33
so maybe we treat them specially
(Bit/Int/Num/Str)
and introduce four methods 09:34
.bit .int .num .str
(note that the first two already exists)
I kinda like this
.to_i .to_f .to_s 09:35
as well as the .to_b Ruby never got
to quote matz: 09:36
nothingmuch NOOOOOOOOOOO ! NO UNDERSCORES!
audreyt <matz> In general, such attempt to define new false values is not worth the
performance cost we all have to pay.
nothingmuch: er I mean I like .bit .int .nnu .str
nothingmuch ;-)
i actually like .to_int etc a bit better but *shrug*
lumi .to_b might cause bad punning 09:37
audreyt .to_b || .to_b!
.to_b?
nothingmuch if ( .to_b || !.to_b ) { } will always evaluate
die(); sleep();'
i think hamlet really ment "to be xor not to be" 09:38
meant
which is why we will never be able to translate.
.. *sigh*
audreyt I think he meant "to be // not to be" 09:39
as in defined-or
09:39 rodi joined
audreyt mm. matz doesn't want .to_b for a very good reason 09:42
09:42 kane-xs joined
audreyt as in ruby that would mean you can redefine TrueClass#to_b 09:43
(since nothing is sealed)
and have "true" to mean false
perl5 took the middle path and basically seal all value types
but allow reference types to define their own "bool" 09:44
nothingmuch both have merits
the question is who the hell wants to explain to $junior_programmer why if ( true ) { print "moose" } isn't evaluating 09:45
audreyt somehow I think preventing method redefinition for builtin value types is attractive.
nothingmuch i totally agree
rodi well, true meaning false has worked very well for some politicians...
audreyt ok. so all builtin method for value types is final 09:47
what about Array.int?
4 + @foo
nothingmuch hmm 09:48
audreyt should the user be able to override it
nothingmuch i think not
unless they tie it
audreyt in which case it's not Array
nothingmuch in which case it's no longer Array
audreyt but SomeOtherType
nothingmuch aye
$[ is evil, it was deprecated for a reason
this is not precisely the same, but it's related
audreyt ok. 09:50
gaal audreyt: should there be ((:>:) Id) instances for all Val types? 09:53
nothingmuch i think it *is* legitimate to give base values new roles though
kinda like haskell type classes
audreyt gaal: that's just their valId
nothingmuch: sure, as long as they don't conflict with their existing methods
nothingmuch yep 09:54
audreyt gaal: so sure...
gaal yes, but was Val.hs:59 just a demo or is it goign to be used somewhere?
audreyt it's used on line 57
that was just experimenting; but sure
hm. there's another implicit coercion that perl does all the time 09:55
I'll call it .list for old time's sake
gaal -> PureSeq ?
audreyt PureList
($x, @y, %z) is translated to infix:<,>(variable($x).list, variable(@y).list, variable(%z).list) 09:56
and infix:<,> just does concat
and builtin .list is again nonoverridable 09:57
but that does let you write an array clasD[D[D[D[D[Ds that does not flatten
and then it's bound to @x, then it won't flatten anymore
how does this sound?
gaal so there's Id context and... List context? confusing. 09:59
audreyt Id context? 10:00
gaal (:>: Id)
audreyt that's just used for .valid
gaal ((:>:) Id)
audreyt it's an upcast... not coercion
(:>:) in general is upcast not coercion
it's just for internal use
gaal yes.... 10:01
audreyt the coercions written here will take place in the SIO monad
if not Eval monad
(still not sure)
probably SIO monad
at least for the builtin types
ok. I'll write ImplicitCoercion class 10:02
gaal needs to take a nap... & 10:03
10:04 chris2 joined
rodi ?eval my $args = \(1,2,3,:mice<blind>) 10:29
10:29 evalbot_11984 is now known as evalbot_11989
evalbot_11989 [1, 2, 3, ("mice" => "blind")] 10:29
rodi ?eval @$args[3]<mice>
evalbot_11989 Error: Undeclared variable: "$args"
rodi oops 10:30
?eval my $args = \(1,2,3,:mice<blind>); @$args[3]<mice>
evalbot_11989 \"blind"
rodi I really love you, evalbot_11989.
pugs, perl6, and all of you are so, so, so cool. 10:31
wolverian ?eval my $args = \(1,2,3,:mice<blind>); $args[3]<mice>
evalbot_11989 \"blind"
rodi is that supposed to work? 10:32
I'm still catching on to the invariant sigils, not to mention twigils. 10:33
wolverian I don't know capture semantics yet. 10:34
rodi %@$args[3]<mice> # definitely does not work... 10:35
wolverian S02 doesn't specify if Capture responds to postfix:<[ ]>
rodi more specifically: 10:37
?eval my $a = \<a b c>; say $a[1]
evalbot_11989 OUTPUT[b ] Bool::True
rodi seems to invalidate the notion of invariant sigils in my mind, though I understand Capture is magic. 10:38
I expect:
?eval my $a = \<a b c>; say @$a[1]
evalbot_11989 OUTPUT[b ] Bool::True
rodi to work.
11:38 xdg joined 11:53 arbaalo joined
arbaalo hi 11:53
11:57 codermattie joined
meppl guten morgen 12:04
12:04 justatheory joined 12:06 Limbic_Region joined 12:08 bpphillips joined
rodi wie gehts 12:10
svnbot6 r11990 | fglock++ | pX/v6 - lazy rules compilation in syntax categories 12:24
clkao fglock - you might noticed it's already merged to perl5/
svnbot6 r11991 | audreyt++ | * Pugs.Val: Coercion interface. 12:27
Limbic_Region idly wonders if Luke has returned from the dark side
12:32 fglock joined 12:36 kanru joined 12:37 iblechbot joined
fglock Test.pm on v6 now takes less than 8s; '-e' takes 1s cpu time 12:38
audreyt yay!
fglock fglock: it is 'autoloading' the rules (lazy compiling) 12:39
kolibrie fglock: very exciting! 12:40
fglock s/fglock/audreyt/ :)
12:40 cdpruden joined
kolibrie is going to try to get v6 up-and-running today 12:40
fglock this version is still in pX/Common 12:41
kolibrie fglock: so, by the time I have it working locally, it will be merged :)
12:42 nine joined
fglock it is still using a lot of ram - it is possible that the new insideout objects are not being destroyed 12:44
kolibrie one step at a time
kolibrie is not in a hurry 12:45
12:48 frederico joined 12:53 jferrero joined 12:54 jferrero left, jferrero joined
fglock oh, clako merged to perl5/ in r11983 - I'll move my changes there to 12:54
clkao
too
svnbot6 r11992 | gaal++ | * improve error messages on failed coersion 12:57
pasteling Someone at 192.115.25.249 pasted "missing instance breaks build on 6.4.1" (7 lines, 448B) at sial.org/pbot/18852
fglock clkao: I just backlogged - I'll merge now 13:02
lambdabot right now?
rodi lambdabot: you are a bot, right?
gaal > True 13:04
lambdabot True
audreyt gaal: so... I'm trying to resolve the circularity a bit 13:09
svnbot6 r11993 | audreyt++ | * unbreak the build by supplying an instance for new val
audreyt gaal: the idea is that all pure value types should have visibility to each other
I think
13:09 lypanov joined
audreyt yet they are to be defined in different modules 13:09
which means Pugs.Val will import and then export them 13:10
via .hs-boot
lypanov hey *
audreyt somehow putting "Coercible" into .hs-boot seems to not work
lypanov: hi
lypanov heya audreyt :) 13:11
lypanov was stolen by $job and mov and ->paint()
lypanov reads teh blogs
13:19 rodi is now known as rodi_away
nothingmuch hola lypanov 13:19
welcome back
lypanov yoyo nothingmuch! 13:22
nothingmuch slinky lypanov!
13:22 xinming_ joined
lypanov heh 13:22
nothingmuch did you paint anything nice? or just walls?
lypanov nothingmuch: just walls :( 13:23
svnbot6 r11994 | fglock++ | v6 - merged lazy rule compilation
gaal audreyt: won't making classes of all of them help? 13:25
svnbot6 r11995 | fglock++ | v6 - pX/Common cleanup
13:26 fglock joined, mauke_ joined
audreyt gaal: "them"? 13:26
the class is Pure... 13:27
gaal i didn't know instance Coercible SIO Val where {- nothing -} is valid haskell
13:27 kanru joined, christopher joined
gaal or that instance X {} is either, for that matter 13:27
audreyt {} is same as nothing
gaal hmm you're right it's already Pure... 13:28
of all things why is it pure that needs all-to-all visibility? 13:29
because of coersion?
(coercion?)
audreyt yeah 13:30
so strictly speaking just the coercion targets
needs to be visible
13:34 Qiang joined
audreyt valMeta is now automagic :) 13:36
i.e. if it's called in Hs as "PureStr" then it gets the p6 name "Str"
audreyt plunges ahead to make "say `hello`" work 13:37
svnbot6 r11996 | audreyt++ | * valMeta now works again by intuiting p6land data type
r11996 | audreyt++ | from hsland data type.
13:40 justatheory joined
gaal wow 13:40
13:40 mauke_ is now known as mauke
nothingmuch wow? 13:41
gaal nothingmuch: r11996 is cool 13:42
13:43 buetow joined
gaal though, I wonder, 42.meta autoboxes 42, so what's the chance of seeing a native meta? natives are unboxed and don't have metas, no? 13:43
13:44 dmsantam joined
pasteling "gaal" at 192.115.25.249 pasted "the other Cabal is jealous?" (2 lines, 143B) at sial.org/pbot/18855 13:44
audreyt did you build once with and once without embed parrot? 13:47
gaal always with, but sometimes optimized and sometimes not. 13:49
audreyt mmm 13:50
weird. :/
try not enable embed parrot while you are coding this, I guess
gaal nuking .o and .his from dist and src, trying again...
yes, that fixed it. funny.
nothingmuch ugh 13:52
my sister 13:53
is sooooooooooooooooooooooooooooo
ugh
audreyt ugh?
nothingmuch ugh. 13:54
gaal alias deadchicken find . -name \*.hi | perl -n00le '@a = split /\n/, $_; print $a[rand@a]' | xargs rm
nothingmuch: give her a commit bit.
nothingmuch no, i'd rather not communicate with her today
she is in a teacher mood
kolibrie and nothingmuch does not want to be her eager student? 13:56
nothingmuch well
she doesn't teach you anything
she just treats you like a preschooler
when she does it to my dad it's almost amusing
gaal what's the name of that search-in-source-files-of-one-kind tool again? 13:57
nothingmuch ack
?
gaal yes, thanks
audreyt: what's P and what is Identity? 13:59
hmm
@hoogle Identity
lambdabot Control.Monad.Identity :: module 14:00
Control.Monad.Identity.Identity :: a -> Identity a
Control.Monad.Identity.Identity :: newtype Identity a
gaal aha
(answer: "Go read this paper")
web.cecs.pdx.edu/~mpj/pubs/springschool.html 14:01
lambdabot Title: Functional Programming with Overloading and Higher-Order Polymorphism
nothingmuch is mpj spj's evil twin? 14:02
gaal professor s and professor m. no, doesn't have quite the right ring to it 14:03
audreyt P is Identity 14:04
gaal yes, trying to find out what that is 14:05
:)
ugh, and it's not mentioned by that name inthe Overloading paper?
haskell.org/ghc/docs/latest/html/li...ntity.html is not very useful
gaal suddenly vaguely recalls Identity is a monad? 14:06
audreyt yes
newtype Identity a = Identity a
it's a monad that's erased by the compiler 14:07
P stands for Pure
the idea is that each of the three variant is associated with a monad
Pure with P, Mut with STM, Ext with SIO
gaal ah, so all code that deals with them polymorphically can be monadic 14:08
svnbot6 r11997 | audreyt++ | * Bridge VV-land coercion with oldland fromVal, so this now works: 14:09
r11997 | audreyt++ | say `Hello, World!`;
audreyt exactly
gaal and when we are inside pure code we can escape out of the monad
audreyt yup
by saying "liftP"
liftP :: Monad m => P a -> m a
gaal unsafeExceptReallyThisIsSavePerformP
audreyt yup
I think my work today is done 14:10
if you'd like, you can try this exercise 14:11
say `1`+`1`
which involves adding fromVV to Pugs.AST.Internals's
Value Vint, Value VNum 14:12
cases
and elaborate the corresponding asNum and asInt in VV land
I also wonder if we should adopt a convention for type classes
ICoercible, IValue, etc 14:13
gaal good, except doesn't the parser already quote the thing iside ``s?
audreyt to visually distinguish them
yes, so it's testing PureStr->PureInt coercion
I'd like to get the PureStr case done right
and then select a Mut class to test
perhaps a mutable hash implemented by JudyHS 14:14
and then a Ext class, perhaps file handle
pasteling "gaal" at 192.115.25.249 pasted "another 6.4.1 error?" (19 lines, 1K) at sial.org/pbot/18856
audreyt and once the three are bridged
then we'll know the MOP is ready
seems so; I've added a -fallow-overlapping-instances 14:15
svnbot6 r11998 | audreyt++ | * cure 6.4.1 build.
audreyt see if it helps
gaal pulling
yes, thanks
audreyt yay 14:16
so, once Pure/Mut/Ext can be shown to be bridged to the old runloop
gaal ok I'll try to moose it
audreyt Capture and Signature can then be introduced
at which point we convert PerlSV to Ext
and then retire the old Value class 14:17
at which point the new MOP takes over
and then we can tackle Exp
have fun :) 14:18
*wave*
gaal say `moo` just prints moo here..
audreyt that's correct
gaal is that what was indtended?
audreyt what else do you expect? :)
try
./pugs 14:19
pugs> :d `foo`
Noop;
VPure (MkStr "foo")
gaal so `` is surface Val.Val -> VStr?
ah, the coercion is later
i get it
heh, the new ast will probably get rid of those leading Noops too :) 14:20
ok good night audreyt :)
14:20 hexmode joined
audreyt :)) 14:20
&
svnbot6 r11999 | audreyt++ | * add fromVV to oldland Val itself. 14:21
14:31 cjeris joined 14:32 fridim joined
fridim hi 14:32
14:36 mdiep joined
Limbic_Region lo 14:38
14:39 hexmode` joined
svnbot6 r12000 | gaal++ | * New naming convention gives "I" prefix to general interfaces. 14:48
r12000 | gaal++ | For now, this is used only in IValue and ICoercible.
r12000 | gaal++ | * Maybe use "A" for ASTish typeclasses (e.g. APure instead of IPure)?
14:53 awwaiid joined
svnbot6 r12001 | fglock++ | v6 - move for/while/until/loop macros to %StatementControl 14:53
fglock it should now be possible to lexically redefine statementcontrols - i haven't tried yet 14:54
& 14:55
14:56 fglock left 15:03 Eimi joined 15:18 vel joined 15:26 marmic joined, crem joined 15:30 weinig joined 15:43 rodi_away is now known as rodi 15:54 fglock joined
audreyt gaal: I think I solved the context puzzle for real :) 15:56
svnbot6 r12002 | audreyt++ | * Finally, an extremely sane treatment for item/list contexts.
r12002 | audreyt++ | both only occur in ByVal (i.e. when the return continuation is
r12002 | audreyt++ | expecting something not "is rw").
r12002 | audreyt++ | The compiler inserts a runtime dispatch of .item or .list on the
r12002 | audreyt++ | term (usually a container).
r12002 | audreyt++ | A user-defined object can elect to return its content
r12002 | audreyt++ | (like Scalar.item, Scalar.list and Array.list) or not
r12002 | audreyt++ | (like Array.item, Hash.item and Int.list).
r12002 | audreyt++ | The choice in Hs level is controlled in asList and asItem
r12002 | audreyt++ | method; the P6 level equivalence would be ".item" and ".list"
audreyt happily goes back to sleep
svnbot6 r12002 | audreyt++ | unless later overruled. :-)
r12002 | audreyt++ | * Bridged this treatment to oldland VV as well.
gaal audreyt: cool! I've beed adding PureInt `1` stuff
15:57 weinig joined
gaal but problems with circularity and ICoercible etc. mean some stuff is shoved in Pugs.Val 15:57
audreyt yup
solving circularity somehow would be a win
gaal it's almost finished compiling now, let's see if it works
audreyt but my brain is fried :)
ooh nice
*wave* again
be back in ~10hrs
gaal night :) 15:58
so, because `foo` is a string, how do I get to see MkInt in action? 16:03
it parses and compiles and all, but I still get MkStr "1" 16:04
16:04 jferrero joined
gaal guess I need to be more clever aroudn Parser:2008 16:05
okay, so I completely hijacked this and did: 16:12
return . Val . VV $ val (cast ((read str) :: Integer) :: PureInt)
but that's obviously lying since it depends on the existing Show class to do to the conversion
and yet, it works :) 16:13
though interestingly I find that + doesn't work on ints! `1`+`1` seems to require them to be lifted to doubles (VNum). isn't that a bug?
svnbot6 r12003 | fglock++ | v6 - finished %StatementControl migration
16:17 frederico joined 16:20 frederico joined
svnbot6 r12004 | audreyt++ | * Experiment with two higher-order instances of cast: 16:20
r12004 | audreyt++ | "return . cast" can be written as "cast"
r12004 | audreyt++ | "fmap cast" can be written as "cast"
r12004 | audreyt++ | also, most "liftX" can now be written as "cast" as well.
r12004 | audreyt++ | If this proves to be too confusing and/or causing too
r12004 | audreyt++ | much overlaps, then they could be retired (esp. the first
r12004 | audreyt++ | case that gives out "Just" and "singleton" for free).
Limbic_Region is a realclean currently necessary to build after recent commits? 16:21
I ask because I haven't been able to build on Win32 for about the last 5 commits
and fwiw - make realclean is b0rk on Win32 16:23
gaal Limbic_Region: nopaste? 16:24
svnbot6 r12005 | audreyt++ | * document the meaning of "cast" better: It must be injective,
r12005 | audreyt++ | i.e. different inputs must be mapped to different outputs.
Limbic_Region gaal - just a sec 16:25
which - the realclean or the build problem?
gaal the one that bothers you more :)
16:26 xinming_ is now known as xinming
Limbic_Region ah, well then that's the build 16:26
perlbot nopaste
gaal argh, audreyt, conflict in ci now. you're sleepcommitting again :)
perlbot Paste your code here and #<channel> will be able to view it: sial.org/pbot/<channel>
gaal audreyt the somnasvkcist
pasteling "Limbic_Region" at 129.33.119.12 pasted "Build problem on Win32" (31 lines, 2.3K) at sial.org/pbot/18858
gaal Limbic_Region: let me finish this commit and i'll be with you 16:27
svnbot6 r12006 | fglock++ | v6 - TODO cleanup
Limbic_Region gaal - already attempting a realclean so I might be a few minutes myself 16:28
[particle] i'm here too, doing realclean of older pugs
(win32)
16:29 ruz joined
Limbic_Region wanders off for food but bbiab 16:30
svnbot6 r12007 | fglock++ | v6 - v6.pm 0.012; Pugs::Compiler::Rule 0.13 16:31
16:32 Psyche^ joined
fglock this v6.pm is likely the cpan version - please report bugs 16:33
gaal Limbic_Region: are you running the very latest r? this error is the same kind you had the other day. what does svk pull ; svk st Pugs.cabal.in say? 16:36
svnbot6 r12008 | gaal++ | * Add VV support for PureInt. The verification is awkward to make with
r12008 | gaal++ | the `` hack, so it's commented out.
r12008 | gaal++ | * Belay the attempts at -boot files since they don't seem to allow
r12008 | gaal++ | ICoercible. The cost is that instances for that class must be defined
r12008 | gaal++ | in Pugs.Val.
16:37 hcarty joined
gaal perhaps we can group types and have Pugs.Val.Pure instead of .Str, .Int etc.? 16:38
Limbic_Region gaal - I was running the very latest rev (which was working) up until about 11998 or so 16:42
gaal please make sure your Pugs.cabal.in is up to date
Limbic_Region it is 16:43
in fact, the first thing I did this morning was remove it and svn up to verify it was restored and working (which it was)
I can post what it looks like if you think that might be of interest
gaal does it have Pugs.Val.Str?
try a clean build again. worst comes to worst, clean checkout. 16:44
Limbic_Region yes it has Pugs.Val.Str 16:45
and I am still trying the clean build from [12:28] <Limbic_Region> gaal - already attempting a realclean so I might be a few minutes myself 16:46
gaal okay. remember unoptimized 16:48
16:48 Psyche^ is now known as StudiesInWords
Limbic_Region I am not going to do a clean checkout - I know if I reverted back to 11990 or so it would work again - and I haven't done anything other than svn and nmake 16:48
Limbic_Region never does unoptimized primarily because he doesn't care how long the build takes as long as the runtime is relatively fast 16:49
not that I write much Perl 6 these days or do anything with Pugs other than verify it compiles
gaal when testing build problems...
bbl & 16:50
Limbic_Region k
it appears that all that was necessary was a realclean and a nmake 16:54
Limbic_Region is not entirely sure why that is necessary sometimes but things appear to be working just fine now
fglock I forgot to update the changelog - too late 16:56
v6 0.012 is in cpan :) 16:57
[particle] fglock++ 16:58
Limbic_Region yep - successfully built
particle - were you also having build problems on Win32?
[particle] fglock: i'm trying now to add some of your parser rules to parrot/perl6
l_r: i was going to look into yours
but my system is really slow due to currently executing backup 16:59
fglock [particle]: cool - please let me know if i can help
[particle] fglock: it'd be great to have one representation, perhaps P::C::P6 could be generated?
cjeris Limbic_Region: I'm building on win32 and can't get the ghc_heap_size: 512m setting in config.yml to take effect ... keep dying on Pugs.Parser 17:00
fglock actually, v6-compiler would be the best source
Limbic_Region cjeris - either change the size of the heap or just type nmake again after it dies - it will continue on happily
fglock I plan to emit v6.pm from v6-compiler in the (near) future
[particle] fg: is that in the pugs repo?
i see 17:01
Limbic_Region ok, built 12005 successfully and just svn'd up to 12008 - will see if that builds fine without realclean
cjeris Limbic_Region: what do I have to do to get the setting from config.yml to stick though? I don't remember having to edit anywhere else a few weeks ago
Limbic_Region notices that Pugs.cabal.in has been updated
fglock [particle]: yes - v6/v6-Compiler - I'm working on both in parallel 17:02
Limbic_Region cjeris - dunno though I am not the right person to be asking
fglock v6-Compiler is 'p6p6' and v6.pm is 'p6p5'
Limbic_Region cjeris - IOW, if uncommenting # ghc_heap_size: 348m in your config.yml and/or adjusting it doesn't stick - I am at a loss 17:03
[particle] ah, i see. p6p6 is viable now? that's great.
clkao fglock: whoot release. does syntax/braces-in-rule pass?
fglock v6.pm is supposed to compile v6-Compiler, and then you only need v6.pm to implement low-level stuff 17:04
clkao: should I have tested before releasing? :) 17:05
[particle] fglock: well if i can get the prereqs set up on windows, i may be able to help with parser mods
fglock clkao: I'll try
[particle]: I installed in windows with vanilla-perl 17:06
17:06 weinig joined
Limbic_Region if anyone is using AS Perl with mingw then I can tell you how to get all the v6.pm prereqs installed 17:07
[particle] l_r: could you write up a pod? 17:08
Limbic_Region AS is broke and Module::Build finds the error
particle - it would be easier just to point to the PerlMonks node where I asked (and got solutions)
btw - Jan Dubois from AS applied the patch that bart came up with and it is going to be part of build 818 17:09
[particle] ah. those bums at perlmonks helped ;)
nothingmuch Juerd: ping
fglock bbiab &
Limbic_Region see perlmonks.org/index.pl?node_id=565276 17:10
lambdabot Title: Re^3: Help building Devel::Caller
Limbic_Region while that addresses Devel::Caller, the patch actually fixes the AS Perl, MinGW, Module::Build problem 17:11
nothingmuch Juerd: actually, hold that ping, i am going to take a shower first
17:12 frederico joined
fglock clkao: do you know what needs to be added to Makefile.PL in order to have precompiled Test.pm and Prelude in the distro? 17:14
(Module::Compile stuff)
17:20 weinig joined
clkao crazy module::install-fu. ask ingy 17:24
Limbic_Region ok, that was odd 17:30
bpphillips fglock: check search.cpan.org/src/INGY/Module-Com....18/README under the "DISTRIBUTION SUPPORT" section
Limbic_Region I finally got build 12005 working after doing a realclean
I svn'd up to 12008
I did an 17:31
fglock bpphillips: thanks!
Limbic_Region nmake
built fine - but doing a pugs -v still shows 12005?
17:36 weinig joined
svnbot6 r12009 | fglock++ | v6 - t/syntax/parsing/braces_in_rules.t "ok 1 - expression parsed" 17:36
r12010 | fglock++ | more...
fglock clkao: fixed :)
17:42 weinig joined 17:45 aufrank joined 17:46 baest joined 17:47 pmurias joined
pmurias hi 17:47
ingy hola
pmurias what would the following english order somebody to do, say "h" if 1 is unequal to 1 or 2 or 3, otherwise say "hello" 17:50
?
wolverian "h" 17:51
Limbic_Region pmurias - I believe it is ambiguous that given the verbal direction to different people would result in different responses
pmurias but I would tend to agree with wolverian that the majority would go with "h"
pmurias meant "hi" :) 17:52
aufrank there's definitely an ambiguity in scope
wolverian this is why junctions and negations are strange.
pmurias well, the example was inspired by the synopsis
that was (i'm not sure if correct) translation of "if $a != 1 | 2 | 3 {...}" 17:54
Limbic_Region pmurias in a programming language it is easy, all that is necessary is to know the precedence of or
of course, or ne junction so that kind of breaks down too 17:56
pmurias the synposis suggest that that code should raise a warning , because it work diffrently in perl and in english, 17:58
wolverian "if a is not 1 or 2 or 3..." 18:00
is the translation you are looking for
which means 'if $a != all(1,2,3)' 18:01
Limbic_Region wolverian - um, no 18:02
that should be any(1,2,3) 18:03
wolverian well, that is how I parsed the english.
Limbic_Region 1 & 2 & 3 would = all(1,2,3)
wolverian yes.
but I did not translate from perl to perl, but from english to perl.
Limbic_Region isn't complaining about your english translation - just your code
wolverian I _meant_ 1 & 2 & 3 18:04
18:04 jferrero joined
wolverian "if a is not 1 or 2 or 3" means that a can not be any of them, i.e. all(), not any() 18:04
Limbic_Region um, than you should s/or/and/
or rather 18:05
wolverian "if a is not 1 and 2 and 3" does not make sense. :)
Limbic_Region s/or/and not/g
wolverian right.
Limbic_Region if a is not 1 and not 2 and not 3
wolverian anyway, I believe that is what the synopsis refers to - people do use "or" there.
pmurias by the way is there a word in english meaning xor? 18:06
remembered the either form :) 18:07
wolverian yes, xor. :-)
..not many people use it though..
pmurias "i will go on foot xor call a taxi" is a bit strange... 18:10
Limbic_Region there is a www.dictionary.com entry for xor but not a thesaurus.reference.com/ entry so I doubt there is a common english word that means the same as xor 18:12
lambdabot Title: Thesaurus.com
pmurias the polish word is "albo' 18:15
merlyn exclusively or. :) 18:16
or the word OR with a lot of emphasis
TimToady xor is generally "or" in English.
c6rbon in English, 'or' is most often used as xor.
merlyn you can have the cake ORRRRRRRR the ice cream
TimToady to really mean "or" you say "and/or"
c6rbon even without emphasis, xor is its usual meaning. 18:17
merlyn which is never pronounced "and or or" :)
even though logically, it must mean that
c6rbon English doesn't really have a logical OR I can think of - we rarely use that meaning in speech. 18:18
TimToady I'm thinking that fake methods should be treated syntactically as type coercions rather than methods, so that would change .meta to .Meta or Meta(), .valid to .ValueId or ValueId(), and also variable() to .Variable or Variable() 18:19
assuming we recognize type names as method calls representing coercions 18:20
wolverian sits down 18:21
merlyn english has illogical or
wolverian TimToady, all types?
TimToady :D
most of 'em are uppercase, so it might not be a big collision problem. 18:22
gaal logicians have optimistic expectations of formalization
TimToady if foo() and .foo are nearly the same, then Type() and .Type should probably be nearly the same thing.
pmurias merlyn: i think got the point quite clearly
wolverian but I'm used to seeing the type in front of the name 18:23
TimToady then write it that way.
wolverian I'm playing devil's advocate, mostly. does prefix type coerce too then? 18:24
TimToady another way of saying what I'm saying is that I'm claiming the types Meta, ValueId and Variable rather the method name.
whether Type($x) can also be written $x.Type is orthogonal to that. 18:25
wolverian oh. yeah. sorry.
TimToady alternatively we could claim META(), VALUEID(), and VARIABLE() 18:26
18:26 bernhard joined
TimToady still as type names... 18:26
syntactically speaking 18:27
pmurias that would be better
than Meta,ValueId and Variable IMHO 18:28
TimToady I suppose we could have $x.META without allowing $x.Int, but it seems cleaner to generalize
since .META actually is saying "make me a metaclass object out of this"
18:30 fitzzz joined
TimToady On the contravariant "as", I think we just say that it's not really a method in this class. You're really writing a default constructor for the other class. 18:30
18:30 fitzzz left
TimToady and $x as Foo then calls Foo($x) 18:31
and there is no .as method
you just say $x.Foo if that's what you want 18:32
in which case maybe we don't need infix "as". 18:36
that might give us back .as for formats.
biab & 18:37
wolverian I am liking it.
TreyHarris we do mean boolean-or sometimes. "if you are an elite member of one of our frequent-flyer partners OR are seated in first class rows 1-8, you may now board OR later at your leisure". one boolean or, one xor. 18:41
18:49 weinig joined
svnbot6 r12011 | fglock++ | v6 - updated v6-rule grammar; fixed token <@array> 18:57
TimToady I suppose if the value id is just the value itself for value types, it could just be .VALUE or .VAL 18:59
and then VARIABLE could be .VAR
VAR($x).foo 19:00
wolverian I like the short-and-caps style.
TimToady if we say that any .TypeName is recognized at compile time, that gives us potentially a general way to write other macro-like methods too. 19:01
and it even kindof follows the cpp macros-in-uppercase convention 19:02
and/or, we require/allow $x.::TypeName 19:04
if required, then you'd have to write META($x) or $x.::META 19:05
but we have the .^ notation as a shorthand still, presumably.
I dunno, I'm inclined to allow but not require the :: 19:06
[particle] does the :: sigil interact with any twigils? 19:07
TimToady but that does create a natural conflict between compile-time vs run-time dispatch.
can't have it both as a macro, and as a fallback from .Foo to Foo() at run-time.
unless the class marks its constructor as a macro maybe 19:08
then $x.FOO could be translated to FOO($x) at compile time, but $x.BAR could just call Object.BAR which defers to BAR($x). 19:09
hmm, well, I really oughta go to work...
since it's already after noon...
19:10 frederico joined
TimToady method ::Foo { ... } # how to write coercion? 19:21
method ::Foo { Foo(self) } # default coercion?
I think it's probably better to make all classes macroish methods to give the optimizer a shot at them. 19:27
not sure how this fits in with virtualized classes though. 19:28
I guess the compiler already knows which classnames are virtualized though. 19:30
19:33 justatheory joined, broquaint joined 19:43 andez joined, andez left 19:52 jmf left 20:00 weinig joined 20:02 weinig joined 20:10 vel joined 20:18 bpphillips left, weinig joined 20:19 buubot joined 20:25 asz joined 20:31 jferrero joined 20:47 equinox5 joined
equinox5 hi 20:47
what will be ready by Christmast?
I have heard of Perl 6 will be ready by then. 20:48
What backend will be ready by then?
obra equinox5: it's a joke. Nobody will tell you which christmas 20:55
20:55 SageLT joined
marcus_ is dreaming of a green christmas 21:03
obra: congrats on the hiveminder going public
obra thanks
marcus_ -/win 5 21:06
agh
StudiesInWords yes, congrats, obra
equinox5 obra.. joke Yes, I heard that a year ago... 21:08
but on www.pugscode.org/ I saw a presentation and a graph showing the end of 2006.... 21:09
lambdabot Title: Pugs - pugscode
equinox5 as a finish line.
21:11 Maddingue joined
svnbot6 r12012 | fglock++ | v6 - added 'StatementModifier' grammatical category 21:13
21:15 fglock joined
fglock re what backend will be ready first - I guess they are very likely to get ready together, as the spec gets stable and we get more reusable algorithms and code 21:18
ingy: ping 21:22
ingy: 'pmc_support' didn't work in v6 Makefile.PL - I'm reinstalling M::Install and M::Compile ... 21:26
21:27 kanru joined
fglock it works now - I had to remove ../../inc 21:31
now i've got to find out how to exclude files from precompilation 21:37
svnbot6 r12013 | fglock++ | v6 - added precompilation support to Makefile.PL (needs more work)
fglock & 21:39
21:39 fglock left
equinox5 bye 21:49
21:50 dduncan joined 21:51 fglock joined, dduncan left 22:00 Psyche^ joined, dduncan joined 22:08 weinig joined 22:14 Psyche^ is now known as StudiesInWords
svnbot6 r12014 | fglock++ | v6 - added 'Quote' grammatical category 22:19
22:21 hcarty left
svnbot6 r12015 | Sage++ | The -R option for translation (which makes minimal changes to regexs) is now functional, I'm also working on making it change captures too (which should make it a valid option for translation instead of a shortcut for code that doesn't use captures). 22:21
r12015 | Sage++ | Some functionality is in place for translating exports. The translator now knows which functions need to have "is export" added, but the actual translation doesn't happen yet.
22:24 cjeris left 22:32 StudiesInWords joined
svnbot6 r12016 | fglock++ | v6 - added ?\194?\171quotes?\194?\187 but Text::Balanced doesn't recognize it; needs some work 22:43
22:43 frederico joined
svnbot6 r12017 | fglock++ | v6 - ':!a' adverbial pair 22:45
22:56 Excedrin joined 23:03 Bit-Man joined 23:11 cm joined 23:22 froh-doh joined 23:24 fglock left
svnbot6 r12018 | fglock++ | v6 - non-working '=begin END', commented out 23:24
23:28 lumi joined 23:34 luqui joined, mauke_ joined 23:41 explorer__ joined 23:43 theorb joined 23:44 mauke_ is now known as mauke, explorer__ joined 23:46 weinig joined
svnbot6 r12019 | rodi++ | Tests for correct interpolation of whole hashes in double quotes. 23:47
cognominal usr/bin/ld: warning multiple definitions of symbol _PC
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libreadline.dylib(terminal.so) definition of _PC
/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libncurses.dylib(lib_tputs.o) definition of _PC
/usr/bin/ld: warning multiple definitions of symbol _UP
pugs does not like on my macbook to have both readline and libncurses installed :( 23:48
23:50 jferrero joined 23:53 vel joined 23:54 Jackfrost joined 23:55 theorb is now known as theorbtwo
audreyt cognominal: it's just a warning 23:59
feel free to ignore it