pugscode.org/ | nopaste: sial.org/pbot/perl6 | pugs: [~] <m oo se> (or rakudo:, kp6:, elf: etc.) (or perl6: for all) | irclog: irc.pugscode.org/
Set by Tene on 29 July 2008.
00:05 ruoso left 00:06 fridim_ left 00:19 bacek joined 00:26 kanru left 00:30 PZt left 00:34 eternaleye joined 00:38 alester joined 00:45 eternaleye left 00:48 araujo joined 01:03 jferrero left 01:09 eternaleye joined 01:29 apeiron_ joined, luqui joined 01:38 xinming joined 01:39 apeiron left 01:51 xinming__ left 01:58 Jedai left 02:13 eternaleye left 02:18 xinming_ joined 02:29 meppl left 02:30 xinming left 02:31 meppl joined 02:36 s1n joined 02:37 wknight8111 left 02:42 alester is now known as alester_away 02:44 sri_work joined 02:46 eternaleye joined 02:54 s1n left 03:02 s1n joined 03:22 alester joined 03:32 eternaleye left
meppl good night 03:46
03:47 meppl left 04:15 alanhaggai left 04:18 alanhaggai joined 04:42 eternaleye joined 05:02 |alanhaggai| joined, alanhaggai left 05:04 BinGOs joined 05:06 meteorjay left 05:08 |alanhaggai| left 05:13 alanhaggai joined 05:16 BinGOs_ left 05:19 alester left 05:34 Psyche^ joined 05:44 Patterner left, Psyche^ is now known as Patterner 05:57 ashizawa joined 06:01 zamolxes left 06:02 [particle]1 joined, xinming joined 06:04 PZt joined 06:05 [particle] left, Myoma left, Auzon left 06:09 Myoma joined, Myoma left 06:10 Auzon joined 06:16 xinming_ left 06:22 viklund joined 06:23 bbkr_ joined, bbkr left 06:51 zamolxes joined 07:01 Myoma joined 07:22 masak joined 07:53 elmex joined 07:57 pmurias joined 08:03 penk joined 08:04 fridim_ joined
pmurias svn: REPORT request failed on '/pugs/!svn/bc/22012' 08:11
svn: REPORT of '/pugs/!svn/bc/22012': 400 Bad Request (svn.pugscode.org)
lambdabot Title: Revision 22032: /
pmurias whe svn up'ing is a problem with the network not with the repo? 08:12
* when
moritz_ when I try, and it works for me, it's a problem with the network (as in this case) ;-)
pmurias how can i check if there's a proxy and workaround it? 08:15
moritz_ dunno
pmurias checking out via https worked 08:20
08:23 frobnitz_ joined 08:26 larsen_ joined 08:34 japhb left, japhb joined 08:35 Gothmog_ left, frobnitz left, bacek left 08:36 IRSeekBot left 08:38 IRSeekBot joined 08:39 Gothmog_ joined 08:41 dr_df0 joined 08:42 dr_df0 left 08:44 pmurias left, df_df0 joined, df_df0 left, dr_df0 joined 08:56 iblechbot joined
dr_df0 sorry for bothering You, but I've been looking at readme and howto files 09:04
masak dr_df0: yes? 09:05
09:30 Gothmog_ left 09:41 Myoma left 09:46 wknight8111 joined 09:48 jferrero joined 09:52 barney joined 09:55 Gothmog_ joined 10:09 dr_df0 left 10:11 dr_df0 joined
dr_df0 rakudo: say "just testing .." 10:13
p6eval rakudo 29834: OUTPUT[just testing ..ā¤]
moritz_ you can also let pugs or elf eval your code 10:14
pugs: say [+] 1..4
p6eval pugs: OUTPUT[10ā¤]
10:14 dr_df0 left 10:41 megamic joined 10:46 wknight8111 left 10:54 meppl joined
masak pugs: say [=>] 1..4 11:01
p6eval pugs: OUTPUT[1 2 3 4ā¤]
masak pugs: say ([=>] 1..4).perl 11:02
p6eval pugs: OUTPUT[\(1, \(2, \(3, 4)))ā¤]
moritz_ pugs: say [>=] 1..4 11:05
p6eval pugs: OUTPUT[ā¤]
moritz_ pugs: say [<=] 1..4
p6eval pugs: OUTPUT[1ā¤]
moritz_ masak: I tried to write a lexer for the Perl 6 version of HTML::Template, but RT #58312 stopped me :/ 11:07
masak moritz_: I'm on it. I'll rewrite the whole HTML::Template today or tomorrow. 11:08
with tests.
moritz_ my plan was to tokenize the input into chunks of normal text and directives, and then write a recursive decending parser on these tokens
well, you already have some tests ;)
masak I'll see if I can find a way to make Perl 6 grammars do the recdescent 11:09
moritz_ and I guess you could ask samtregar if you can use his HTML::Template test suite, at least the relevant parts
masak I've looked a bit at that test suite 11:10
it looks very comprehensive
but it may or may not be too tied to the Perl 5 HTML::Template
that said, I might be able to 'borrow' the good parts, or at least get inspiration from it 11:11
moritz_ it certainly depends on whether you want to be HTML::Template 5 compatible, or only alike
masak alike
I thought I'd redesign the interface while I'm at it
(yes, 2nd sys synd, I know)
I've noticed that all of our usages follow the pattern create - set params - output 11:12
so I thought I'd design the interface around that
make it easy to do that case, with sensible fallbacks if you want to get more elaborate
moritz_ sounds great 11:13
masak will probably write something about it on use.perl.org
maybe I'll decide to make our HTML::Template fully compatible, and then write a wrapper that does the DWIMmery 11:14
moritz_ or the other way round
clean break, remember? ;-)
masak true. 11:15
moritz_ masak: when you're done with your refactor, ping me, and I'll contribute an implementation of default_escape
masak moritz_: nice. I will.
moritz_ (which I consider to be most important wrt XSS)
masak moritz_: do you still prefer to send us patches from outside? :) 11:16
moritz_ at the moment, yes
masak that's ok.
moritz_ when I'm more confident with git I'll certainly accept a commit bit 11:17
masak moritz_: you're going to love git 11:18
moritz_ speaking of which... 11:19
"error: Entry 'p6w/HTML/Template.pm' not uptodate. Cannot merge.
what do I do now?
masak moritz_: btw, your #58312 is just a special case of #57858. marking it as such.
11:19 wknight8111 joined
masak moritz_: git merge? 11:19
oh, that's what you're doing. sorry
what was the command you were running when you got that error? 11:20
moritz_ git-pull 11:21
I probably shouldn't have modified the file in master, right? 11:22
masak check out a clean version of that file and try again 11:23
that might solve it
git does some unexpected things for a few days, and then it becomes wonderful 11:24
but I'm still a bit unclear on the way to handle merge conflicts, because it doesn't happen too often 11:25
moritz_ so how do I check out a clean copy of the file?
masak git checkout
moritz_ ok, that tells me M p6w/HTML/Template.pm 11:26
Your branch is behind the tracked remote branch 'origin/master' by 12 commits,
and can be fast-forwarded.
what do I do then? git-pull again?
masak interesting.
yes, try that...
moritz_ p6w/HTML/Template.pm: needs update 11:27
error: Entry 'p6w/HTML/Template.pm' not uptodate. Cannot merge.
masak :/
moritz_ git-diff|patch -R -p1 11:28
followed by a git-pull
not very nice, but worked :
:/
masak heh
moritz_ perhaps git-clean might have helped 11:29
masak dunno
11:34 meppl left 11:36 meppl joined 11:41 bbkr_ left 11:49 pmurias joined 11:52 pmurias left 11:53 rindolf joined 11:59 pmurias joined 12:02 megamic left 12:05 fridim__ joined 12:10 Ehtyar left 12:13 fridim__ left 12:15 iblechbot_ joined 12:18 fridim_ left 12:19 jferrero left 12:24 iblechbot left 12:29 jferrero joined, allbery_b left
wolverian does the spec allow you to "wrap" a class method with a role method? in scala, this kind of a trait method is marked "abstract override", and it calls the class method via super 12:31
particularly this allows you to stack these traits (roles) that modify a given method 12:32
12:33 luqui left
masak will subs in classes be inlined automatically? 12:34
pmurias masak: i think inlining is implementation dependend 12:37
masak but there's no theoretical obstacle?
pmurias subs in classes should be inlined the same as subs everywhere 12:38
i think it should be possible 12:39
moritz_ rakudo: my $M; my $str = 'abc'; while $M := $str ~~ /b/ { say "from ", $M.from; $str = '' }; 12:40
p6eval rakudo 29834: OUTPUT[from 1ā¤]
masak seems to work. 12:42
moritz_ aye 12:43
now I'm one step closer to my tokenizer
masak moritz_++
pasteling "moritz_" at 89.13.210.223 pasted "Shot at a first tokenizer for HTML::Template" (30 lines, 694B) at sial.org/pbot/31985 12:44
moritz_ I wonder why it says No match on ' <dsadf '
but then @tokens is ["foo ", "<TMPL_VA", ""] 12:45
ie last item is empty
ah, @otkens.push: $str.substr(0); # weird way to get a copy of a string 12:48
masak moritz_: interesting work. best of luck. right now I'm at $work, so I'm not hacking on a new HTML::Template -- but when I get home, I'll take a closer look at what you've done. 12:49
without any real proof, I'd say you are inventing Perl 6 grammars right now 12:50
moritz_ masak: ok, I have a tokenizer now that basically works
masak but -Ofun, so...
moritz_ I know, but this actually works ;)
masak so do Perl 6 grammars :)
moritz_ my succcess with grammars was verly limited so far 12:51
masak I've had the opposite experience
moritz_ how do I match against a grammar rule? $stuff ~~ /<Grammar.TOP>/ ?
masak $stuff ~~ Grammar.TOP
see Wiki.pm
moritz_ ok
masak that's how we parse wiki markup at present
though there, too, I have some pending changes 12:52
moritz_ do you knew if 'token ws { ... }' does what it should?
ah, probably no :sigspace yet
masak I think it was a mistake to parse on the article level as opposed to the paragraph level 12:53
Str.split could pry apart paragraphs better than a grammar could, and then intra-whitespace handling becomes simpler
s/intra-/intra-paragraph / 12:54
12:54 ashizawa left 13:01 kolibrie joined 13:05 jferrero left
moritz_ grammars work fine for me as long as I don't recurse :( 13:09
masak hm, we recurse, so far without problems
but what you say does sound like a new rakudo bug 13:10
moritz_ I'll try to track it down
masak also, be careful not to call any of your tokens 'text' :/
PGE doesn't like that.
moritz_ f*ck, I did
masak haha
I call mine 'twext' 13:11
moritz_ I call it 'plain
masak developing in rakudo is a bit like building sand castles in a mine field. 13:12
as long as you build in the right spots, it's pretty nice. 13:13
moritz_ do you know if lookaraounds are implemented and accessible?
masak we've used both -aheads and -behinds a bit 13:14
see Wiki.pm
moritz_ cool
YaY 13:15
masak :)
13:17 Auzon left 13:20 kanru joined 13:22 frobnitz_ is now known as frobnitz
moritz_ I have a working grammar for HTML::Template now 13:33
pugs_svn r22033 | pmurias++ | [smop] fixed warnings raised by gcc and the bugs that caused them
moritz_ mostly working ;) 13:34
masak moritz_: cool!
13:36 barney left
pugs_svn r22034 | pmurias++ | [smop] removed a no longer relevant files which likely appeared due to a svk bug 13:37
13:41 rdice joined 13:43 pmurias left
moritz_ masak: sent mail 13:55
13:55 dmq joined
masak moritz_: many thanks 13:56
moritz_ no problem, that was -Ofun indeed
masak -Ofun++ 13:59
14:02 TJCRI joined, gbacon joined 14:04 jhorwitz joined 14:14 bbkr joined 14:25 kanru left 14:32 allbery_b joined, cmarcelo joined 14:37 hercynium joined 14:47 kanru joined 15:01 allbery_b left, Exodist joined 15:03 rindolf left
rakudo_svn r30536 | pmichaud++ | [rakudo]: spectest-progress.csv update: 127 files, 2278 passing tests 15:04
15:15 Myoma joined 15:18 penk left 15:54 zamolxes left 15:55 alanhaggai left
moritz_ TimToady: %hash.exists<key> doesn't look like English to me. What about an alias %hash.contains<key>, or perhaps .has? 16:07
smg has_key? 16:10
masak has-key?
contains-key?
moritz_ smg: just has
masak likes 'has' 16:11
as long as we're making a clean break -- we already changed length to elems/chars/etc 16:12
so s/exists/has/++
OTOH, `exists %hash<key>` _does_ make sense 16:25
is that syntax still valid in Perl 6?
16:26 zamolxes joined
moritz_ no 16:28
we discussed this the other day when larry added symbol tables to STD.pm which caught such mistakes
16:33 alanhaggai joined
masak moritz_: in that case, I'd say that `exists` has played out its wole 16:44
s/w/r/
16:45 masak left
moritz_ I CAN HAZ HASH KEY? 16:45
16:46 rindolf joined 16:55 alester_away is now known as alester 17:02 allbery_b joined
Khisanth more like English? Perl6 stealing from COBOL? :) 17:15
allbery_b lemme guess, - in identifiers? 17:17
moritz_ Perl has always been happily stealing features from other languages, and admitted it freely ;)
17:51 jferrero joined 17:57 aindilis left 17:58 aindilis joined 18:16 rindolf left 18:34 TJCRI left 18:48 TJCRI joined 18:56 calin joined
moritz_ on use.perl.org, how do I become a "fan" of somebody else? 19:09
19:25 meppl left
BinGOs the little smiley faces. 19:27
moritz_ is fan == friend? 19:28
BinGOs i believe so. 19:29
moritz_ ah, I think if I declare somebody as my friend, I'll appear as his fan - or something like that 19:31
19:36 dr_df0 joined 19:39 rindolf joined
dr_df0 Hi all, I've installed Pugs from sources and i have problems running prove6 utility 19:45
it always stops with error on first test
moritz_ how did you install pugs? with 'perl Makefile.PL && make' ?
19:45 rindolf left
moritz_ from svn? 19:46
dr_df0 Yeah, just before building i've done svn up
moritz_ can you pleae nopaste the error message?
and what happens when you run 'make test'?
dr_df0 but I did also the last bit "make install" ?!?
19:47 rindolf joined
moritz_ I never did that ;) 19:47
dr_df0: so what's the error message? 19:49
dr_df0 info: Harness with pugs (Haskell backend). 19:51
t/spec/S03-operators/arith....NOK 144# Failed test (t/spec/S03-operators/arith.t line 330, column 1-17)
# Expected: 'Inf'
# Actual: '-Inf'
# Looks like you failed 1 tests of 190
t/spec/S03-operators/arith....FAILED test 144
Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t/spec/S03-operators/arith.t 190 1 0.53% 144
Failed 1/1 test scripts, 0.00% okay. 1/190 subtests failed, 99.47% okay.
moritz_ it means the test fails ;) 19:52
which is because it's written wrongly
is -Inf.abs, Inf;
should actually be is (-Inf).abs, Inf;
dr_df0: could be your first test to fix 19:53
dr_df0 i've checked few of them, and i could not find any working 19:54
moritz_ pugs isn't really well maintained at the moment
which is why I mostly focus on rakudo these days
19:56 gbacon_ joined 19:57 gbacon_ left
pugs_svn r22035 | moritz++ | [t/spec] fixed precedence bug in arith.t, dr_df0++ for spotting it 20:07
moritz_ perlbot: karma dr_df0 20:10
perlbot Karma for dr_df0: 2
20:10 larsen_ left 20:18 sri_work left 20:32 rindolf left 20:38 larsen_ joined 20:51 eternaleye left 20:54 eternaleye joined 20:56 ruoso joined 20:57 cmarcelo left 21:00 BinGOs left 21:07 BinGOs joined 21:12 meppl joined 21:19 rdice left 21:22 Auzon joined 21:24 ruoso left 21:31 Limbic_Region joined 21:38 TJCRI left 21:40 dr_df0 left 21:45 jhorwitz left 22:09 aindilis left 22:10 aindilis joined, eternaleye_ joined, eternaleye left 22:25 cotto_work left 22:26 cotto_work joined 22:32 ruoso joined 22:43 hercynium left 22:53 ruoso left 22:54 simcop2387 left 22:56 Exodist left 23:00 jferrero left, simcop2387 joined 23:27 elmex left 23:48 iblechbot_ left 23:55 calin left