Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2005-08-22

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 fglock_ has quit IRC ("Leaving")
00:13 stevan putter: mm 2.0 is still in progress
00:13 stevan but it is meant to be a simplified version of mm 1.0
00:14 stevan and it expects a smaller set of "things" to "just be there"
00:16 gantrixx a submethod is just a method that doesn't get inherited?  correct?
00:16 stevan gantrixx: yes, for the most part
00:16 stevan it is best used for infastructural methods
00:16 gantrixx hmmm...then perhaps I've discovered an error
00:17 gantrixx could I paste something for you?
00:17 putter back...
00:17 stevan sure
00:17 stevan gantrixx: FWIW I think submethod is just an alias for method right now
00:17 gantrixx I think so too
00:17 stevan gantrixx: I doubt we will have proper submethods until the metamodel is in
00:18 pasteling "gantrixx" at 24.251.41.77 pasted "$kangaroo.move() should be undefined" (38 lines, 682B) at http://sial.org/pbot/12649
00:18 gantrixx it seems to inherit the submethod
00:18 gantrixx so perhaps this isn't implemented yet
00:19 stevan gantrixx: yes, i think am pretty sure 'submethod' is just an alias for 'method'
00:19 gantrixx ok, I won't worry about it then
00:19 gantrixx or should I notify someone of this?
00:19 putter fglock_: yes it does (seem to make sense).  though I'm fuzzy brained just now.
00:20 stevan gantrixx: check in t/oo/ if you see tests which check this and are labeled :todo
00:20 stevan if not, please write some tests :)
00:20 putter stevan: the mob cries out for a mm to bang on.  actually, if the external api is stable, any mm will do...
00:21 stevan putter: I am planning on keeping the same external API
00:21 stevan the class 'Foo' => { ... } stuff that is
00:21 stevan it will basically be a "macro" layer over the mm 2.0
00:22 stevan but that is just the p5 version
00:22 stevan autrijus needs to make the haskell version work, my haskell skills are non-existant
00:24 putter ok... hmm...
00:25 putter bbiab
00:26 stevan putter: I started documenting the p6 facing API for the metamodel in the docs/ dir, but current $work.load() is keeping me away from finishing it
01:00 gantrixx I have a question about the $?VARS
01:00 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
01:00 stevan gantrixx: ask away
01:00 gantrixx how would you use $?SUBNAME
01:01 gantrixx meaning which subname an I in
01:01 stevan gantrixx: the best place to look is in t/magicals actually
01:03 fglock_ has joined #perl6
01:04 putter stevan: ok. thanks.
01:05 justatheory has joined #perl6
01:05 stevan putter: believe me, I would rather do Pugs than $work right now
01:05 putter ;)
01:06 fglock_ putter: what's going on?
01:06 * putter has to obtain $work rsn
01:07 putter fglock_: err, laundry, about to grab some dinner, ...
01:07 putter It's been quiet.
01:07 fglock_ I'm planning to work on the 'Sub' object
01:07 putter awesome.
01:07 fglock_ and find out a way to call it from p5
01:08 gantrixx On thing that would be very helpful for debugging is if you had some way of printing out an objects attributes and methods and from where, if other than self, that they are inherited from
01:08 putter feel free to bypass ApiX if it's getting in your way.
01:08 stevan fglock_: I have some basic stuff in the metamodel 1.0 you might want to look at
01:08 stevan fglock_: t/80_Code.t I think is the file
01:08 gantrixx is this something that I might find in a synopses, epock, or campfire folklore?
01:09 stevan gantrixx: hopefully someone will implement something like that. The Metamodel will make doing it fairly trivial actually
01:09 fglock_ sure - thanks
01:09 iblechbot has quit IRC (Read error: 110 (Connection timed out))
01:09 fglock_ gantrixx - there is a 'meta' method, that offers a lot of methods like that
01:10 gantrixx please point me in the right direction
01:10 gantrixx what is a meta method?
01:10 fglock_ things like $thing.meta.name - returns the object class name
01:10 castaway has joined #perl6
01:10 theorbtw1 has joined #perl6
01:10 stevan gantrixx: see "Introspection" in the Synopsis 12 for small glimpse
01:11 fglock_ stevan - is meta defined in the metamodel, or the runtime should supply it?
01:12 stevan fglock_: I was pondering this issue while walking my dog tonight actually :)
01:13 * fglock_ has just walked the dog
01:13 stevan the MM 1.0 makes a mess of this actually, but originally just added a meta method to the base Object
01:13 stevan however, in MM 2.0, we have merged MetaClass and Class into one
01:14 stevan and my current thought process has been do something like this:
01:14 stevan $FooClass->class_method()
01:14 stevan $iFoo->instance_method()
01:14 stevan $FooClass->META::meta_method()
01:14 stevan $iFoo->META::meta_method()
01:15 stevan META:: is a pseudo package like SUPER:: basically
01:15 stevan but I am not sure of the soundness of that approach
01:16 * putter originally read/thought stevan had just been talking with his dog about meta.  also plausible, but somewhat odder...
01:16 * stevan has a very smart dog, in fact he design the metamodel... shhh dont tell
01:17 fglock_ about using uppercase - is .fetch() supposed to be written .FETCH() (in Array,Scalar)?
01:18 stevan fglock_: I am not sure, I assume FETCH since that is what tie() used
01:18 justatheory has quit IRC ()
01:18 justatheory has joined #perl6
01:18 justatheory has quit IRC (Client Quit)
01:19 fglock_ the original p6 syntax was $obj.meta.meta_method - changing it to $obj.META::meta_method() doesn't change things much
01:19 fglock_ it sure makes sense
01:20 gantrixx is this $obj.meta.getmethods() stuff supposed to work now or is it on the todo list?
01:21 fglock_ Where are p6 subroutine names going to be stored? (and variable names)
01:22 fglock_ gantrixx: I think the meta API was not implemented yet
01:23 stevan fglock_: meta.meta_method() can also just be a sugared form of META::meta_method() too
01:23 stevan gantrixx: no .meta methods will work yet
01:24 fglock_ are you planning to support pads in MM2? for local classes, etc
01:25 stevan fglock_: I could, my current focus on mm2.0 is to just clean things up
01:26 leo__ stevan: you need a smart and good looking dog like archimedes: http://nonseum.at/verein/archi.jpg
01:26 stevan and make it (I hope) easier to integrate into the runtimes
01:27 theorbtwo has quit IRC (Read error: 110 (Connection timed out))
01:27 * stevan ponders a canine hack-a-thon :)
01:27 leo__ # we got 3
01:28 castaway_ has quit IRC (Read error: 110 (Connection timed out))
01:35 putter scholarly looking dog. :)
01:35 fglock_ stevan: you wrote everything already :)
01:35 stevan fglock_: but re-writes are so much fun ;)
01:36 putter a quick dinner.  bbl &
01:36 * stevan actually wrote about 8-9 different metamodel prototypes before the one which eventually became 1.0
01:36 leo__ putter: well, his name is Archimedes
01:39 Eryadan has joined #perl6
02:31 putter_ has joined #perl6
02:31 putter_ leo__: lol # re Archimedes
02:32 putter_ was he so named as a pup, or more recently?
02:34 vcv- has joined #perl6
02:36 putter_ hmm, Bundle::Perl6 looks out of date...
02:36 putter has quit IRC (Read error: 113 (No route to host))
03:06 fglock_ ping
03:06 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
03:06 svnbot6 r6404 | fglock++ | * perl5/ Code
03:06 svnbot6 r6404 | fglock++ |   - refactored Code.pm from stevan's MetaModel t/80_Code.t
03:06 svnbot6 r6404 | fglock++ |   - 'Code', 'Sub', 'MultiSub', 'Block' are now Perl6 classes
03:09 putter_ autrijus: re rt.openfoundry.org, fyi pugs/ pugs/browse/ and pugs/rss/ are all identical (and still  back at 6384).   I also got a "could not write to (directory?)" error page when I first loaded it.  fyi.
03:31 autrijus fixed.
03:31 putter_ :)
03:31 * putter_ is reading PIL2JS...
03:31 autrijus I hope you like the new foundry ui :)
03:33 putter_ nicely cleaner.  more Tufte.  but when urls go i18n, then I wont be able to determine what links do by looking at the url... ;)
03:34 autrijus :D
03:35 putter_ awww, its back to english.  I was kind of enjoying the international flavor of the log being in chinese...
03:38 putter_ (there's just no pleasing some customers;)
03:41 autrijus has quit IRC ("Lost terminal")
03:44 fglock_ putter: ping
03:44 putter_ pong.
03:45 fglock_ I've got a Code class
03:45 fglock_ it passes some tests already
03:46 putter_ (ust wondering how to do exceptional control flow if p5 code can call methods directly...)
03:46 putter_ nifty! :)
03:46 putter_ once it can do say(), it can be swapped into pil-run... :)
03:47 fglock_ multi subs should work soon - I'm slowly getting used to MM
03:48 whiteg has quit IRC (Read error: 104 (Connection reset by peer))
03:48 putter_ so the named sub stuff is implementing a namespace?
03:49 putter_ oh, thats the test file.  never mind.
03:49 svnbot6 r6405 | fglock++ | * perl5/ Code - passes a few tests
03:50 fglock_ I'm using stevan's idea of placing the names into a hash
03:50 fglock_ there could be some kind of export control
03:51 fglock_ there is the need to do name scopes too
03:51 putter_ could you walk me through it?  you have a p5 sub say { print @_,"\n"; }.  How does one create a Sub, and then call it?
03:53 putter_ hmm, can it do *@slurpyarray params?
03:53 fglock_ see t/code.t - that's almost plainly stevan's code, that I translated to p6-ish
03:54 putter_ ahh.
03:54 fglock_ you will - but the current code doesn't know about that yet
03:54 fglock_ (that's 1h worth of coding)
03:56 fglock_ the good news is that stevan's code was written with native data in mind - so it should play well with p5 data
03:56 Amnesiac has quit IRC ("Leaving")
03:56 putter_ !:)
04:00 fglock_ must sleep now &
04:00 putter_ me too.  good night &
04:00 * luqui too
04:00 putter_ ;)
04:00 luqui hello and good night
04:01 putter_ good night luqui.
04:01 fglock_ good night all
04:02 putter_ I'm tempted to try faking slurpyness in the PrimX, but I suspect <,> will break.  perhaps wait for mm slurpies.
04:02 putter_ now I'm hungry.  #slurpies.
04:02 putter_ good night fglock_.
04:03 fglock_ has quit IRC ("Leaving")
04:15 putter_ fglock_: ?
04:15 putter_ ok 2 - The object isa Code
04:15 putter_ Can't call method "params" on an undefined value at lib/Perl6/Code.pm line 119.
04:15 putter_ end of day. good night all &
04:15 putter_ has quit IRC ("Leaving")
04:19 SamB has joined #perl6
04:33 autrijus has joined #perl6
04:33 Eryadan has quit IRC (Remote closed the connection)
04:36 vcv- has joined #perl6
05:13 coet has quit IRC (Read error: 104 (Connection reset by peer))
05:13 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
05:13 coet has joined #perl6
05:32 nothingmuch has joined #perl6
05:46 saorge__ has quit IRC (Read error: 110 (Connection timed out))
05:51 coet has quit IRC (Read error: 113 (No route to host))
06:03 SM_ax has joined #perl6
06:36 vcv- has joined #perl6
06:39 rmr has joined #perl6
06:39 rmr hello everyone :-)
06:43 rmr is there anyone in here???
06:43 jql any*one* or anyone *helpful*?
06:44 rmr any one with a helping attitude :-)
06:45 * Supaplex calls kill(getpid(),SIGSLEEP);
06:45 jql hah
06:45 * jql has an attitude
06:46 rmr gud
06:50 rmr has left
06:57 iblechbot has joined #perl6
07:01 scook0 has joined #perl6
07:13 larsen has joined #perl6
07:14 pdcawley has quit IRC ()
08:13 lhooq has joined #perl6
08:13 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
08:45 rlb3 has quit IRC (Read error: 104 (Connection reset by peer))
08:47 rlb3 has joined #perl6
08:54 iblechbot has quit IRC (Read error: 104 (Connection reset by peer))
09:01 andynu_ has joined #perl6
09:05 andynu has quit IRC (Read error: 104 (Connection reset by peer))
09:13 vcv- has joined #perl6
09:22 xinming luqui: you there please?
09:22 xinming luqui: There is a correction need to do to the Synopsis.
09:26 jp-autark has quit IRC ("leaving")
09:34 iblechbot has joined #perl6
09:44 whiteg has joined #perl6
09:47 nothingmuch xinming: mail corrections to perl6-language@perl.org as unified diff
09:49 xinming nothingmuch: Ok, thanks.
09:51 nothingmuch xinming: anyone can fix synopses, but unlike the pugs repo you need someone with commit access (@Larry, leo__, chip, pmichaud) to svn.perl.org
09:51 nothingmuch only they can apply
09:54 xinming nothingmuch: :-) But luqui seemed did the change to Synopsis. ;-)
09:55 nothingmuch xinming: luqui is a member of @Larry
10:01 * pdcawley_ looks at some of the discussions of symbolic lookups and hopes that $::('string with spaces') is going to be as legal in Perl 6 as its equivalent is in Perl 6. And hopes further that Larry's right that $::('foo') will check both lexical and dynamic scopes.
10:02 nothingmuch $::('foo') should be just like $foo
10:02 prefiks has joined #perl6
10:02 nothingmuch so "me too"
10:02 pdcawley_ ?eval my $foo = 10; $::('foo')
10:02 evalbotzy \10
10:02 nothingmuch huraaaa
10:02 pdcawley_ ?eval my $foo = 10; $foo
10:02 evalbotzy \10
10:03 pdcawley_ Weird... isn't that a reference?
10:03 nothingmuch i'm not sure
10:03 pdcawley_ ?eval 10
10:03 evalbotzy 10
10:03 nothingmuch ?eval my $foo = 10; $foo.ref
10:03 evalbotzy ::Int
10:03 nothingmuch ?eval my $foo = 10; $foo + 5
10:03 evalbotzy 15
10:03 nothingmuch ?eval my $foo = 10; $::('foo') + 5
10:03 evalbotzy 15
10:03 pdcawley_ I rather think that's odd...
10:03 nothingmuch i'm guessing that pugs passes the container in case it's 'is rw'
10:03 pdcawley_ ?eval my $foo = 10; 5 + $foo
10:03 evalbotzy 15
10:04 nothingmuch and + binds the container's value to another container
10:04 nothingmuch and returns a value
10:04 pdcawley_ Anyone got a running pugs to check on?
10:04 nothingmuch in short '$foo' can mean either container or value
10:04 pdcawley_ I think you're probably right.
10:04 nothingmuch while '$foo + 5' is just value
10:04 nothingmuch so I wouldn't fret over it, but I can check (not at work though, later)
10:06 lhooq pdcawley_: I think it's just an evalbot issue
10:07 pdcawley_ Yeah. Sounds plausible.
10:07 lhooq pdcawley_: evalbot doesn't properly "print" the evaluated result. it sorts of "dump" it
10:07 * pdcawley_ grins, "I don't need the details"
10:07 lhooq :-)
10:11 lhooq memo to self: don't try to be helpful unless someone cries "HELP!"
10:14 nothingmuch 10.perl
10:14 renormalist has joined #perl6
10:14 nothingmuch ?eval 10.perl
10:14 evalbotzy '10'
10:14 nothingmuch ?eval my $foo; $foo.perl
10:14 evalbotzy '\\undef'
10:14 nothingmuch ?eval my $foo = 10; $foo.perl
10:14 evalbotzy '\\10'
10:14 nothingmuch that's what it does
10:14 nothingmuch evalbot simply calls .perl on a thing
10:14 nothingmuch and $foo.perl is a container, not a value
10:15 nothingmuch you can say 'my $foo = 10; my $str = $foo.perl; my $bar := eval $str; $bar + 5'
10:15 nothingmuch ?eval my $foo = 10; my $str = $foo.perl; my $bar := eval $str; $bar + 5
10:15 evalbotzy 15
10:15 nothingmuch ?eval my $foo = 10; my $str = 10.perl; my $bar := eval $str; $bar + 5
10:15 evalbotzy 15
10:15 nothingmuch it behaves the same
10:16 nothingmuch but vice versa it won't work
10:16 nothingmuch not thaat I can describe it in perl because perl does away with such pointless details =)
10:16 nothingmuch essentially - a reference is something you can write to
10:16 nothingmuch $foo is a symbol that contains a reference that contains a value
10:16 nothingmuch 10 is a value
10:16 nothingmuch $foo.perl dumps the reference and the value, 10.perl dumps the value
10:17 nothingmuch cleared up?
10:21 xinming {n,m}                 <n,m>                 # assert repeat count
10:21 xinming so, will this still work?
10:21 xinming <n, m>
10:21 QtPlatypus <n, m>
10:21 xinming {n, m} changed into **{'n', 'm'}
10:21 xinming How about <n,m>?
10:21 xinming Is it still working?
10:21 wolverian I thought it's **{n..m} now
10:21 Juerd It is n..m indeed now
10:22 wolverian Juerd, thanks. :)
10:22 Juerd x**{n,m} will actually mean [x**{n}|x**{m}]
10:22 wolverian that's logical.
10:22 Juerd (Stupid syntax!)
10:22 wolverian heh. :)
10:22 Juerd I really HATE **{}
10:23 Juerd I can live with **, I can live with {}
10:23 xinming Juerd: you should tell @larry. :-)
10:23 Juerd Not with a 4 character regex op.
10:23 Juerd xinming: I have.
10:23 Juerd Larry's very indifferent to what the community thinks whenever the community mostly agrees.
10:24 Juerd \d**5 should be easy to make work
10:24 xinming Juerd: well, You might believe that Larry has done right thing on perl 5? :-)
10:24 Juerd And then () for grouping and {} for closures is all fine by me.
10:24 xinming s/might/have to/
10:24 Juerd xinming: Not really
10:24 Juerd xinming: It works.
10:24 Juerd Perl 6 can be close to perfection but in some areas imperfection is chosen as the standard.
10:26 xinming Juerd: hmm, well, the truth must be proved. :-)
10:26 Juerd I, for one, am disgusted by some of the "you should avoid this, so we're making it very ugly" ideology
10:27 Juerd Yes, in TEXT, you should indeed try to avoid **{}, but in all those other strings, it's a very important feature that is used a lot.
10:27 xinming Juerd: well, I believe that @Larry thought more than us on perl 6 language design. ;-)
10:27 Juerd Don't think I'll write \d**{3} if  Ican write \d\d\d
10:27 Juerd xinming: I believe that, but I think that that is no guarantee for success.
10:27 QtPlatypus Though it starts to become a factor with your dealing withs omething like **{20}
10:28 Juerd In fact, the more he thinks about things that were already set in stone before, the more the design suffers.
10:28 QtPlatypus Juerd: Your speeking like when I got my proposeal to have "eval" as an option to q
10:28 QtPlatypus rejected
10:28 xinming Juerd: hmm, well, I hope he would think more...
10:29 xinming Juerd: @Larry might cosidered that there might be some special case...
10:29 Juerd And then there are a few inconsistencies that I think are stupid to leave in.
10:30 Juerd xinming: Not really.
10:30 Juerd (By the way, what is this Larry is God thing? He's incredibly smart, but makes mistakes too.)
10:31 xinming Juerd: I don't think @Larry is God, But at least, He can do a much better design than we could. that's all.
10:32 Juerd Yes, the basis for the design is his strength
10:32 Juerd The fuckups are in details.
10:33 xinming ?eval "stirng".pos
10:33 evalbotzy Error: No compatible subroutine found: "&pos"
10:33 Juerd ?eval "abcdef".length
10:33 evalbotzy Error: No compatible subroutine found: "&length"
10:33 Juerd That's so gonna bite me
10:34 Juerd But length gone is in fact a very good idea :)
10:35 xinming ?eval "lsd;kjfsdfj".bytes;
10:35 evalbotzy 11
10:35 xinming :-)
10:38 QtPlatypus ?eval "\x{78}".bytes
10:38 evalbotzy 4
10:38 QtPlatypus ?eval "\x{78}".chars
10:38 evalbotzy 4
10:38 QtPlatypus ?eval "\x78".chars
10:38 evalbotzy 1
10:38 QtPlatypus ?eval "\x78".bytes
10:38 evalbotzy 1
10:39 QtPlatypus Bytes lies.
10:59 f0rth ?eval "喵".bytes
10:59 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
10:59 evalbotzy ***      unexpected "("     expecting term postfix, operator, postfix conditional, postfix loop, postfix iteration, ";" or end of input     at -e line 11, column 4
11:02 xinming ?eval "ä½ ".codes;
11:02 evalbotzy 1
11:02 xinming ?eval "ä½ ".bytes;
11:02 evalbotzy 1
11:02 xinming lies to us...
11:02 xinming ?eval "ä½ ".chars;
11:02 evalbotzy 1
11:02 xinming ?eval "你好".chars;
11:03 evalbotzy 2
11:03 xinming ?eval "你好".bytes;
11:03 evalbotzy 2
11:03 xinming It seems that utf-8 support for pugs isn't so well.
11:04 f0rth ?eval "ä½ ".bytes
11:04 evalbotzy 1
11:04 f0rth ?eval "汪汪".bytes
11:04 evalbotzy 2
11:06 * QtPlatypus nods "Hopefully that will be fixxed when we have raw strings"
11:11 xinming by the way, Insn't there any function which will "open" a file? :-S
11:11 xinming It seems that my $stream is from($fh); will slurp file into a scalar. and my @stream is from($fh) will slurp file into a @arry.
11:12 xinming hmm,
11:12 xinming might be worng.
11:19 meppl has joined #perl6
11:36 dudley has quit IRC (Remote closed the connection)
11:37 dudley has joined #perl6
11:49 dudley has quit IRC ()
11:49 umbop has joined #perl6
11:55 meppl has quit IRC ("quit")
12:08 orafu has quit IRC (Read error: 113 (No route to host))
12:09 kolibrie has joined #perl6
12:15 orafu has joined #perl6
12:35 iblechbot_ has joined #perl6
12:37 vkon has joined #perl6
12:38 vcv- has joined #perl6
12:39 vkon are there special reasons why pugs version at "feather.perl6.nl" now is 6378, and not 6405?
12:40 xinming vkon: Because that is not the default resiponsory for pugs.
12:41 xinming vkon: try this. http://svn.openfoundry.org/pugs/
12:41 xinming maybe not the "official".
12:41 kolibrie vkon: I think Juerd was out-of-town for a bit
12:43 vkon ... a build is automated... but I think it could not be built for some reasons (make do not finishes cleanly?)
12:43 vkon ?eval say $?PUGS_VERSION
12:43 evalbotzy Perl6 User's Golfing System, version 6.2.9, August 3, 2005 (r6378) bool::true
12:44 vkon When I compiled last few times, there were error messages but executable was seemingly fine... anyone with similar experience?
12:44 fglock has joined #perl6
12:50 iblechbot has quit IRC (Connection timed out)
12:52 prefiks has quit IRC (Remote closed the connection)
12:55 evalpugs has joined #perl6
12:55 xinming ?eval $?PUGS_VERSION
12:55 evalbotzy \'Perl6 User\'s Golfing System, version 6.2.9, August 3, 2005 (r6378)'
12:55 evalpugs \'Perl6 User\'s Golfing System, version 6.2.9, August 3, 2005 (r6405)'
12:55 xinming hmm...
12:55 evalpugs has quit IRC ()
12:57 vkon xinming: how did you do that?
12:58 xinming vkon: what?
12:58 xinming vkon: Do mean mean the run th ebot?
12:59 vkon acme__: two different eval ... yes, run the bot?
12:59 xinming vkon: well, they are 2 different bot.
12:59 xinming one is from me, and another is from someone else here.
13:00 vkon ?eval $?PUGS_VERSION
13:00 evalbotzy \'Perl6 User\'s Golfing System, version 6.2.9, August 3, 2005 (r6378)'
13:00 scook0 ?eval say "Hello, vkon!"
13:00 evalbotzy Hello, vkon! bool::true
13:00 vkon but there was another one evalpugs... ok, nevermind...
13:01 ods15 ?eval 'a'
13:01 evalbotzy 'a'
13:01 xinming vkon: that's "my" bot. :-)
13:01 ods15 ?eval a
13:01 evalbotzy Error: No compatible subroutine found: "&a"
13:01 xinming ?eval "string".pos;
13:01 evalbotzy Error: No compatible subroutine found: "&pos"
13:01 ods15 ?eval "a"
13:01 evalbotzy 'a'
13:01 ods15 ?eval "$?PUGS_VERSION"
13:01 evalbotzy 'Perl6 User\'s Golfing System, version 6.2.9, August 3, 2005 (r6378)'
13:02 ods15 ?eval $?PUGS_VERSION
13:02 evalbotzy \'Perl6 User\'s Golfing System, version 6.2.9, August 3, 2005 (r6378)'
13:02 ods15 that's a bug
13:02 xinming ?eval my $a =5; "$a".say;
13:02 evalbotzy 5 bool::true
13:02 nothingmuch hola ods15
13:02 ods15 i think
13:02 ods15 nothingmuch: is that a bug?
13:02 xinming Odin-: which one?
13:02 nothingmuch ods15: no
13:02 scook0 just a quirk of evalbot
13:02 ods15 why the different behavior
13:02 nothingmuch becase $?PUGS_VERSION is not a value, it's a variable
13:02 ods15 scook0: well a bug in evalbot is still a bug :)
13:03 nothingmuch scook0: i disagree
13:03 nothingmuch ?eval my $foo = 10; $foo.perl
13:03 ods15 ?eval my $a = 'a'; $a
13:03 evalbotzy '\\10'
13:03 evalbotzy \'a'
13:03 nothingmuch ?eval my $foo = 10; ($foo).perl
13:03 evalbotzy '\\10'
13:03 nothingmuch ?eval my $foo = 10; ($foo + 0).perl
13:03 evalbotzy '10'
13:03 nothingmuch see the diff?
13:03 ods15 wtf is .perl ?
13:03 nothingmuch ods15: dump it as perl code
13:03 nothingmuch evalbot calls .perl on it's return value
13:03 ods15 ah
13:03 nothingmuch s/return value/reduced expression/;
13:04 nothingmuch since $?PUGS_VERSION is a container, it is dumped as a reference (a reference is the value that is a container)
13:04 ods15 and, ohhhhhhhhhhhh, that make's sense
13:04 ods15 \ as in back refernce
13:04 nothingmuch yep;
13:04 ods15 \  "string"
13:04 nothingmuch ?eval my $foo; \$foo;
13:04 evalbotzy \undef
13:04 nothingmuch ?eval my $foo; \$foo
13:04 evalbotzy \undef
13:04 ods15 as opposed to just "string" which is a value
13:04 nothingmuch uh, oops
13:04 nothingmuch yes
13:04 ods15 ok neat
13:05 nothingmuch see, '$foo' the expression may be bound to something else, as rw
13:05 revdiablo has quit IRC (Remote closed the connection)
13:05 nothingmuch ?eval my $foo = 10; $bar := $foo; $bar = 1; ($foo + 0)
13:05 evalbotzy Error: Undeclared variable: "$bar"
13:05 nothingmuch ?eval my $foo = 10; my $bar := $foo; $bar = 1; ($foo + 0)
13:05 evalbotzy 1
13:05 nothingmuch ?eval my $foo = 10; my $bar := ($foo + 0); $bar = 1; ($foo + 0)
13:05 evalbotzy Error: Can't modify constant item: VInt 10
13:06 nothingmuch imagine that instead of '$bar := <expr>' i said '<expr>.perl' and it makes sense
13:07 ods15 whats :=
13:07 nothingmuch ods15: runtime binding
13:07 ods15 like C++'s '&' ?
13:07 nothingmuch i doubt it
13:07 nothingmuch don't think in terms of pointers
13:07 ods15 no, not pointer
13:07 nothingmuch address of?
13:07 nothingmuch or a different &?
13:07 ods15 'int & a = b;'   a and b are now the same variable
13:07 nothingmuch ahb
13:07 nothingmuch yes
13:07 xinming ods15: many things in perl are in different state...
13:07 nothingmuch i didn't know about that
13:08 ods15 nothingmuch: niether did i till i saw it...
13:08 QtPlatypus Like perl5's *foo = *bar
13:08 vkon has quit IRC ("CGI:IRC")
13:08 ods15 perl5 had '*' ??
13:08 nothingmuch ods15: := means 'assign the container to the symbol', while = means 'assign the value in the container to the container'
13:08 ods15 nothingmuch: yes i got it :)
13:08 nothingmuch there's also ::= which is compile time binding
13:09 nothingmuch which behaves more like a macro
13:09 ods15 difference?
13:09 nothingmuch my $bar ::= $foo; # from now on any instance of '$bar' can be compiled to a lookup for '$foo'
13:09 QtPlatypus ods15: Yes, it mean varable glob.
13:09 scook0 ::= would work for things that /have/ to be known at compile-time
13:09 ods15 as opposed?
13:09 scook0 (and presumably more efficient)
13:10 nothingmuch := is just an assignment on the container, instead of the value
13:10 prefiks has joined #perl6
13:10 ods15 ::= just sounds more limited (and faster?) version of :=
13:10 nothingmuch you can't use something that isn't known at compile time on the right side of ::=
13:10 ods15 yup
13:10 nothingmuch exactly... it's a safety feature
13:10 * nothingmuch tries to figure out who the fuck is messing up his character encodings
13:11 ods15 speaking of which, how is perl5 with multilang crap
13:11 ods15 hey, nothingmuch, you're grey again! just noticed
13:11 nothingmuch ods15: every strings is implicitly unicode, unless the 'use bytes' pragma
13:11 nothingmuch ods15: i'm at work now
13:11 ods15 ah
13:11 ods15 perl6* i meant
13:12 nothingmuch perl 6 is much more spunky
13:12 nothingmuch a str is low level data (chars or bytes, or whatever)
13:12 nothingmuch a Str is several
13:12 nothingmuch you have characters, symbols, graphemes
13:12 nothingmuch and bytes
13:12 nothingmuch all accessible by stating your preference or explicitly saying which one you're using
13:12 nothingmuch the canonical representation is unicode
13:12 nothingmuch the internal representation doesn't matter
13:13 ods15 btw try not to make same mistake as hurd and other big stuff.. overdesigning and making something "perfect" only leads to it never being released or buggy
13:13 nothingmuch encodings can be converted when moving strings in and out of the process (into a handle, etc)
13:13 nothingmuch ods15: this has already been designed by the unicode folks
13:13 ods15 how well can i do low level crap with perl6?
13:13 nothingmuch all Perl 6 is giving is a portable API into unicode strings
13:13 nothingmuch my str $bytes;
13:14 ods15 i dunno, some kind of special ram access, sockets, write()'s, etc.
13:14 nothingmuch my int @array; # packed array, just like a C array but with bounds checking
13:14 nothingmuch special ram access - runtime dependant
13:14 nothingmuch sockets - you have system calls
13:14 nothingmuch but probably wrapped as abstracted handles
13:14 nothingmuch see also http://search.cpan.org/search?quer​y=IO%3A%3A&amp;mode=all&amp;n=100
13:14 ods15 heh
13:14 nothingmuch mostly IO::Hanlde and it's deriviatives
13:15 nothingmuch system calls in perl 5 are structured around STDIO
13:15 nothingmuch where buffered write is 'write' and "real" write is called "syswrite", for example
13:15 nothingmuch doh
13:15 nothingmuch the only function this doesn't apply to is actually 'write'
13:16 nothingmuch don't use write, use 'print'
13:16 ods15 that's useless for low level stuff :)
13:16 nothingmuch but read, open, etc
13:16 ods15 (i.e., stuff with nuls)
13:16 nothingmuch no it isn't
13:16 nothingmuch perl is null safe
13:16 nothingmuch syswrite(STDOUT, "\0"); # works
13:16 nothingmuch ods15: assume makes an ass out of u and me
13:17 QtPlatypus BTW has anyone given any thoughts to my question about lazy IO conflicts?
13:17 nothingmuch QtPlatypus: dated when?
13:17 ods15 syswrite yes, and but you said to use 'print'
13:17 ods15 16:16:01 <nothingmuch> don't use write, use 'print'
13:17 ods15 16:16:14 <ods15> that's useless for low level stuff :)
13:17 nothingmuch print "\0"; # works
13:17 ods15 print "\0hello world"; prints what?
13:17 revdiablo has joined #perl6
13:17 ods15 ?eval say "\0hello world";
13:17 nothingmuch • [syeeda:~] nothingmuch % perl -e 'print "\0hello"' | od -c
13:17 nothingmuch 0000000   \0   h   e   l   l   o  
13:18 nothingmuch ods15: evalbot has limited opcodes and prolly won't allow it
13:18 * ods15 looks around for evalbot
13:18 ods15 heh
13:18 nothingmuch plus IRC is probably blocking it
13:18 ods15 heh what's up with your prompt
13:18 nothingmuch my prompt has a little round bullet char
13:18 nothingmuch which is red if $? is != 0
13:18 nothingmuch and green otherwise
13:19 nothingmuch it's the same char you get when you type into password boxes
13:19 ods15 why are there so many hex dumping tools on linux :)
13:19 ods15 1 is enough...
13:19 ods15 xxd, od, hexdump... heh
13:19 nothingmuch i only use od nowadays
13:19 nothingmuch od -x and od -c
13:19 nothingmuch mostly od -c
13:19 ods15 nothingmuch: heh i have a bit more
13:19 ods15 16:19) ods15@linux15:~ $ false
13:19 ods15 Error 1|16:19) ods15@linux15:~ $ true
13:19 ods15 16:19) ods15@linux15:~ $
13:20 nothingmuch ods15: same principal, only ansi colors
13:20 xinming what does <?ws> mean?
13:20 xinming for rule...
13:20 nothingmuch xinming: IIRC noncapturing whitespace or something
13:20 ods15 ya mine actually says the number :) which sh btw
13:20 ods15 psh?
13:20 nothingmuch ods15: bash
13:20 ods15 ah
13:20 ods15 zsh rox
13:22 nothingmuch ods15: so i've heard
13:22 nothingmuch i'm interested in recursive globs
13:22 nothingmuch but "if it ain't broke don't fix it"
13:22 nothingmuch and my setup is far from broke
13:23 ods15 yeah i love it's tab completion.. what i like about tab completion is that i can learn a program while typing out it's command...
13:23 ods15 whats recursive globs?
13:23 nothingmuch in zsh you can say 'echo some_dir/**'
13:23 nothingmuch and it recurses all the children of some_dir
13:23 nothingmuch like find
13:23 ods15 ah those
13:23 ods15 well you can do that in bash too actually
13:23 ods15 ls /*/*
13:24 nothingmuch but not recursively?
13:24 ods15 zsh is kinda more interesting, you can do '/home//.kde<tab>' and it will fill in '/home/ods15'
13:24 ods15 16:24) ods15@linux15:~ $ echo mdf/**
13:24 ods15 mdf/DriveD mdf/Encoding Tools mdf/FlashFXP mdf/My Download Files mdf/kazaa mdf/mirc mdf/noise Folder mdf/oldhd mdf/shows
13:24 ods15 .. not at all recursive...
13:24 nothingmuch well, stuff like that is not worth the learning curve and the loss of the fact that i overcame the bash learning curve
13:25 nothingmuch oh, i thought it was really recursive
13:25 nothingmuch bummer
13:25 ods15 yeah i've never seen the need for that '//' feature
13:25 ods15 but i like other zsh features
13:25 ods15 i like that it shows me the options BELOW the line, not dump em and make a new prompt
13:25 nothingmuch in bash i fluently type for loops, nested backticks, pipelines, subshells and so forth without thinking... every time i'm on tcsh it takes me 3-4 tries for each complex command to realize why it's not working
13:26 nothingmuch so relearning something right now is not a good idea
13:26 xinming $_.pos = 0;
13:26 xinming    s:c{ (<?ident>) = (\N+) $$}{$1 => $2} for 1..4;
13:26 xinming what does this do for sure? :-S
13:26 ods15 i like that i can do bla/<tab><tab> and it will just fill in the first option, VERY useful with hebrew filenames
13:26 xinming Synopsis doesn't cover the example in detail. T_T
13:26 nothingmuch <?ident> is "identifier", probably "\b.*?\b" or something like that
13:26 ods15 heh zsh is fully bash compliant
13:26 scook0 xinming: reading S05?
13:27 xinming scook0: yes
13:27 nothingmuch for the weird prompts and bash completion and all that too?
13:27 ods15 you can do ln -sf /bin/sh /bin/zsh , and end up with (slightly) faster ./configure scripts
13:27 nothingmuch no bourne shell, bourne again shell
13:27 ods15 zsh's prompt is completely different from bash's..
13:27 nothingmuch c'est un otre chose
13:28 ods15 PS1 is nothing like it, took me quite a while to redesign mine when i switched
13:28 nothingmuch $PS1 function callbacks and all that?
13:28 scook0 xinming: the important point is the `for 1..4`
13:28 nothingmuch see, that's what I don't want to go through right now
13:28 scook0 everything else is just details of the example
13:28 ods15 yes, but you talked about pipelines and for loops, they are identical in zsh
13:28 scook0 it's showing what the :x() modifier does
13:28 xinming scook0: I know that, for (1, 2, 3, 4) { }
13:29 scook0 xinming: It just means that the substitution happens four times
13:29 scook0 instead of one
13:29 xinming s:c{ (<?ident>) = (\N+) $$}{$1 => $2}
13:29 ods15 and yes i use em fluently too
13:29 nothingmuch Sogudi is soo nice... i have 's 05' aliased for synopsis 05, 'pd Moose' raise search.cpan.org/perldoc?Moose, 'cpan' do a regular search, wp for wikipedia, c2 for c2.com/wiki
13:29 ods15 i have a lot of aliases for 'common' stuff
13:29 nothingmuch ods15: csh vs. bash is apples vs. oranges
13:29 nothingmuch right now I have stuff working, and i'm used
13:30 ods15 dunno about csh, iirc it sucks
13:30 nothingmuch zsh is like an orange with slightly more flavour, i guess
13:30 xinming scook0: hmm, So, could you please give me an exampel?
13:30 ods15 zsh is exatly the same regarding those piplines :)
13:30 nothingmuch csh does suck, it sucks major ass
13:30 nothingmuch ods15: right, but the small difference is not worth it
13:30 nothingmuch because most of what I do already works
13:30 ods15 L for '|less', G is for '|grep', P is for '|perl -pe' :)
13:30 nothingmuch my env is "good enough"
13:30 ods15 W is for '|wc -l'
13:30 nothingmuch i don't work like that... i type fast enough that things get "programmed"
13:31 ods15 so i can type nice stuff like 'ls W' :)
13:31 ods15 i don't type that fast, and i like it cause it's kind of easier to read
13:31 nothingmuch i would just as well do 'ls | wc -l
13:31 ods15 reaching for | is annoying
13:31 nothingmuch fairynuff
13:31 scook0 xinming: (my $str = 'xxxx') ~~ s/x/y; # yxxx
13:31 scook0 xinming: (my $str = 'xxxx') ~~ s:x(3)/x/y; # yyyx
13:31 ods15 i basically have A LOT of aliases..
13:31 * nothingmuch envisions a *nix keyboard where there are two space bar like keys, and one is |
13:31 ods15 16:31) ods15@linux15:~ $ alias W
13:31 ods15 53
13:32 nothingmuch i've got 8 by that measure
13:32 lhooq scook0: s/x/y/
13:32 nothingmuch all are very big
13:32 ods15 a lot of em are mplayer related
13:32 scook0 lhooq: aye, typo
13:32 ods15 i have about 8 different aliases for running mplayer is different ways
13:32 nothingmuch for example grep with a bunch of --excludes, gnucash launches an x server, 'cvg' is
13:32 ods15 (full screen in framebuffer, not full screen in framebuffer, in X, using vidix, etc.)
13:33 xinming scook0: Oh, thanks. :-)
13:33 nothingmuch prove with Devel::Cover and open to browser
13:33 QtPlatypus July 30 subject: Lazyness and IO http://groups.google.com.au/group/perl.perl​6.language/msg/f686745b828b6e7c?hl=en&amp;
13:33 scook0 xinming: I think you got distracted by all the other crazy stuff :)
13:33 nothingmuch ods15: what's the diff between vidix and xv?
13:33 lhooq scook0: shouldn't s:x(3)/x/y/ return "xxyx"?
13:33 nothingmuch QtPlatypus: the main solution that I see @Larry have come up with is "*shrug*" so far
13:34 ods15 vidix is direct connection to hardware, hence being hardware specific and needing root privledges (or a special patch to the kernel)
13:34 nothingmuch nothing substantial
13:34 ods15 Xv is Xvideo extention to X...
13:34 scook0 lhooq: that would be s:nth(3)/x/y/
13:34 lhooq scook0: right, thankyou
13:34 ods15 you can even use Xv over network (i've done it...)
13:34 nothingmuch ods15: vidix ~~ dri but for 2d?
13:34 scook0 (or s:3rd/x/y/)
13:34 ods15 not sure what dri is
13:34 QtPlatypus nothingmuch: Oh dea.
13:34 QtPlatypus dear
13:34 scook0 (or even s:3nd/x/y/) :)
13:34 nothingmuch QtPlatypus: IMHO laziness should be explicit, but then again my humble opinion is always warnocked
13:35 nothingmuch '=' is hufffmanized enough for laziness
13:35 nothingmuch annything 'is pure' can be auto lazified
13:35 lhooq scook0: but not s:3th/x/y/ :-)
13:35 QtPlatypus IO is inherently unlazy.
13:35 scook0 lhooq: that would work too
13:35 nothingmuch and any place where there is affinity between left and right side, WRT laziness (both sides want laziness) it is taken
13:35 ods15 if your X's XV is working, vidix will be marginally faster if at all (it has the tiny advantage of not going through TCP and X's API. but that's it)
13:35 QtPlatypus IO is inherently inpure I mean.
13:36 nothingmuch as for your post, i'd expect only the first article to be read
13:36 lhooq scook0: so 'nd', 'th' and 'rd' are completely interchangeable?
13:36 ods15 but, vidix's beauty is that it works even when not in X :) as in, even from VGA console!
13:36 nothingmuch but the rest is read later
13:36 nothingmuch ods15: ah, that's good to know
13:36 scook0 lhooq: right, the idea is so that non-english speakers don't have to be pedantic
13:36 lhooq scook0: I thought only 'nd' was allowed on any number
13:36 nothingmuch i used to use the vesa output driver, but it was clunky
13:36 scook0 lhooq: oh, maybe
13:37 scook0 (could be)
13:37 ods15 you quality will not be amazing though :( vidix looks AMAZING on fbdev though
13:37 xinming scook0: I am not distracted... But Just a bit confusing... :-) however, I will go on. ;-)
13:37 ods15 you might want to retry vesa, it's been completely seperated now and is now an extrnal lib and tools
13:37 nothingmuch QtPlatypus: what you should do for that example is instead of lazily reading $news, say '**<$news>' for now
13:37 nothingmuch or '<$news>' without it
13:37 nothingmuch and drop the for
13:37 ods15 (in cvs just like a few days ago, see mplayerhq.hu news)
13:37 scook0 lhooq: S05 implies that they are interchangeable
13:38 lhooq scook0: yes, just seen
13:38 nothingmuch my @artical <== grep { True .. /^.$/ } <$news>; # currently lazy
13:38 nothingmuch my @artical <== grep { True .. /^.$/ } **<$news>; # currently strict
13:38 nothingmuch my @artical <== grep { True .. /^.$/ } =<$news>; # explicitly lazy
13:38 nothingmuch ** is explicitly, btw
13:38 * scook0 goes to get some sleep
13:38 scook0 has quit IRC ("Leaving")
13:38 nothingmuch ods15: no reason to nowadays
13:38 ods15 btw - that's MY monitor - http://mplayerhq.hu/homepag​e/images/shot-cvidix-02.jpg
13:38 nothingmuch i've laptop screen is much better than TV
13:38 nothingmuch and widescreen too
13:38 ods15 that's vidix on framebuffer, coolest/pretiest thing i've ever seen
13:39 QtPlatypus nothingmuch: When you said "strict" you mean "eager"?
13:39 ods15 ah, yes, your laptop is awesom.. what do you use, xv or some native macos thing?
13:39 nothingmuch QtPlatypus: yes, they're the same
13:39 QtPlatypus Great
13:39 ods15 quartz, that was it
13:39 nothingmuch ods15: 'quartz' is the mplayer default output, which gets sent to what they call 'quartz extreme'
13:39 nothingmuch which is basicsally "the windowing system compiled for your GPU"
13:39 ods15 they = mac?
13:39 nothingmuch yeah
13:40 ods15 heh
13:40 nothingmuch ars technica had a nice article, let me find it
13:40 nothingmuch http://arstechnica.com/rev​iews/os/macosx-10.4.ars/14
13:40 ods15 does xv work on mac?
13:41 ods15 it should if mac is X compliant... (it is, right?)
13:41 nothingmuch ods15: there is an X11 server shipped
13:41 nothingmuch it is on top of quartz
13:41 nothingmuch but it doesn't have xv
13:41 nothingmuch not that I care
13:41 ods15 oh
13:41 nothingmuch you can run X11 separately
13:41 ods15 you mean, the native screen is not X?
13:41 nothingmuch and then it might support XV, i have no idea (look at GNU darwin)
13:41 nothingmuch no, it's something completely different
13:41 nothingmuch it's a vector based system
13:41 nothingmuch based on a subset of PDF
13:42 ods15 lol
13:42 ods15 gnu darwin?
13:42 ods15 isnt darwin the (propiatery) mac kernel?
13:42 nothingmuch no
13:42 nothingmuch darwin is opensource
13:42 nothingmuch the kernel is freebsd + mach + some other stuff
13:43 nothingmuch MacOSX is darwin + propietry drivers + windowing system, libraries, UI, and bundled software
13:43 ods15 only the ui is closeD?
13:43 nothingmuch gnu darwin uses X11 (i guess, never used it)
13:43 nothingmuch yep
13:43 ods15 mac os x is freebsd style?
13:43 ods15 whats darwin?
13:43 nothingmuch darwin is: NextSTEP userland (gnu + bsd, leaning towards GNU)
13:43 nothingmuch with the XNU kernel which is mostly a port of freebsd for POSIX stuff
13:44 nothingmuch and mach microkernel for hardware stuff and IPC
13:44 ods15 i thought darwin was the mac kernel...
13:44 nothingmuch no, darwin is the opensource operating system that macosx is built on top of
13:44 ods15 oh. close enough.
13:44 ods15 coreutils etc.?
13:44 nothingmuch not really
13:45 nothingmuch kernel = %3 of code, maybe
13:45 nothingmuch =P
13:45 nothingmuch http://developer.apple.com/darwin/
13:46 nothingmuch think of darwin as 'GNU/Linux'
13:46 nothingmuch and of xnu (the darwin kernel) as linux
13:46 nothingmuch and of MacOSX as 'GNU/Linux/KDE'
13:46 nothingmuch or something like that
13:46 ods15 ah
13:46 nothingmuch only closed source
13:46 nothingmuch (the KDE part)
13:47 ods15 so, umm, darwin exists regardless of macosx?
13:47 nothingmuch yes
13:47 nothingmuch every osx isa darwin
13:47 nothingmuch but not the other way
13:47 nothingmuch there's also some more opensource stuff: safari, the osx browser is based on KDE's KHTML engine
13:48 ods15 mac has been using gnu darwin for while now?
13:48 nothingmuch the quicktime streaming server is available for darwin, if i recall correctly
13:48 svnbot6 r6406 | fglock++ | * perl5/ Code - pass all tests
13:48 nothingmuch no, apple develops darwin
13:48 ods15 isn't khtml lgpl?
13:48 nothingmuch gnu darwin is a distribution of darwin, with linux-ish semantics (x11, kde, etc)
13:48 nothingmuch i don't know, it might be
13:48 nothingmuch but apple's webkit/safari are opensource
13:48 QtPlatypus ods15: Darwin is under the BSD licence iirc.
13:48 nothingmuch and they contribute back to KHTML (mostly speed improvements)
13:48 ods15 ah, when you want the open part of mac on your system... is it portable (cpu-wise)?
13:49 nothingmuch ods15: yes, it runs on x86 and ppc
13:49 ods15 khtml is lgpl i'm pretty sure, how can mac be using it then
13:49 ods15 oh, i just noticed what you said, more open source stuff
13:49 nothingmuch it's even designed for portability... Mach-O (the moral equiv of ELF) supports multi arch binaries
13:49 nothingmuch lgp is permissive
13:49 nothingmuch lgpl
13:50 nothingmuch you can use lgpl code in propietry code, you simply can't claim it's yours
13:50 nothingmuch you can link to it and whatnot
13:50 ods15 not so permissive that you can take it and close it :) i thought that's what you meant...
13:51 ods15 btw, i realized something weird.. can you take a gpl library, make a lgpl "library" which is nothing but a ton of function call wrappers, and then make a closed source program that links against that against that?
13:51 nothingmuch on the server front, OSX server has lots of opensource stuff with a propietry mangament gui... ldap, samba, bind, postfix, cyrus imap
13:51 nothingmuch ods15: no, you're not allowed to link GPL code with closed code
13:52 ods15 heh
13:52 ods15 mac just about is the best of both worlds, it's funny that regarding popularity, they are actually LOOSING in both worlds...
13:52 ods15 probably cause of over expensive
13:53 nothingmuch ods15: not so... OSX is the most deployed UNIX platform in the world =)
13:53 ods15 really?
13:53 nothingmuch it is not growing as fast as linux nowadays though
13:53 nothingmuch yup, more than all of them combined
13:53 nothingmuch israel is not representative
13:53 ods15 i think linux is more popular.. including servers that is?
13:53 nothingmuch but given the fact taht since OSX came out apple has quadrupled it's market share or so...
13:54 nothingmuch ods15: no
13:54 nothingmuch ods15: osx + osx server is more than the sum of all linux workstations, pcs, laptops, servers, hpux, aix, sun, etc
13:54 nothingmuch but that's not saying much... windows is more than those combined too
13:54 ods15 hehe
13:54 ods15 no seriously, in servers and such, macosx is more popular than linux?
13:55 ods15 i find that odd
13:55 nothingmuch anyway, if linux distros ever get as "just working" as OSX i'll switch without losing a breath
13:55 nothingmuch no, osx server is not more popular than linux servers
13:55 hexmode has joined #perl6
13:55 ods15 i thought linux is 2nd place regarding servers
13:55 nothingmuch but osx PCs are muich more than linux servers and PCs
13:55 ods15 oh.. that kinda makes sense
13:55 nothingmuch osx server is a lan type thingy, like a windows PDC
13:55 nothingmuch there's no real advantage in using it for a webserver, or something like that
13:55 ods15 it's REALLY sad that windows is 1st place regarding SERVERS
13:56 nothingmuch but as a file/directory server it's pretty decent
13:56 nothingmuch ods15: well, the battle is doomed for microsoft
13:56 ods15 ?
13:56 nothingmuch because whether or not they're winning right now, linux is getting better and cheaper
13:56 nothingmuch at a constant rate
13:56 nothingmuch and at some point enough effort will be invested, and this effort isn't lost very easily
13:56 ods15 you obviously haven't seen what's going on in israeli uni's and army :(
13:57 nothingmuch that's not my argument
13:57 nothingmuch in the next 30 years microsoft will write and trash N OSs
13:57 nothingmuch linux based OSs will write and trash M > N os distributions
13:57 ods15 everyone i know here won't touch linux with a 2km pole
13:57 nothingmuch but linux based ones will have much more to copy and steal from
13:58 nothingmuch and eventually enough good code will be preserved that you have things that are stable, fast, and just work
13:58 nothingmuch because it doesn't cost anything to steal this knowlege
13:58 nothingmuch interest *is* mounting and there are more and more developers
13:58 ods15 i think i have an ear infection :(
13:58 QtPlatypus nothingmuch: But it does cost to steal the code.
13:59 ods15 nothingmuch: btw, regarding last statement, just bout all developers i know are "in love" with C#
13:59 nothingmuch QtPlatypus: it costs O(1) to steal the code, in programmer time
13:59 nothingmuch it costs O(N) to steal the code when you pay licensing fees
13:59 nothingmuch and I don't mean for the developers, I mean for the developers and the community
14:00 nothingmuch linux's price/benefit ratio is getting better, microsoft one's may, but it'll have to stop improving at some point, or they will go bankrupt
14:00 nothingmuch brb
14:00 ods15 heh
14:00 ods15 cya
14:01 nothingmuch back
14:02 nothingmuch anyway, my point is - linux will not get worse
14:02 ods15 fast
14:02 nothingmuch if it does it'll be forked (xfree anyone?)
14:02 nothingmuch where it is 'linux the kernel', or 'distro x'
14:02 nothingmuch look at what ubuntu did to debian in terms of idiot usability
14:03 nothingmuch all the knowlege they acquired is open and accessible
14:03 ods15 i've actually seen quite a few aspects where linux is getting worse, not better :( can't think of any off top of my head
14:03 nothingmuch gentoo can steal their fixes
14:03 nothingmuch but not what they did wrong
14:03 nothingmuch and vice versa
14:03 ods15 forking is part of the problem
14:03 nothingmuch microsoft doesn't have that because there is a schism between the customer and the programmer
14:03 ods15 the developer has to deal with so much crap regarding portability it's insane
14:03 nothingmuch ods15: don't think over a 5 year scale
14:03 ods15 its driving developers away
14:04 nothingmuch i'm talking about 20-30 years from now
14:04 ods15 hmm
14:04 ods15 hard to think that far
14:04 nothingmuch i claim that linux has the ability to progress faster than microsoft, and to accelerate this progression faster than microsoft
14:04 nothingmuch and that opensource in general is more scalable
14:04 nothingmuch on a world wide basis
14:04 QtPlatypus nothingmuch: Appart from emacs, and BSD has there been any majour projects that have forked?
14:04 ods15 by then all earth could be blown to bits by some atomic rocket :P
14:05 nothingmuch QtPlatypus: xfree/xorg forked for licensing issues
14:05 ods15 QtPlatypus: X
14:05 nothingmuch ubuntu span off debian
14:05 ods15 mplayer-mplayerxp, though it's not that big :P
14:05 nothingmuch gentoo "forked" the other distros but started over again
14:05 nothingmuch but they all have the same packages and usability, just slightly different
14:05 CaptainMorgan has joined #perl6
14:05 nothingmuch knowlege about what is the right and best thing is accumilating, even if no one can really say what it is
14:06 CaptainMorgan what's better, perl or php ? and what is perl, specificly, used for?
14:06 nothingmuch CaptainMorgan: perl is better for everything than any other language in the world
14:06 nothingmuch and it's used to make sushi
14:06 ods15 he he he
14:06 ods15 COFFEE you fool
14:06 nothingmuch by automating the sushi maker peripheral
14:06 CaptainMorgan I can't grasp php, in the limited time I have.. and no one in its channel is caring :)
14:06 * ods15 slaps nothingmuch over the head
14:06 ods15 "you sound like a damn fool when you say it wrong!"
14:06 CaptainMorgan damn, thought it was used to make rum
14:07 nothingmuch CaptainMorgan: you can't learn a programming language in the time that it takes to get a response on a channel
14:07 nothingmuch what's your real dillema?
14:07 nothingmuch ods15: coffee is trivial to make
14:07 nothingmuch sushi, OTOH has mary varieties, and is quite a task
14:07 ods15 tell that to proffessional coffee makers
14:07 QtPlatypus CaptainMorgan: You most likely wish to ask in the #perl channel.  #perl6 is a totally unrelated thing.
14:07 ods15 ones that make an art out of it
14:07 nothingmuch ods15: tell that to professional sushi chefs
14:08 particle_ has left
14:08 nothingmuch " "
14:08 CaptainMorgan i need a page done before school in sept. probably the only page that that'll ever give me the mos trouble, feeback. I have 98% of it done, validation is where Im hurting
14:08 ods15 btw, name that quote
14:08 nothingmuch ods15: Dave
14:08 ods15 you really otta know it
14:08 CaptainMorgan everything works and functions smoothly, except validation
14:08 ods15 was that his name? damn i can't even remember
14:08 ods15 no, it wasn't dave...
14:08 nothingmuch CaptainMorgan: well, in that case you ought to reinsall "validation"
14:08 nothingmuch ods15: i didn't say it was, i said it is
14:09 nothingmuch i named the quote dave
14:09 CaptainMorgan resintall?
14:09 nothingmuch CaptainMorgan: i'm not serious
14:09 CaptainMorgan :)
14:09 nothingmuch you have to give us more info than that
14:09 ods15 nothingmuch: lol
14:09 ods15 17:06:50 <ods15> "you sound like a damn fool when you say it wrong!" - where is this quote from
14:09 ods15 17:06:42  * ods15 slaps nothingmuch over the head
14:09 ods15 including that part
14:09 nothingmuch i don't know
14:09 ods15 bah, shame on you
14:09 ods15 BIFF!
14:10 nothingmuch biff?
14:10 nothingmuch whihch biff?
14:10 ods15 the old one, slapping the young one
14:10 ods15 from bttf
14:10 CaptainMorgan Id like to know, aftering hitting submt after leaving the fields blank, does he make the error highlighting work: http://jeffhowden.com/code/css/forms/
14:10 nothingmuch CaptainMorgan: please describe: a. what you want to get, b. what you have, c. how you want to get there
14:10 * QtPlatypus nods to nothingmuch "Point taken"
14:10 ods15 "so why don't you make like a tree, and get out of here" *slap* "'leave' you idiot! make like a tree, and 'leave'! you sound like a damn fool when you say it wrong"
14:11 CaptainMorgan i wish for a similar highlighting error effect
14:11 nothingmuch CaptainMorgan: by making a <div> and writing an <img> in there
14:11 nothingmuch and styling it
14:11 nothingmuch but it has  nothing to do with either perl or php
14:11 CaptainMorgan k, i realize im not givin enough enough
14:11 CaptainMorgan info
14:11 nothingmuch ods15: bttf?
14:11 ods15 yes!
14:11 nothingmuch what is bttf?
14:12 ods15 you obviously don't know your movie/tv basics :(
14:12 ods15 back to the future
14:12 CaptainMorgan one page, for html, and php. then I source to another php  for the form action
14:12 nothingmuch ah, i've never seen it
14:12 nothingmuch CaptainMorgan: that is not saying much more than how your files are organized
14:12 CaptainMorgan layout and highlighting is all designed, it's gettiting to fucntion
14:12 nothingmuch i need to know:
14:12 nothingmuch what is the data
14:12 ods15 shame on you
14:12 nothingmuch what is the structure
14:12 nothingmuch what is the flow of logic
14:12 nothingmuch what decisions your php is making
14:12 QtPlatypus CaptainMorgan: I strongly suggest that you ask in a PHP or a web authoring channal.
14:12 nothingmuch then I can helpl you
14:13 CaptainMorgan QT: for days now
14:13 nothingmuch CaptainMorgan: you need to post some code which isn't working, or describe exactly what you have and ask us how we would transform it (e.g., ask for advice)
14:13 QtPlatypus CaptainMorgan: Then perhaps your not asking the right questions.
14:13 CaptainMorgan Ive tried rearranging everything about the logic... put the validation at the top, the middle, bottom, split.
14:13 nothingmuch but not "how do i do this?"
14:13 nothingmuch because all we can say is "like that"
14:13 nothingmuch CaptainMorgan: that's nonsensical
14:13 xinming hmm, ^^ $$ and ^ $ a bit confusing, any example?
14:13 nothingmuch data goes in
14:14 nothingmuch it gets verified
14:14 nothingmuch html goes out
14:14 CaptainMorgan understood, but where do you want me to post code?
14:14 CaptainMorgan it's a big chunk
14:14 nothingmuch CaptainMorgan: i don't want you to post your code right now, it won't help
14:14 nothingmuch for future reference:
14:14 nothingmuch perlbot: nopaste?
14:14 perlbot Paste your code here and #<channel> will be able to view it: http://sial.org/pbot/<channel>
14:14 CaptainMorgan perbot!!!
14:14 nothingmuch CaptainMorgan: do you grasp the way data moves around the application?
14:14 CaptainMorgan sure
14:15 nothingmuch the html form describes to the browser how to display things
14:15 CaptainMorgan yep
14:15 xinming "xyz\nabcdefg\nabc" will the /^^.+/ match the full string? including \n?
14:15 nothingmuch the submit button makes the browser send the data over to where the form told it to send it
14:15 nothingmuch the php script runs
14:15 nothingmuch the data is looked at
14:15 nothingmuch and decisions about the data are made
14:15 nothingmuch after which there is output
14:15 CaptainMorgan hold up, ill get the code.. perlbot, don't know where that page has been for the last week.. thank you
14:15 SM_ax has quit IRC ("ChatZilla 0.9.61 [Mozilla rv:1.7.8/20050513]")
14:16 nothingmuch and the html you print out is what the browser will show the user
14:16 CaptainMorgan understand all that nm.. albeit, not proficiently, but alright
14:16 nothingmuch validation has nothing to do with the way the form is displayed
14:16 nothingmuch but if you validate the data
14:16 nothingmuch and then based on the results of the validatioon print HTML for the situation
14:16 nothingmuch for example, on failure, HTML that says "pleas re-enter your password" when the validation failed because there was no passworod, is logical
14:17 nothingmuch validation on the top, bottom, or split across the file, magically adding HTML that makes things colorful and snazzy is not logical
14:17 justatheory has joined #perl6
14:17 pasteling "CaptainMorgan" at 68.170.154.214 pasted "//Validation Code // Create an" (27 lines, 1.2K) at http://sial.org/pbot/12660
14:17 CaptainMorgan awesome..
14:17 nothingmuch CaptainMorgan: wherever you copied that from, it doesn't matter
14:18 nothingmuch what you need to understand is what do you have before this chunk of code runs
14:18 nothingmuch and what you expect to have after this chunk of code runs
14:18 nothingmuch do you know *exactly* what those will be?
14:18 CaptainMorgan where it says insert processing code here
14:18 nothingmuch no
14:18 CaptainMorgan yea, before it - everything runs smoothly, and I understand it
14:18 CaptainMorgan i wrote it
14:19 nothingmuch CaptainMorgan: okay, so explain what is before it
14:19 nothingmuch and explain what you want to get out of it
14:21 xinming hmm, anyone here would explain ^^ $$ and ^ $ for me please? :-S
14:21 CaptainMorgan well, at the very top is variable setting. then, i have a few functions.. some of which call to the above variables. This page is sourced from the main form page. I used if and else, switch for radio button and email processing.. now, Ive tried splitting up this code that I pasted is so many ways around the main code so many times Ive lost count
14:21 nothingmuch xinming: ^ means "begining of string"
14:21 nothingmuch $ means "end of string"
14:21 nothingmuch ^^ means "begining of line"
14:22 xinming nothingmuch: Ok, clear enough... ;-)
14:22 nothingmuch as opposed to perl 5, where "^" meant begining of line, except when you used the /s switch, when it meant begining of string
14:22 kgftr|konobi \A and \Z were the perl5 equivalents
14:22 PerlJam nothingmuch: "meant"?  Already referring to perl5 in the past tense?  ;-)
14:22 xinming nothingmuch: I know what does /s and /m do, But as I read Synopsis, It sometimes refer to string and sometimes refer the line...
14:22 nothingmuch PerlJam: heh... sorry =)
14:23 nothingmuch \a and \Z, no?
14:23 nothingmuch or \A and \z
14:23 xinming ^^ and $$ match line beginnings and endings. (The /m modifier is gone.) They are both zero-width assertions. $$ matches before any \n (logical newline), and also at the end of the string if the final character was not a \n. ^^ always matches the beginning of the string and after any \n that is not the final character in the string.
14:23 PerlJam nothingmuch: \A and \z match at the beginning and end of string respectively in perl5
14:23 nothingmuch what's the lowercase then?
14:23 kgftr|konobi one will include newline, the other won't
14:24 nothingmuch           \A  Match only at beginning of string
14:24 nothingmuch           \Z  Match only at end of string, or before newline at the end
14:24 nothingmuch           \z  Match only at end of string
14:24 nothingmuch right
14:24 PerlJam \a ?  That's the bell (alarm)
14:24 nothingmuch ^ = \A
14:24 nothingmuch $ = \z
14:24 xinming that's what I confused about...
14:24 nothingmuch ^^ = ^ without /s
14:24 nothingmuch $$ = $ without /s
14:24 kgftr|konobi nothingmuch: not in m!!gms mode
14:24 Juerd In Perl 5, $ is \Z, not \z
14:25 kgftr|konobi in perl 5 $ is $
14:25 kgftr|konobi *slap*
14:25 PerlJam heh
14:25 nothingmuch isn't \Z like /$/m ?
14:25 kgftr|konobi yup
14:25 Juerd No, /$/ without /m is like /\Z/ with or without /m
14:25 nothingmuch okay, so is perl 6's $ is not /$/s or not?
14:25 nothingmuch ah
14:25 kgftr|konobi but $ in perl5 always refers to line NOT string
14:25 Juerd Perl 6's $ is Perl 5's \z
14:26 * nothingmuch almost always uses /s because it's too confusing
14:26 Juerd kgftr|konobi: Depends on whose explanation you use. If you use mine, then yes. But Damian disagrees.
14:26 nothingmuch CaptainMorgan: do you understand what needs to happen for it to work, and what the validation code is doing?
14:26 Juerd nothingmuch: /s does absolutely nothing to anchors.
14:26 Juerd nothingmuch: /s only makes . include \n
14:26 nothingmuch Juerd: right
14:27 kgftr|konobi i had a lovely regex with lookahead, negative lookahead, positive lookbehind and /gms all rolled in one recently
14:27 nothingmuch in which case ^.*$ means 'the whole string'
14:27 Juerd nothingmuch: Only because * is greedy.
14:27 kgftr|konobi well.. /m changes the anchors
14:28 pasteling "nothingmuch" at 212.143.92.226 pasted "/m vs /s" (5 lines, 197B) at http://sial.org/pbot/12663
14:29 nothingmuch i think you're wrong, Juerd
14:29 nothingmuch but not completely wrong
14:29 Juerd I'm right.
14:29 nothingmuch because $ is not \z
14:29 nothingmuch then I'm misunderstanding
14:29 nothingmuch howcome the first one doesn't match 'foo'?
14:30 nothingmuch i'm using .*? not .*
14:30 CaptainMorgan validation is taking given values and testing them against already set values to determine elibility? and notfiying and preventing some typos, or attempts
14:30 Juerd Because it needs (?=\n)?\z
14:30 Juerd eh
14:30 nothingmuch CaptainMorgan: what do you make of the notification?
14:30 Juerd Because it needs (?=\n?\z)
14:30 Juerd Which is what $ is, if there is no /m
14:31 nothingmuch oh, okayh
14:31 nothingmuch i see...
14:31 nothingmuch in that case /s sanifies . for me
14:31 CaptainMorgan sorry, notification?
14:31 nothingmuch so that I can use $ like I mean
14:31 nothingmuch which is chomping \z
14:31 Juerd Just don't for a second think that /s does anything to $.
14:31 nothingmuch CaptainMorgan: you used that verb, "... and notifying..."
14:31 CaptainMorgan is there a bot for other channels too?
14:31 nothingmuch Juerd: thanks
14:31 Juerd It's the greediness of * combined with the \n matching of . that does what you want.
14:32 CaptainMorgan well, allerting the user to mistakes
14:32 PerlJam Juerd: /s was mnemonically a poor choice (as was the description of "treat RE as a single line")
14:32 nothingmuch CaptainMorgan: yes, how does it do that?
14:32 Juerd PerlJam: Agreed.
14:32 nothingmuch PerlJam: yeah, i think that's where my feeling came from
14:32 nothingmuch either way, i almost never use /m
14:32 kgftr|konobi $foo = "foo\nnoo\nboo\nloo"; $foo =~ s/^o(?!\z)$/e/gms;
14:32 nothingmuch and I always feared that // is a bit like //m
14:33 nothingmuch and I guess that was moot
14:33 feroz has joined #perl6
14:33 Juerd nothingmuch: Perhaps strengthened by that // is m// :)
14:33 CaptainMorgan direction, an what I stated above - testing. but after it's done, it stays along a set path, whichever written
14:33 Juerd Not m//m though
14:33 nothingmuch Juerd no
14:33 nothingmuch the fact that '$' did not match end of strings sometimes when used in conjunction with .
14:33 feroz Hello
14:33 Juerd In any case, /s is not in any way related to /m
14:33 nothingmuch that made me use it in a cargo cultish way
14:33 nothingmuch use /s
14:33 autark has joined #perl6
14:34 autark is now known as jp-autark
14:34 Juerd nothingmuch: Why did you live with this fear? There's more than enough documentation available that explains these simple thruths
14:34 nothingmuch it made me think that since . is not matching \n, it's only logical that $ will match
14:34 Juerd truths
14:34 nothingmuch Juerd: i read that early on in my perl life
14:34 nothingmuch and i only realized now that I was wrong
14:34 nothingmuch and it didn't stop me =)
14:34 nothingmuch because almost always I mean //s, or there's no \n in the string
14:35 nothingmuch and if I use //m, then I know what it's doing
14:35 PerlJam nothingmuch: There is a reason that . matches *anything* in perl6  :-)
14:35 Juerd I particularly like the /^$/ test because it saves me a chomp. This is bad laziness.
14:35 PerlJam I sometimes wish that perl5 had gone that route too
14:35 Juerd PerlJam: In Perl 5 terms, Perl 6 always has /sx
14:35 Juerd I like \N
14:36 Juerd It's so universally correct that it's almost wrong again :)
14:36 PerlJam the consistency between  \x and \X as anti-\x is great though
14:49 nothingmuch HTML::Element is silly
14:49 nothingmuch it escapes the xml, without knowing the target encoding
14:49 nothingmuch which causes great breakge and misery
14:50 Odin- has quit IRC (Read error: 104 (Connection reset by peer))
14:50 Odin- has joined #perl6
14:51 feroz Hmm, needed some help
14:52 feroz How would you execute two non-interupt able code at the same time on a perl script?
14:55 nothingmuch feroz: which version of perl?
14:55 svnbot6 r6407 | fglock++ | * perl5/ Code - created hooks for signature type-checking
14:55 nothingmuch what do you mean by non interruptable?
14:55 feroz perl5
14:55 feroz Hmm first is a function listenin to a socket
14:56 nothingmuch $SIG{$_} = "IGNORE" for qw/HUP ALRM INT/; if (fork) { process one } { process two  }
14:56 feroz second is a timer
14:56 nothingmuch sounds like a job for four argument select()
14:56 nothingmuch and sounds like a question for #perl, not #perl6
14:57 feroz Oops, sorry
14:57 renormalist has quit IRC ("using sirc version 2.211+KSIRC/1.3.11")
15:06 Amnesiac has joined #perl6
15:07 feroz Thx again nothingmuch.
15:07 nothingmuch feroz: sure thing
15:07 nothingmuch feroz: you can also use threads, but that will likely have disappointing results
15:07 Juerd 16:50 < nothingmuch> HTML::Element is silly
15:07 nothingmuch or if the socket and the recurring sub don't have to happen in the same process, you can fork
15:07 Juerd nothingmuch: All such modules were designed without the encoding/charset awareness that we have today
15:07 nothingmuch and have one process read, and the other process sleep
15:08 Juerd nothingmuch: Let's hope Perl 6 can change all this in a somewhat uniform way
15:08 nothingmuch Juerd: the problem is that it's 50%/50% - it makes an attempt to handle charsets, but it does it wrong
15:08 nothingmuch *HTML::Element::_xml_escape = sub { }; # did the trick
15:08 nothingmuch so no sweat
15:09 nothingmuch anybody got a quick snippet to escape all vertical whitespace into \n and such?
15:11 * Juerd can't parse it
15:11 nothingmuch i'm printing strings to a log
15:11 nothingmuch and I want to make sure they're sanified
15:12 nothingmuch escaping delimiters, and newlines, I guess
15:12 Juerd Needs it be fully human readable?
15:12 nothingmuch yes
15:12 Juerd Needs it be one line?
15:12 nothingmuch yes
15:13 Juerd Consider quoted printable
15:13 nothingmuch String::Escape seems useful
15:13 nothingmuch but the documentation is a bit ambiguous
15:14 nothingmuch i guess I should just try it =)
15:14 Juerd And file a bug report
15:14 nothingmuch a bug report? what for?
15:15 nothingmuch String::Escape::qprintable is good
15:16 nothingmuch thanks for the magic phrase, Juerd
15:16 Juerd A bug report for the ambiguous documentation
15:16 svnbot6 r6408 | fglock++ | * perl5/ Code
15:16 svnbot6 r6408 | fglock++ |   - Param 'type' is a closure, allowing the use of 'subtype'
15:16 svnbot6 r6408 | fglock++ |   - New methods: .arity, .name
15:16 Juerd Which magic?
15:17 nothingmuch ah
15:17 nothingmuch the string "quoted printable"
15:17 Juerd I see
15:17 Juerd Stuff like that a programmer should just know :)
15:17 nothingmuch as for the bug report - i think it's nitpicking, it's mostly because i'm unfamiliar with the vocab
15:18 Juerd You're experienced with Perl. If you don't understand documentation, the documentation must be wrong.
15:18 nothingmuch and the fact that it's hard to document that stuff unambiguously
15:18 Juerd It's also hard to write bug free code
15:18 nothingmuch Juerd: have a quick look at the docs, if you think they are unclear, i will make a patch
15:18 Juerd But does that refrain you from reporting bugs?
15:18 Juerd I don't have the time atm
15:19 nothingmuch well, I don't like submitting bugs that are just complaints, if I can fix them
15:19 nothingmuch so if i'll submit a bug for this, i'll submit a docpatch too
15:19 Juerd And I'm from before the patches-welcome era
15:19 nothingmuch but I don't know if one is really in order
15:20 Juerd I don't feel sorry for sending patchless reports, and don't think others should
15:20 Juerd In fact, I have yet to accept any patch unmodified myself.
15:20 nothingmuch ride is leaving, ciao
15:20 Juerd Bye
15:20 nothingmuch thanks again!
15:21 Juerd Yw
15:24 vcv- has quit IRC (Read error: 110 (Connection timed out))
15:29 xinming It's just plain cool, that's why.  Oh, and Perl 6 then magically
15:29 xinming runs inside every vaguely recent web browser.
15:30 xinming anyone here can tell me what does this mean?
15:30 xinming will perl 6 be converted into JavaScript? :-S
15:30 luqui xinming, yes
15:30 Juerd Yes, PIL2JS works so well that Parrot won't be used :)
15:31 xinming luqui: hmm, do you mean the source code?
15:31 luqui no, Perl 6 will be *compiled* to javascript
15:31 luqui just as you can compile Perl 5 to bytecode
15:31 luqui javascript is just a very funny looking bytecode :-)
15:32 xinming luqui: hmm, But I ever thought, Java and JavaScript is quite different thing
15:32 luqui yes they are
15:32 luqui who ever said anything about java?
15:32 luqui look at PIL2JS in the pugs rep
15:32 luqui repository
15:33 * luqui is off to school
15:33 * luqui &
15:34 fglock has left "Fui embora"
15:41 nothingmuch has quit IRC (Read error: 110 (Connection timed out))
15:43 hexmode has quit IRC (Remote closed the connection)
15:45 Maddingue__ has joined #perl6
15:50 pdcawley has joined #perl6
15:51 dudley has joined #perl6
15:58 Maddingue has quit IRC (Read error: 110 (Connection timed out))
16:03 xinming `/ <before pattern> / # was /(?=pattern)/` What does this mean please?
16:03 xinming found in S05
16:05 xinming hmm, I found the answer. :-)
16:06 saorge has joined #perl6
16:18 fglock has joined #perl6
16:33 umbop has quit IRC ("Leaving")
17:00 jhorwitz has joined #perl6
17:01 feroz has quit IRC (Read error: 104 (Connection reset by peer))
17:05 iblechbot_ has quit IRC (Read error: 110 (Connection timed out))
17:08 hexmode has joined #perl6
17:08 svnbot6 r6409 | fglock++ | * perl5/ Code
17:08 svnbot6 r6409 | fglock++ |   - refactored internal classes
17:08 svnbot6 r6409 | fglock++ |   - Added 'default' parameter hook
17:08 svnbot6 r6409 | fglock++ |   - Added required/optional parameters
17:08 xinming ?eval ?100
17:08 evalbotzy bool::true
17:08 xinming ?eval +100
17:08 evalbotzy 100
17:09 xinming ?eval my $t = 100; $t ~~ m,100,;
17:09 evalbotzy pugs: src/events.c:270: init_events_first: Assertion `rc == 0' failed.
17:09 xinming ?eval my $t = 100; $t ~~ m/100/
17:09 evalbotzy pugs: src/events.c:270: init_events_first: Assertion `rc == 0' failed.
17:12 lhooq has quit IRC ("(this quit message left intentionally blank)")
17:13 Maddingue__ is now known as Maddingue
17:14 kolibrie xinming: that might be an evalbot problem, those expressions work for me in command-line pugs
17:18 Amnesiac has quit IRC (Read error: 110 (Connection timed out))
17:18 xinming kolibrie: by the way, can I add a + before m/.../ ? just like +m/.../
17:18 xinming I wish it to be forced into numeric context
17:22 meppl has joined #perl6
17:23 kolibrie xinming: I'm pretty hazy with the syntax there, but that doesn't sound right
17:23 kolibrie xinming: you want the number of matches it finds for that string?
17:24 xinming kolibrie: hold on
17:25 xinming In numeric context it evaluates to the number of matches:
17:25 xinming yes, But, the example just shows on += not +
17:26 xinming So, If we wish to change the context, can we use +m/.../
17:26 kolibrie I think another example (not shown) would be:
17:26 kolibrie $match_count += $string ~~ m/pattern/;
17:27 kolibrie oh, maybe the :g is required
17:27 kolibrie to find all the matches
17:29 xinming kolibrie: hmm, Ok, how do about this example?
17:31 xinming my $t = "this is a string"; "The result of match { $t ~~ m/is/ }".say ;
17:31 svnbot6 r6410 | fglock++ | * perl5/ Code
17:31 svnbot6 r6410 | fglock++ |   - Added 'slurpy' parameter
17:31 svnbot6 r6410 | fglock++ |   - Compatible with Perl 5 scalar/list context
17:31 xinming kolibrie: so, How do we force the context of "$t ~~ m/is/" ?
17:32 xinming maybe scalar, maybe bool.
17:32 kolibrie xinming: I'm guessing that you put a '+' in front of $t
17:32 kolibrie xinming: but maybe not
17:33 xinming kolibrie: in fact, If the default match string is $_, so we can use $_ = $t; and then {m/is/}
17:33 xinming hmm, I am not sure...
17:33 xinming Synopsis doesn't cover much.
17:34 kolibrie you might need to capture the match object in a variable, and put a + in front of that
17:34 kolibrie true, the synopsis is kind of light when it comes to rules
17:34 kolibrie and, not up-to-date, either
17:36 xinming kolibrie: Ok, I think I got the "exactly" answer... :-)
17:37 xinming we can use +$t.match( / / )
17:37 xinming ;-)
17:40 PerlJam What are you trying to do?
17:40 xinming PerlJam: force the context for the match result...
17:41 xinming $match_count += m:g/pattern/;
17:41 xinming # In numeric context it evaluates to the number of matches:
17:41 xinming But the problem is out, It use += here, Some times, we might not need to pass value to a $var.
17:41 xinming so, If we can use +m,/.../
17:42 PerlJam yes, you should be able to do that.
17:42 Limbic_Region has joined #perl6
17:43 PerlJam (assuming you meant +m:g/.../ again)
17:43 xinming # In string context it evaluates to $0, the entire matched string:
17:43 xinming    print %hash{"{$text ~~ /<?ident>/}"};
17:43 xinming    # or equivalently:
17:43 xinming    $text ~~ /<?ident>/  &&  print %hash{~$/};
17:44 xinming PerlJam: Thanks for your clarification.
17:44 xinming hmm, I wonder, for the second example...
17:44 xinming Why It will default pass to %hash?
17:44 PerlJam And I believe that it isn't "g" anymore, but rather "e"  for "every"  (or something like that)
17:45 xinming as the key name "~$/"
17:45 xinming or, every %hash will get the pair ( ~$/ => "$matched" ) ?
17:46 xinming will it act like multi sub here?
17:46 xinming bbl, go to shit... :-)
17:54 xinming hmm, so anyone would help?
17:57 iblechbot has joined #perl6
17:58 * xinming goes to restart gnome...
17:59 xinming has quit IRC ("I really love GNU")
18:02 xinming has joined #perl6
18:12 mjl69 has joined #perl6
18:17 vcv- has joined #perl6
18:23 fsweetser has joined #perl6
18:34 dduncan has joined #perl6
18:38 rm-r has joined #perl6
18:39 rm-r hi, how can i initialize the size of a vector? (declaring it is big x)
18:40 rgs has joined #perl6
18:41 * Khisanth checks the channel name
18:41 Khisanth what sort of vectors are you talking about? :)
18:42 rm-r hum arrays sorry
18:42 rm-r @array
18:43 * ods15 deletes rm-r
18:43 ods15 or unlinks
18:43 ods15 whatever
18:43 rm-r ?
18:43 ods15 <somebody> how do you delete an entire directory in unix?    * rm-rf doesn't know...
18:44 rm-r eheh :)
18:44 ods15 search for that in bash.org :P
18:48 xinming what's [ ] used for in rule?
18:49 xinming hmm, Syn Says it's non-capturing.
18:49 xinming what does it mean please?
18:49 mjl69 has quit IRC (Read error: 110 (Connection timed out))
18:49 xinming s/non-capturing/non-capturing group/
18:51 Juerd Perl 6's [] is Perl 5's (?:)
18:52 rm-r has left "Sto andando via"
18:53 kolibrie xinming: so you can say m/[this|that]/, without 'this' or 'that' being trapped in $0, $1
18:54 xinming kolibrie: It will still match, but don't capture the match, right?
18:54 kolibrie correct, it just doesn't get added to the match object under $0, $1, etc.
18:55 xinming ;-)
18:55 xinming # In string context it evaluates to $0, the entire matched string:
18:55 xinming    print %hash{"{$text ~~ /<?ident>/}"};
18:55 xinming    # or equivalently:
18:55 xinming    $text ~~ /<?ident>/  &&  print %hash{~$/};
18:55 xinming how about this example?
18:56 xinming will ~$/ inserted into "every" %hash ( %a, %b, %c... etc ) in the current block?
18:57 xinming I thought It's a bit like multi sub, But I really don't know if I am right.
18:57 kolibrie no, %hash is an ordinary hash that was defined previously
18:58 kolibrie in this example, we are pulling out a value from the hash based on what matched
18:58 kolibrie in the rule
18:58 kolibrie and $0 isn't the entire matched string any more
18:59 rgs quick question... isnt "while =$fh" supposed to populate $_ ?
18:59 xinming kolibrie: hmm, I think I need to think more.
19:00 xinming rgs: =$fh just do `$_ = $fh[$itator]`
19:02 rgs xinming: and why don't I see a value in $_ when doing while =$fh { say } ?
19:04 xinming rgs: because the by default, `while =$fh` will automatically pass one "piece" into $_
19:04 xinming ?eval my @ary = (1, 2, 3, 4); while =@ary { $_.say };
19:04 evalbotzy Error: Can't use readline() or getc() in safemode.
19:04 xinming ?eval my @ary = (1, 2, 3, 4); while @ary { $_.say };
19:04 xinming oops.
19:04 evalbotzy perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6 perl6
19:04 xinming ....
19:05 xinming is it a bug?
19:05 xinming ?eval my @ary = (1, 2, 3, 4); while @ary { say };
19:05 evalbotzy                                                                                                                                                                                                                                                                                                                                                                                                                                                                
19:05 xinming rgs: hold on please.
19:05 ods15 xinming: FOR
19:05 rgs you're welcome.
19:05 ods15 fool
19:05 xinming oops
19:05 xinming for...
19:05 xinming ?eval my @ary = (1, 2, 3, 4); for @ary { say };
19:06 evalbotzy    undef
19:06 xinming ?eval my @ary = (1, 2, 3, 4); for @ary { $_.say };
19:06 evalbotzy 1 2 3 4 undef
19:06 PerlJam yeah, just remember to use "for" where you would have used "while" in perl5 and you'll do good.
19:06 ods15 PerlJam: uh, it was for() in 5 too\
19:06 ods15 that code was wrong in 5 too, infinite loop
19:07 xinming ?eval my @ary = (1, 2, 3, 4); for @ary -> $_ { $_.say };
19:07 evalbotzy 1 2 3 4 undef
19:07 xinming ?eval my @ary = (1, 2, 3, 4); for @ary { say };
19:07 evalbotzy    undef
19:07 ods15 the undef thing aint right though
19:07 PerlJam ods15: The primary iterator in perl 5 was <> and it was almost always used with "while".  This changes in perl 6
19:07 xinming why doesn't say default use $_ ?
19:07 xinming ods15: yes, that's what I normally do in perl 5.
19:08 ods15 PerlJam: thats wrong though... you used while with <>, which DOES make sense, but you use for with @arr
19:08 xinming rgs: Sorry, you can use while =$fh here. must use for
19:08 ods15 <> and @arraretotally different here
19:08 PerlJam ods15: sure, but this started with unary =
19:08 ods15 <> and @arr are totally different here
19:08 xinming rgs: I remember wrong... maybe carelessly maybe foolishly... God knows...
19:08 ods15 ?
19:09 ods15 for(<>) doesnt make any sense
19:10 xinming ($key, $val) = @$result; will this be the same as ( $key, $val ) = @{$result} ?
19:10 ods15 ohhhhhhh, the undef is the result of the whole expression :)
19:10 PerlJam rgs was asking about the perl6 equivalent to perl5's   while (<$fh>) { ... }  and asked why  while =$fh { ... } didn't work.  The answer is to use "for" in perl6 where you would have said "while" in perl5
19:10 ods15 ?eval my @ary = (1, 2, 3, 4); for @ary { say }; 5
19:10 evalbotzy    5
19:10 ods15 ?eval my @ary = (1, 2, 3, 4); for @ary { say $_ }; 5
19:10 evalbotzy 1 2 3 4 5
19:10 ods15 :)
19:10 ods15 ?eval my @ary = (1, 2, 3, 4); for @ary { print }; 5
19:10 evalbotzy 5
19:11 xinming say and print won't take $_ anymore, It's a bug.
19:11 rgs ok thanks, I now remember that damian mentioned that for =$fh ought to be lazy
19:11 rgs is it actually lazy in pugs BTW ?
19:11 xinming well, maybe...
19:11 ods15 ?eval my @ary = (1, 2, 3, 4); for @ary { print $_ }; 5
19:11 evalbotzy 12345
19:11 ods15 heh
19:12 xinming ($key, $val) = @$result; will this be the same as ( $key, $val ) = @{$result} in perl 5 please??
19:13 xinming :-S
19:13 ods15 night
19:13 xinming Odin-: night.
19:13 xinming ods15: night.
19:13 ods15 errrrr not Odin-
19:13 xinming ods15: well, wrong completion.
19:16 nothingmuch has joined #perl6
19:16 xinming ???
19:17 xinming -lilo/Wallops- "I lift this clavicle to worlds without ...
19:17 xinming who is he? a server?
19:18 saorge_ has joined #perl6
19:19 nothingmuch evening
19:19 nothingmuch xinming: you must be a robot
19:19 fglock hi nothingmuch
19:19 nothingmuch hi ho
19:20 nothingmuch damnit, work network is down
19:20 nothingmuch oh wait, that's just safari
19:21 saorge__ has joined #perl6
19:22 xinming nothingmuch: ???
19:22 xinming ...
19:22 nothingmuch xinming: whenever I come here you are awake
19:22 nothingmuch and you're in a different time zone
19:22 nothingmuch and I sleep 5 hours a night
19:23 xinming nothingmuch: well, I am not a robot...
19:24 saorge__ has quit IRC (Client Quit)
19:24 saorge__ has joined #perl6
19:25 Khisanth so you say!
19:26 xinming nothingmuch: Now, I didn't get work, So, I can do what I like to do, Just like learning stuff or such... In the past 2 years, I wasted tooo much time, I like computing, But I addict myself to play warcraft III, Now, I know, If I go on with Warcraft III, I might become another Death-Knight... :-)
19:26 nothingmuch xinming: =)
19:31 WildPikachu has joined #perl6
19:34 whiteg has quit IRC (Read error: 104 (Connection reset by peer))
19:34 saorge has quit IRC (Read error: 110 (Connection timed out))
19:34 autrijus_ has joined #perl6
19:34 jhorwitz has quit IRC ("Chatzilla 0.9.67 [Firefox 1.0.4/20050511]")
19:34 autrijus has quit IRC (Read error: 104 (Connection reset by peer))
19:34 autrijus_ is now known as autrijus
19:35 saorge_ has quit IRC (Read error: 110 (Connection timed out))
19:36 WildPikachu has left "Leaving"
19:37 xinming by the way, `my( $s, $t ); $s = "$t"; $t = "xyz"; print $s;` in perl 5, it will give a warn because it's $t is undef, how about perl 6?
19:37 xinming It's said in perl 6, the list is lazy, will the Scalar be "lazy" ?
19:38 iblechbot has quit IRC (Read error: 110 (Connection timed out))
19:40 arcady perl 6 should complain about that too, I think
19:40 xinming arcady: hmm, In fact, I wonder, why perl 6 make "all" things lazy. :-)
19:40 xinming s/why/why not/
19:42 arcady well, you can say that scalars are already lazy
19:42 arcady you don't have to define them until you actually use them
19:44 xinming arcady: But, This example shows, It might be lazy, But not actuall lazy...
19:44 saorge__ has quit IRC (Read error: 110 (Connection timed out))
19:44 xinming my( $s, $t ); $s = "t now is: $t"; $t = "xyz"; print $s;
19:45 xinming In perl 5, If you wish to do in this structure, you have to do eval '$s' before print.
19:45 xinming I mean the "xyz"
19:46 PerlJam you'll need similar trickery for perl 6
19:47 xinming PerlJam: But, I wonder if the @Larry could consider make "scalar" lazy. just as @ary;
19:47 PerlJam not by default.  That would be too surprising.
19:48 xinming I think this feature won't waste not much CPU circle, and even, I didn't see any side effect to make "scalar" lazy.
19:49 Limbic_Region If made a general rule - I think it would have to also be left to run time for validation
19:49 Limbic_Region which isn't a desireable thing IMO
19:49 Limbic_Region things like tied variables would cause havoc if you tried to do them at compile time
19:50 xinming Limbic_Region: So, You mean, The make the scalar lazy will made chaos?
19:50 xinming Limbic_Region: hmm, How about @ary? :-)
19:51 xinming I think, we might need to add a attribute... my $scalar is lazy;
19:51 Limbic_Region xinming - I mean identifying with all scalars being lazy will be chaos if you don't defer to checking until runtime
19:51 Limbic_Region and IMO, defering to run time is not good for speed
19:51 Limbic_Region but that is just my opinion
19:52 Limbic_Region I don't know much about this stuff and could be out in left field
19:52 xinming Limbic_Region: hmm, I will ask in p6l. :-)
19:55 fglock putter: ping
19:55 svnbot6 r6411 | fglock++ | * perl5/ Code - bugfix - MultiSub wasn't checking parameter signature
19:58 fglock in 'sub x returns Int {...}' - is it a runtime error if the sub doesn't return an Int?
20:00 Limbic_Region fglock I think only if whatever does get returns doesn't have a :coercable thingy that allows it to be coerced into an Int
20:00 Limbic_Region and that may even be compile time
20:01 Limbic_Region if you want to force it to complain even if it is coercable you have a couple of options
20:01 Limbic_Region the first is to create a package that has the coerceable bits turned off
20:02 Limbic_Region so that you can do it on a variable by variable basis
20:02 Limbic_Region the second is to use a pragma (that I believe autrijus might have already implemented) that says all variables at a given scope can't be cast
20:02 Limbic_Region if you need more specific implementation details - see autrijus and/or the list
20:03 * Limbic_Region was only midly interested when he discussed it with autrijus
20:03 fglock so 'returns Int' is a no-op by default
20:03 Limbic_Region I don't think so
20:03 Limbic_Region I think it is a hint
20:03 G2 has joined #perl6
20:04 Limbic_Region that says how a return variable needs to be cast that isn't already an Int
20:05 Limbic_Region if you want, I can check the log to find the conversation with autrijus and myself?
20:05 fglock so it's kind of a caller context (almost)
20:05 dudley has quit IRC ()
20:06 fglock no rush - I've got plenty to do before I really need to know :)
20:09 iblechbot has joined #perl6
20:12 xinming # An interpolated array:
20:12 xinming    / @cmds /
20:12 Limbic_Region fglock - I have found the most recent conversation - though I have raised it several times
20:12 Limbic_Region http://colabti.de/irclogger/irclogge​r_log/perl6?date=2005-08-09,Tue#l981
20:12 xinming what will this interpolated exactly?
20:12 xinming @cmds = ( "str", "string" )
20:12 Limbic_Region the conversation started with "IIRC, @larry - or perhaps even $larry has ruled that if you type the parameters of a sub and" ....
20:13 xinming will it become / str|string / ?
20:13 Khisanth yeah ...
20:14 fglock thanks
20:15 Limbic_Region walang anuman
20:17 xinming hmm, anyone here would clarify my question?
20:17 fglock salamat
20:18 Limbic_Region xinming - you have IMO too questions
20:18 Limbic_Region the first is lazy initialization
20:18 Limbic_Region and the second is lazy interpolation
20:19 Limbic_Region s/too/two/
20:19 xinming Limbic_Region: Sorry for my questions... But In Synopsis, I really can't get clear answer to catch perl 6 grammar...
20:20 Limbic_Region ok - I am confused
20:20 Limbic_Region with regards to the lazy scalar
20:20 xinming @cmds = ( "str", "string" ); / @cmds /; and what will `/ @cmds /` do?
20:20 Limbic_Region it sounds like you are saying....
20:20 Limbic_Region oh nevermind
20:21 Limbic_Region we are talking about two different things
20:21 Limbic_Region I have no idea about your @cmds question
20:21 Limbic_Region but WRT to your lazy scalar - I think you picked a bad example
20:22 Limbic_Region I say that because interpolation fetches values and I think you don't want that
20:22 Limbic_Region for instance my ($foo, $bar, $blah, $asdf);
20:22 G2 has quit IRC ("oops")
20:22 Limbic_Region $bar = $foo + 12;
20:23 Limbic_Region $blah = $bar - 17;
20:23 Limbic_Region $asdf = $blah * 2;
20:23 Limbic_Region $foo = 42;
20:23 Limbic_Region print $bar;
20:23 Limbic_Region in a lazy initialization - that doesn't pose any problems
20:23 Limbic_Region because nothing needs to absolutely have a value until print of $bar
20:24 Limbic_Region but (at least in p5 speak) $bar = "$foo is great";
20:24 PerlJam xinming: @cmds = ( "str", "string" ); / @cmds /; is equivalent to / [str | string] /
20:24 Limbic_Region would require interpolation to be lazy too
20:24 xinming PerlJam: thanks.
20:25 Limbic_Region since that would NORMALLY fetch the current value of $foo, create a copy, and stick the copy in a new variable
20:25 Limbic_Region anyway - I don't like it but as long as I can ignore it without paying any performance penalties I don't mind you having it
20:31 Limbic_Region has quit IRC ("tiuq\")
20:38 fglock autrijus: ping
20:48 masak seen autrijus
20:48 jabbot masak: autrijus was seen 17 hours 14 minutes 4 seconds ago
20:49 leo__ recently on #parrot (MESZ) 21:44  * autrijus waves and sleeps &
20:50 fglock hi leo
20:50 leo__ hi fglock
20:51 fglock is there somebody working on the Parrot p6 runtime?
20:51 leo__ dunno, but it's currently stalled - wating for merging branches/leo-ctx5 and for new lexical specs
20:52 leo__ even waiting
20:55 PerlJam leo__: so ... when is the merge going to happen?
20:57 leo__ hmm - I think I hear that question a lot - last answer was <@Nicholas> I think I can answer that - "ask chip"
20:58 leo__ I hope that it's in the next release though
20:58 arcady has left "Leaving"
20:59 PerlJam leo__: oh, so you've done all you're going to do, it's strictly up to chip to code review and make it so?
20:59 leo__ yes, so it looks to me
21:00 kolibrie has quit IRC ("leaving")
21:04 mjl69 has joined #perl6
21:05 nothingmuch hmm
21:09 fglock just checking, the plus sign in 'sub x ( +$x ) {...}' means that the argument must be named? 'x( x=>1 )'
21:11 iblech has joined #perl6
21:11 iblech Hi :)
21:11 iblech fglock: Right.
21:11 fglock thanks
21:11 iblech Reading your Perl6::Code currently, BTW
21:12 fglock yes?
21:12 iblech Nothing specifically, only FYI
21:13 nothingmuch ugh
21:13 nothingmuch where does S" store whatever it reads from the buffer
21:13 nothingmuch yuck
21:13 fglock currently working in the TODO list
21:13 fglock S" ?
21:14 nothingmuch fglock: forth
21:14 nothingmuch : hello s" FOO " ;
21:14 nothingmuch : opens a new word, writes header
21:14 nothingmuch s" is immediate, reads from input buffer until char = '"'
21:14 nothingmuch the problem is that 'here' is currently the word being compiled
21:14 nothingmuch so you need to jump around it, i guess
21:16 fglock I think that during a ':' it is not immediate (?)
21:16 nothingmuch fglock: immediate means only one thing =)
21:17 stevan fglock++ # Perl6::Code :)
21:18 stevan hola naddamucho
21:18 nothingmuch hola
21:18 fglock boa tarde
21:18 nothingmuch so someone got around to it, eh?
21:18 * nothingmuch ducks
21:18 stevan :)
21:18 stevan nothingmuch: yes, apparently you waited long enough
21:19 stevan fglock: I had been asking nothingmuch to do Perl6::Code since the hackathon
21:19 fglock :)
21:20 nothingmuch fglock: wanna see my def of S" ?
21:20 nothingmuch it passes the tests
21:20 * nothingmuch writes tests and runs them against gforth
21:21 nothingmuch when they start passing I run them on my own forth
21:21 nothingmuch when they start running again i'm done
21:21 fglock I wrote a forth compiler - mmm 20 yr ago I think
21:22 nothingmuch i was born just a little before that
21:22 nothingmuch almost 2 months
21:22 fglock in 6502 assembler
21:23 nothingmuch i'm writing it in perl 5 =)
21:23 svnbot6 r6412 | iblech++ | * Usual svn props and EOLs at EOFs.
21:23 svnbot6 r6412 | iblech++ | * PIL2JS: PIL::Params: Accomodate for latest ruling:
21:23 svnbot6 r6412 | iblech++ |     sub foo (*@xs) {...}
21:23 svnbot6 r6412 | iblech++ |     foo(xs => [1,2,3]);  # @xs contains (xs => [1,2,3]) now
21:27 fglock nothingmuch: forth was 30x faster than basic
21:27 nothingmuch fglock: it's that many times cooler too
21:27 fglock because it could do inlining
21:28 nothingmuch fglock: some of the fun I want to have is to write a generic stack machine optimizer in haskell
21:29 nothingmuch i would mostly like to do inlining and then peephole based stack op removal
21:30 nothingmuch and since all my primitives will be defined as input and output conditions
21:30 mjl69 has quit IRC ()
21:30 nothingmuch then for example stuff like '10 DUP +' will be compiled as an operation that does in place addition of the TOS
21:31 nothingmuch then, when the stack operations are minimized, the TOS is entirely cached in the register space
21:31 nothingmuch and side effect free reorganization of code is supposed to help reduce spills
21:32 fglock cool
21:32 leo__ nothingmuch: $parrot-src/ languages/forth/ needs a maintainer I presume - wanto to jump in?
21:32 nothingmuch ofcourse, it's all just in theory
21:32 * justatheory removes it
21:32 nothingmuch leo__: i dunno parrot, and I'm not maintaining this either (i did some today, i did some yesterday, but before that a month went by)
21:33 nothingmuch if I ever get around to learning parrot i'll take it
21:33 leo__ parrot's forth is still PASM based, which makes it a bit harder ;-)
21:34 saorge has joined #perl6
21:38 Amnesiac has joined #perl6
21:47 * fglock reads about positionals x named x slurpy
21:47 penk has joined #perl6
21:50 iblech xinming: You have mail :)
21:51 xinming iblech: ???
21:51 iblech xinming: I've replied to your p6l question ("Can a scalar be "lazy"?)
21:52 xinming iblech: lol, thanks. :-)
21:52 xinming iblech: I just now write a test for pugs.
21:52 iblech xinming: cool :)
21:52 xinming fun().another have to be the same as fun.another
21:52 xinming I don't know if it's fixed.
21:53 xinming in old pugs, they won't do the same thing
21:53 iblech Right.
21:53 iblech This bug may be related to a similar bug putter has written a test for yesterday or so
21:54 iblech See t/pugsbugs/attribute_of_return_value.t
21:55 xinming iblech: thanks
21:56 rgs has left "Pining for the Fjords"
21:56 fglock in the current spec, if there is a Pair in the arg list, is it always seen as a name/value (before a slurp)?
21:57 iblech fglock: Right. But luqui wants to change that
21:58 fglock and you can have positionals after the Pair, or is it an error?
21:58 iblech No, that's fine
21:59 iblech At least I've always thought that just until you asked that question :)
21:59 hexmode has quit IRC (Read error: 104 (Connection reset by peer))
21:59 fglock :)
21:59 iblech foo(bar => "baz", 42);  # does this look weird?
22:00 fglock I think it is ok. but foo( bar=>"baz", 42, other => "option" ) is weird
22:00 fglock 42 is position zero?
22:01 leo__ iblech: yes weird and suboptimal as foo("baz", 42); will do the same
22:01 leo__ (if bar is positional)
22:02 iblech fglock, leo__: Right.
22:02 iblech Hm..
22:02 fglock so 42 may be position 0 or 1, depending whether bar is +$bar or not?
22:02 xinming ?eval multi ab { ... }
22:02 evalbotzy undef
22:02 iblech fglock: I think so.
22:04 leo__ imho there are by far too many ambiguous possibilities in p6 call syntax, especially when it's related to Pairs
22:08 leo__ explicitely named args are ok, a slurpy (or argument) hash is ok too, but what does a permutation of these?
22:10 leo__ and there is of course my $p = (a => 5); foo(x => $p, $p); ...
22:10 * fglock goes home &
22:11 fglock has left "Fui embora"
22:11 iblech I basically agree with you, leo__
22:11 iblech Your last example would pass the Pair (a => 5) as first positional to &foo
22:12 iblech And $x would be (the same pair) (a => 5)
22:12 xinming ?eval my $t = 100; $t.undef;
22:12 evalbotzy Error: No compatible subroutine found: "&undef"
22:12 iblech xinming: "undef $foo" is spelled "undefine $foo" in Perl 6
22:12 leo__ I think that would vastly depend on foo, if it declares named, optionals or slurpy hashes
22:12 xinming ?eval my $t = 100; $t.undefine;
22:12 evalbotzy undef
22:12 xinming iblech: thanks. :-)
22:13 * geoffb reappears after unburying himself from $real_life (for at least a little while)
22:13 geoffb How goes the war, gents (and ladies, if any)?
22:13 iblech leo__: Oh, right. I assumed sub foo($doesnt_matter, $x)
22:13 leo__ iblech: and it foo happens to take a Pair as first arg all is different still
22:13 iblech leo__: Right...
22:14 * leo__ thinks that this is an undocumentable and unimplemtable mess
22:15 leo__ (and I'm not alone with these toughts ;-)
22:28 saorge_ has joined #perl6
22:28 svnbot6 r6413 | yiyihu++ | Add a test for testing calling the method ( or multi sub ) of a returned object.
22:28 svnbot6 r6413 | yiyihu++ | eg: $obj.sub1.sub2 should be the same as $obj.sub1().sub2() ;
22:30 xinming iblech: Thanks for your suggestion, Perl is really the language TMTOWD :-)
22:31 xinming uhhh... TMTOWTDO... ?
22:31 iblech xinming: np :)
22:31 iblech xinming: TIMTOWTDI
22:31 prefiks has quit IRC ("Ex-Chat")
22:31 iblech xinming: err, no, forget what I said
22:32 iblech xinming: forget again, TIMTOWTDI is correct. Just was surprised that Google lists only 9000 pages containing TIMTOWTDI
22:33 leo__ iblech: strange, maybe because google is using python?
22:33 xinming iblech: hmm, IMO, your question on Proxy, I think, If there is no STORE method supplied, the default action might be simply return the value...
22:33 iblech leo__: :D
22:34 xinming leo__: why do you think Google use python? :-)
22:34 iblech xinming: STORE is called for assignment -- I doubt that simply returning whatever .FETCH returns is the correct behaviour
22:34 leo__ I heard it
22:34 iblech xinming: Other than that, assignments always return the RHS, I asked this once
22:35 xinming iblech: sorry, I might simply pass the value to it, sorry, got a bit sleepy... @_@
22:35 SamB you sure it isn't TMOWTDI?
22:35 iblech SamB: TMOWTDI has only 44 pages
22:36 leo__ tmtowtdi 28,000
22:36 SamB er, TMTOWTDI
22:36 xinming Results 1 - 100 of about 8,720 for timtowtdi. (0.33 seconds)
22:36 iblech leo__: You must be correct.
22:36 SamB I don't know what happened to that T
22:37 xinming iblech: what's rhs anyway... :-S
22:38 luqui I think the camel writes it TMTOWTDI, but I've seen TIMTOWTDI on mailing lists more
22:38 iblech xinming: Right Hand Side, i.e. the $bar in $foo = $bar
22:38 xinming iblech: just like lvalue = rvalue. :-)
22:38 luqui has quit IRC ("Leaving")
22:44 saorge has quit IRC (Read error: 110 (Connection timed out))
22:44 leo__ well TOOWTDI (Pythons motto) - 1020 results on google ;-)
22:45 SamB that is Python's motto?
22:45 leo__ one of em, yes
22:45 SamB I know they try for TOGWTDI
22:46 leo__ TOGWTDI - did not match any documents
22:47 Juerd I'm starting to believe that at least one out of every ten times I drive the motorway N3 some time around midnight, something happens that requires me to call the emergency number.
22:47 xinming "There's Only One Way To Do It"
22:47 xinming ...
22:47 Juerd I've seen all kinds of dangerous people there, but the guy today beats them all
22:48 Juerd Some --probably drunk-- guy was crossing the motorway. Repeatedly.
22:48 xinming python and perl are both started with "p" But go to the really different "direction"
22:49 Juerd It's incredibly stupid to have exactly one way to do something.
22:49 Juerd It's also incredibly stupid to have multiple best ways to do something.
22:49 xinming Juerd: well, Only paranoia survive. ;-)
22:49 xinming s/paranoia/paranoias/
22:49 Juerd The best solution is to have multiple ways to do something, of which one is the clear and unarguable better choice.
22:50 Juerd Unfortunately, this is hardly possible, and for practical reasons, we always have to choose between the extremes.
22:50 xinming Juerd: hmm, In fact, The better choices come from more choices.
22:51 Juerd Not always
22:51 leo__ yep and of course there is a lot of 'there's no way to do it' except with ugly incompatible hacks
22:51 xinming Juerd: at least, Hope Python won't choose the worst to apply the motto, There's Only One Way To Do It
22:51 leo__ and the 'one way' isn't true either
22:51 Juerd I personally like being able to write either foo if bar, bar and foo, if foo { bar }
22:52 Juerd But I do reckognise that this makes Perl unacceptable to many.
22:52 xinming Juerd: most people don't like $ @ and %...
22:52 larsen has quit IRC ("later")
22:52 xinming Juerd: because they thought this is confusing...
22:52 Juerd xinming: I find them ugly but useful
22:52 Juerd And that describes Perl entirely
22:52 xinming Juerd: I prefer the useful.
22:52 leo__ use nosigils;  # soon at your CPAN6
22:53 Juerd It's very ugly, Perl.
22:53 Juerd But that's not a *problem*
22:53 xinming Juerd: hmm, In fact, I think Perl 6 won't be so ugly... :-)
22:54 xinming Juerd: I hate perl 5's OO design. for a method, You have to do my $obj = shift; in every sub.
22:54 xinming Juerd: and also for use strict; use warnings;
22:55 Juerd Perl 6 will be less ugly.
22:55 Juerd Not unugly
22:55 Juerd I almost never use shift for shifting @_
22:55 Juerd my ($self, $foo, $bar) = @_ works best for me
22:56 Juerd And $obj doesn't work for me. It has to be either $self or $this for me to fully realize you're writing a method.
22:56 xinming Juerd: I wonder why @Larry wish to keep parens away as best as he can.
22:56 Juerd I wonder what you mean by that.
22:57 xinming hmm, You see, if( ) { } elsif () { }
22:57 xinming But in perl 6, larry make the design which can ignore the parens for if
22:58 xinming And even for sub calls.
22:58 xinming a = a();
22:58 xinming a $par; = a( $par );
22:58 Juerd It's not that the parens become *optional* as such
22:58 Juerd They're just no longer part of the syntax
22:59 Juerd You can still use parens, but then they are normal disambiguating grouping parens, and not special syntax for the statement:if
22:59 xinming that makes think of if that @Larry hate the parens.
22:59 xinming s/hate/hates/
22:59 Juerd Everybody should hate unnecessary brackets.
22:59 Juerd { } can't go away for many reasons, but () could go away easily.
23:00 Juerd For the same reason I find it weird that \d**{5} still isn't \d**5
23:00 nothingmuch has quit IRC (Read error: 110 (Connection timed out))
23:00 xinming Juerd: Maybe @larry want it for more clear with 1..num
23:01 Juerd (For the simplest of cases, that is. I'm not arguing for \d**EXPR because that's hard. But for the simple int and int..int, exceptions can and should be made.)
23:01 xinming maybe 1..Inf
23:01 xinming Juerd: Maybe he think, that no one write rules every day, So He chose **{} :-)
23:02 Juerd Oh come on... ucfirst He?
23:02 Juerd That's none(@Larry), fyi.
23:03 zophyx has quit IRC (Remote closed the connection)
23:04 xinming typo
23:05 Juerd And regarding "there's probably a good reason for this". Perhaps there is. I'd like to know it, and until I do know the good reason, I'm not assuming there is one, if I think the design can be improved further.
23:05 Juerd And there are of course times at which the "good reason" isn't all that good.
23:06 xinming Juerd: Only time will improve. :-) As the design can be changed.
23:06 xinming Juerd: at least, Perl 6 hasn't been released yet.
23:09 nothingmuch has joined #perl6
23:11 * xinming go to write test for slurpy %hash and then go sleep.
23:15 Juerd Good night
23:37 venk has joined #perl6
23:37 vcv- has quit IRC (Read error: 104 (Connection reset by peer))
23:46 nothingmuch has quit IRC (Read error: 113 (No route to host))

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo