00:00:00 --- log: started haskell/02.01.25 00:22:59 --- join: jsw (scott@12-234-202-177.client.attbi.com) joined #haskell 02:26:34 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 02:51:16 --- quit: jemfinch () 02:52:23 --- quit: shapr (carter.openprojects.net irc.openprojects.net) 02:54:59 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 02:55:51 good morning 03:10:16 --- quit: shapr (Remote closed the connection) 03:12:45 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 03:19:53 --- quit: shapr ("f00") 03:20:42 Hmm. 04:12:21 --- join: War[Clone] (~myPhpBot@APh-Aug-101-1-3-51.abo.wanadoo.fr) joined #haskell 04:13:21 --- part: War[Clone] left #haskell 04:16:10 --- quit: dblack ("[x]chat") 06:04:57 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 06:08:37 https://sourceforge.net/survey/survey.php?group_id=44807&survey_id=12660 06:09:04 that's the first survey for the haskell-libs project 06:09:58 It wants me to log in - can you summarise it? 06:10:08 er, try it with http:// 06:10:18 I should have noticed that :) 06:10:27 Doesn't help 06:10:30 hrm 06:10:57 http://sf.net/projects/haskell-libs/ 06:11:38 * Igloo contemplates finding out what my username is and joining 06:12:04 Heh, I used haskell tonight to do some of my homework for me. 06:12:11 Logan: cool! what did you do? 06:12:22 Oh, questions not results 06:12:44 Had to generate some tedious parsetrees and left-derivations by hand, wrote a program to do it instead. 06:12:54 Found a yacc-for-haskell program, too. 06:13:02 What subject and what level is this? 06:13:08 happy? 06:13:11 Igloo: right, it's a question :) 06:13:15 er, two questions 06:14:24 Yes, happy. 06:14:34 Programming languages homework. Really basic stuff. 06:14:48 I used some generic Tree code I coded the night before to represent the parse tree. 06:14:50 Undergraduate? 06:14:54 Graduate. 06:14:58 I've been assuming that network libs such as smtplib, imaplib, and poplib are the best things to start with 06:15:03 Though the stuff done so far is the same as the undergraduate course I took. 06:15:04 Oh, cool 06:15:06 but I don't know if anyone else agrees with me 06:15:10 Probably the same exercises, I don't remember. :P 06:15:18 What sort of degree are you doing now then? 06:15:24 M.S. 06:15:48 Right 06:15:55 Cool 06:15:57 In the US? 06:16:04 Igloo: did you find a correct url? 06:16:07 Yep. 06:16:10 shapr: Yeah 06:16:24 * Igloo wonders if it's at a uni I might have heard of 06:16:28 http://www.loganh.com/class/current/programming-languages/hw1 06:16:32 Virginia Tech 06:17:14 Hmmm, not w3m-friendly :-) 06:18:11 Well, that's just my working directory for the homework. Not much you can do in w3m but browse the latex and browse the code in the code directory. :P 06:18:26 Is there some form of show that doesn't quote things? 06:18:41 What are you trying to do? 06:20:59 Well, my tree is defined as working with two polymorphic types, representing node labels and edge labels respectively. 06:21:01 id is the answer, but that won't work if you need it to be polymorphic 06:21:18 And I have some functions that display trees, which exist for trees that work with Showable labels. 06:21:26 And thus they use the show function to preserve polymorphism. 06:23:09 You could make a newtype MyString = MyString String and make it an instance of Show 06:23:23 And make a show function for it that doesn't quote? 06:23:33 I guess that would work, since it's the only thing I've observed quoted. 06:23:41 Yup, by using show on the string and chopping the ends off 06:24:13 No, show quotes backslashes in the string too. 06:24:15 And double quotes. 06:24:31 It'd be better to just have a show = id for strings. 06:30:08 Presumably you are assuming you won't have things like ^G in the String then 06:31:12 Hmm... maybe it would be better if I just had the calling function always provide the display function... basically generalize things more. 06:31:31 It's really just a traversal anyway. 06:31:41 And I already have code to do that with a general function. 06:32:35 So what's a good networking library for haskell? :P 06:32:45 import Socket 06:33:55 Oh, didn't notice that in the ghc stuff. 06:35:10 I should get some sleep today. 06:35:13 --- nick: Logan -> LoganZzZz 06:35:30 g'night LoganZzZz 06:35:43 Isn't it just becoming day in the US? 06:35:50 yup 06:36:01 8 hours back 06:36:16 Virginia is? 06:36:40 * Igloo guesses 7 from the UK if it's 8 from Finland 06:37:05 * Igloo notices shapr is an emacs person...and you seemed like such a nice chap :-) 06:37:13 I'm using ERC 2.1 $Revision: 1.179 $ with Emacs 21.1.1! 06:37:36 how did you notice I'm an emacs person? 06:37:49 I inferred it from you being on #emacs 06:37:53 aha 06:37:54 good point 06:38:08 that also means I'm an interesting person. 06:38:53 Can emacs do cunning joint syntax highlighting like the TeX and Haskell highlighting on http://c93.keble.ox.ac.uk/~ian/haskell-vim/Demo.png out of interest? 06:39:11 I saw your screenshot btw ;) 06:39:21 earlier today when you posted about your spiffy vi mode 06:39:42 Right - I was just wondering if emacs has support for nested syntax highlighting too 06:39:47 yup 06:39:57 mmm-mode 06:40:02 multi-major-mode 06:40:22 it allows you to have one mode with 'submodes' for certain regions 06:40:33 There are an inconsistent number of 'm's there :-) 06:40:38 OK, cool 06:40:40 really? 06:40:48 multi-major-mode-mode 06:41:03 Oh, I guess that does make sense actually 06:41:12 I'm not going to say that emacs (or anything else I use) is inherently better than anything else. 06:41:20 I'll just say those things are better for *me* 06:41:47 and then I'll probably ask you silly vim questions when I get the urge to learn more about vim (which happens every two weeks or so) 06:41:55 :-) 06:42:06 I'm a knowledge sponge. 06:42:54 though at the moment, haskell is my main squeeze 06:43:14 I'd really like to see Haskell become a mainstream programming language 06:44:17 hm, I wonder how I set up a survey that doesn't require authenticated users 06:44:19 That's going to need some work on IO performance and better support for things like network stuff and shared libraries first I think 06:44:42 I did manage to get to the survey from the last link you posted 06:45:20 I suspect performance is not really an issue 06:45:30 time-to-market is 06:45:36 whether that means open source or not 06:46:01 Depends on the application, but yeah 06:46:16 that's why Python is so popular and powerful, because it's easy to plug a bunch of stable featureful libs together and tada, you have an application. 06:47:30 imho, compiled Haskell is faster than Python 06:47:38 Haskell is also more concise than Python, but not concise like Perl ;) 06:47:51 I'd be surprised if that was the case for a heavy IO application 06:48:25 how can we test that? 06:48:30 I'm not sure how much better the new IO library is, but certainly older ghc5 releases really suffered from treating strings as lists of chars and the overheads incurred 06:49:18 can you give me some specific instances where that ended up being really slow? 06:50:32 or some Haskell code that illustrates it? 06:52:40 Can you give my some python that copies file1 to file2 by reading and writing? 06:54:21 yah, just a moment 06:54:40 any particular flavor? eg. all at once, line by line, what? 06:55:13 I don't know how perl compares to python, but 06:55:19 [ian@urchin ian]$ time perl Q.pl 06:55:19 real 0m1.358s 06:55:19 user 0m1.140s 06:55:19 sys 0m0.220s 06:55:22 [ian@urchin ian]$ time ./Q 06:55:22 real 0m9.698s 06:55:22 user 0m9.250s 06:55:24 sys 0m0.450s 06:55:32 ah 06:55:37 Q.pl is 06:55:38 open IN, "< hugs1"; 06:55:38 open OUT, "> hugs2"; 06:55:38 while () { 06:55:38 print OUT; 06:55:38 } 06:55:40 close OUT; 06:55:42 close IN; 06:55:45 can you profile both of them? 06:55:55 that could be informative 06:55:57 And Q is ghc compiled (-O2) 06:55:58 > module Main where 06:55:59 > main :: IO() 06:55:59 > main = readFile "hugs1" >>= writeFile "hugs2" 06:56:21 ghc-5.02.2 to be precise 06:57:13 the simplest equivalent python code: 06:57:16 open('hugs2','w').write(open("hugs1").read()) 06:57:28 untested, but I bet it'll work fine 06:58:04 [ian@urchin ian]$ time python foo.py 06:58:04 real 0m0.332s 06:58:04 user 0m0.020s 06:58:04 sys 0m0.300s 06:58:30 Faster than perl, but the perl was doing extra work to find the ends of lines 06:59:02 yah, the python line reads and writes the entire file 06:59:23 can you profile the ghc code? 07:00:03 http://haskell.org/wiki/wiki?HaskellNiftyTricks 07:00:07 tells how to do profiling 07:00:11 though I bet you already know 07:00:38 perl is real 0m0.305s if I do undef $/; print OUT ; instead 07:01:13 perl is more optimized under the hood than Python 07:01:28 fits the relative language philosophies I think :) 07:02:21 * Heffalump appears, skims scrollback, and notes that (1) Virginia is almost certainly 5 hours from the UK and (2) emacs users are wonderful people 07:02:28 heh 07:02:43 Good afternoon Mr. pico :-) 07:02:50 I don't use that to edit code :-p 07:03:04 and that's "Dr. pico -w" to you, I'll have you know. 07:03:14 Not yet it's not (is it?) 07:03:19 ("almost Dr. pico -w") if you want to be pedantic 07:03:28 crap, I can't get any profiling info :( 07:03:37 Hmmm, it's not very useful 07:03:55 It basically says it's all in main 07:04:01 hm 07:04:09 you're right 07:04:15 that doesn't help much 07:04:36 maybe gdb or one of those guys 07:04:40 if I knew how to use them :) 07:05:20 I don't think there's an easy way to get more useful information 07:05:43 .uinai 07:05:46 (unhappiness) 07:06:29 Hmmm, I seem to hav got sidetracked again :-) 07:06:45 well, I'll ask on the haskell list 07:08:20 thanks for the idea swapping btw ;) 07:08:37 np 07:18:20 aha, nofib 07:19:11 ya know, the most irritating thing about the Haskell community is that so many of the webpages and code samples are old, outdate, and unworking. 07:20:05 this is one of the reasons Haskell 98 is a good thing 07:20:14 people really ought to clearly document it when they go outside that 07:20:18 I agree. 07:36:23 --- quit: Igloo (carter.openprojects.net irc.openprojects.net) 07:36:54 --- join: Igloo (~ian@pc3-oxfo3-0-cust1.oxf.cable.ntl.com) joined #haskell 07:55:07 --- join: kfl (~kfl@vip135.it-c.dk) joined #haskell 07:55:19 hello kfl 07:55:26 --- join: ian_ (~ian@c93.keble.ox.ac.uk) joined #haskell 07:55:35 --- quit: Igloo ("BitchX has bite! (Just ask Mike Tyson!)") 07:55:38 kfl: have you been here before? 07:55:40 --- nick: ian_ -> Igloo 07:56:00 hello shapr. 07:56:12 --- quit: Igloo (Client Quit) 07:56:15 No this is the first time I use IRC 07:56:24 "BitchX has bite! (Just ask Mike Tyson!)" 07:56:31 Welcome to IRC! 07:56:38 jewel: scary :) 07:56:47 --- join: Igloo (~igloo@c93.keble.ox.ac.uk) joined #haskell 07:57:10 kfl: Are you new to Haskell, or an experience programmer of Haskell? 07:57:39 I'm quite experienced using SML 07:58:12 But according to the Haskell Wiki I'm a Haskell black belt 07:58:32 aha! 07:58:35 that's excellent! 07:59:24 I'm sorry I have to leave now, but I'm happy to have learned that #haskell is a nice place 07:59:30 Whereabouts in the Wiki is that? 07:59:37 come back soon kfl! 07:59:45 http://haskell.org/wiki/wiki?HaskellIrcChannel 08:00:02 it all started with my calling the #emacs channel "The Emacs Dojo" 08:00:15 and then this became The Haskell Dojo 08:00:16 and then.. 08:00:58 Ah 08:01:12 --- part: kfl left #haskell 08:01:44 I'd guess you also have a black belt in Haskell 08:02:23 Either brown or black - I haven't done enough with monads to know if I would counts a proficient 08:02:43 well, add yourself where you think you fit 08:02:44 :) 08:02:55 This is heading dangerously close to a Haskell purity test :-) 08:03:00 oh! 08:03:01 good idea!! 08:03:13 "Have you ever used unsafeIO?" 08:03:18 * shapr laughs 08:03:32 "Have you ever generalized a Monad into an Arrow?" 08:03:40 oh, I gotta start that wiki page 08:03:44 unless you do it first 08:03:51 I don't do wikis 08:03:55 why not? 08:04:08 My only experience was with the Haskell one and it was awful 08:04:23 well, it is awful 08:04:24 sadly :( 08:04:26 Conflict resolution was "Sorry, please do it yourself" 08:04:33 yah, it has major problem 08:04:33 s 08:04:40 I suggested moin.sf.net 08:04:50 but John Heron didn't want to convert all of the pages 08:04:57 I should probably volunteer 08:05:04 since I know how to do it 08:05:15 Perhaps we should write a beautiful wiki in Haskell :-) 08:05:20 I agreeeee!!!!! 08:05:44 I desperately want a Haskell Wiki 08:06:13 I've tried to get 08:06:14 oops 08:06:21 http://haskell.org/wiki/wiki?HaskellWikiInHaskell 08:06:29 It's not really very functional unfortunately. You might be able to do something nicely functional for the diff/merge bit though 08:07:44 I suspect it could be very functional 08:13:12 * shapr searches for any of the HaskellWiki prototypes 08:20:59 * shapr emails Marko Schuetz 08:28:46 * shapr meditates upon list comprehensions 08:29:03 For what purpose? 08:29:28 I'm trying to figure out a good way to implement a pascal's triangle function 08:29:44 I couldn't figure out how to do it with scan, but list comps might do it 08:29:58 [ x | x <- [1] ] 08:30:04 step 0 08:30:31 I think it was Heffalump who told me that list comps are actually monads 08:30:55 list comps are the multiple universes theory, but you get all outputs 08:31:02 all legs of the Trousers Of Time 08:36:06 Are you trying to generate the whole triangle? 08:36:20 I'd like to 08:36:43 pascaltri 1 = 1 08:36:46 I'm not sure I can see how you're going to useful use list comprehensions or scanr without a dummy infinite list then 08:36:48 pascaltri 2 = 1 1 08:36:52 hmm 08:37:00 Oh, so you just want to get a given row? 08:37:04 anything :) 08:37:49 pascaltri n = [1] ++ (scanr (+) pascaltri (n-1)) ++ [1] 08:37:58 that was my earliest stab at it 08:38:23 there was some discussion here about 'sublists' recently 08:38:34 I thought that would be a good use of scan 08:39:13 I'm good at distracting you I think :) 08:39:24 Hmmm :-) 08:39:52 * Igloo looks at what I've done and wonders about the efficiency 08:40:07 bah, I'll go play with Joy and stop distracting you :) 08:40:28 Try doing it using iterate and a similar basic idea 08:40:37 ok, I'll try that. 08:40:46 * shapr looks up iterate 08:50:22 * Igloo feels my next distraction getting closer as I yet again scp config files around and diff them 08:50:30 uh oh 08:50:37 * shapr passes some Ritalin to Igloo 08:50:41 I just got a new batch today ;) 08:51:01 How would that help? 08:51:15 Ritalin is the ultimate cure for distraction. 08:51:47 http://c2.com/cgi-bin/wiki?RitalinDrug 08:52:00 Ah, OK. I will ultimately be less efficient if I don't get distracted by things like config file propogation and syntax highlighting config writing, though :-) 08:52:09 Aaargghh! More wikis! 08:52:15 * shapr cackles 08:52:20 that's true 08:52:30 always automate manual tasks 09:21:32 (if what I was hinting at with iterate isn't obvious I can expand on it) 09:22:45 kind of you to offer, but at the moment I'm doing connected graphs in Joy.. 09:22:49 or at least trying... 09:23:11 OK :-) 09:23:42 Is Joy something you'd recommend I have a look at? 09:23:49 uh.. 09:24:03 if you like functional concatenative stack based programming languages 09:24:08 I think it's drop dead sexy 09:24:18 we're talking about it on #functional 12:05:09 --- join: discobob (discobob@slc400.modem.xmission.com) joined #haskell 12:06:53 hi discobob 12:07:06 how's the disco ball? 12:26:21 multi faceted 12:26:37 awesome 12:30:58 so, are we all pretty much haskell newbies here? 12:31:38 er, I'm up to green belt 12:32:11 http://haskell.org/wiki/wiki?HaskellIrcChannel 12:32:16 do you have any questions? 12:32:22 looking for a bunch of people to learn with? 12:33:28 dunno, I've got 'Haskell: The Craft of Functional Programming' and 'The Haskell School of Expression' from my local uni library and am slowly making my way thru them. 12:33:39 ah 12:33:42 they're both nifty 12:33:50 but I like Craft more 12:33:57 how far have you gotten? 12:34:22 a few chapters in Craft 12:34:55 my progress is very slow since I have to divide my time with other things 12:35:09 http://pragmaticprogrammer.com/loty/ 12:35:12 you should check that out 12:35:44 looking 12:36:08 can't seem to pull that up? 12:36:30 here we go 12:37:31 Neither of you have looked at IFP then? 12:37:55 Introduction to Functional Programming? 12:37:57 no 12:38:08 not me 12:55:38 hmm, does 'show "hello world" qualify me for white belt? 12:55:58 it requires that you have a) installed a Haskell interpreter/compiler 12:56:03 b) learned how to operate it 12:56:12 c) learned how to print in Haskell 12:56:26 You can probably qualify for a white belt without using the "show" :-) 12:56:32 I've got GHC and Hugs98 for windows 12:56:36 "print in Haskell"? 12:57:07 currently playing around with Hugs98 12:57:10 That doesn't print in Haskell, it returns a value of type String. The implementatino then sticks it on the screen on the assumption you want to know what your program did 12:57:35 heh 12:57:36 ok 13:16:01 From the Hugs docs "You cannot create new definitions at the command prompt---these must be placed in files and loaded, as described later. The definition of fib in the last example above is local to that expression and will not be remembered for later use. Also, the expressions entered must fit on a single line." 13:16:09 That's kinda annoying 13:16:33 yah it is 13:16:41 but emacs helps 13:19:22 *cough* :-P 13:19:27 * shapr grins 13:19:41 unless you're Igloo, in which case it's vim 13:19:46 heh 13:20:01 haskell-mode in emacs lets me hit C-c C-l to load the file I'm editing into either ghci or hugs 13:20:12 cool 13:20:22 a pity I don't know emacs 13:20:31 it's a whole project in itself 13:20:32 * discobob is a vim man as well 13:21:16 Ah, I use :e in hugs to load vim rather than that way round 13:21:36 Although I suspect you could do the equivalent in vim 14:04:20 --- quit: shapr ("shooting people") 14:55:59 --- quit: discobob ("Client Exiting") 16:12:33 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 16:52:43 --- join: jemfinch (~jemfinch@rnie-99-168.resnet.ohio-state.edu) joined #haskell 16:59:00 --- join: jemfinch` (~jemfinch@rnie-99-168.resnet.ohio-state.edu) joined #haskell 16:59:14 --- quit: jemfinch () 17:28:27 wheee 17:43:59 well now 17:44:16 --- topic: set to 'Functional Programming, that's the opposite of Dysfunctional Programming (like VB) | we be loggin' http://tunes.org/~nef/logs/haskell/ | welcome to the Haskell Dojo | julien is up to white belt! jewel and shapr are up to green belt!' by shapr 18:07:33 --- join: slevin (~Snak@66-108-61-75.nyc.rr.com) joined #haskell 18:08:29 hi slevin 18:08:49 hello 18:09:13 are you new to Haskell? or do you already know it? 18:09:24 supernew 18:09:46 are you looking for a group of people to learn Haskell with? 18:09:57 or do you have some questions? 18:11:01 no plans, I just thought I would see what was being discussed 18:12:14 at the moment, the european is either asleep, or should be 18:12:25 er, "european contingent" 18:12:57 --- quit: slevin ("bye") 18:13:18 ok never mind then 18:21:35 --- quit: PragDave ("Client Exiting") 18:40:19 --- quit: pHa ("Reconnecting") 18:40:23 --- join: pHa (sjh@207.164.213.98) joined #haskell 18:43:38 --- nick: LoganZzZz -> Logan 22:17:23 --- quit: shapr (carter.openprojects.net irc.openprojects.net) 22:17:23 --- quit: Heffalump (carter.openprojects.net irc.openprojects.net) 22:17:23 --- quit: Igloo (carter.openprojects.net irc.openprojects.net) 22:17:23 --- quit: dennisb (carter.openprojects.net irc.openprojects.net) 22:17:24 --- quit: jewel (carter.openprojects.net irc.openprojects.net) 22:17:24 --- quit: jemfinch` (carter.openprojects.net irc.openprojects.net) 22:17:24 --- quit: Logan (carter.openprojects.net irc.openprojects.net) 22:17:24 --- quit: jlb (carter.openprojects.net irc.openprojects.net) 22:17:24 --- quit: dmiles (carter.openprojects.net irc.openprojects.net) 22:22:07 --- join: jewel (~jleuner@57.66.12.99) joined #haskell 22:22:07 --- join: dennisb (~dennis@as2-4-3.an.g.bonet.se) joined #haskell 22:22:09 --- join: shapr (~user@p-c2fbabb9.easy.inet.fi) joined #haskell 22:22:09 --- join: Igloo (~igloo@c93.keble.ox.ac.uk) joined #haskell 22:22:09 --- join: Heffalump (ganesh@munchkin.comlab.ox.ac.uk) joined #haskell 22:22:12 --- join: jemfinch` (~jemfinch@rnie-99-168.resnet.ohio-state.edu) joined #haskell 22:22:12 --- join: jlb (~ktk@jeremeydsl-3.mylinuxisp.com) joined #haskell 22:22:12 --- join: dmiles (~alife@sense-sea-MegaSub-2-56.oz.net) joined #haskell 22:22:12 --- join: Logan (~logan@up112.blacksburg.ntc-com.net) joined #haskell 22:22:35 --- join: sausar (~sausar@12-235-41-29.client.attbi.com) joined #haskell 22:22:43 --- part: sausar left #haskell 22:39:37 --- quit: jewel (Read error: 110 (Connection timed out)) 22:43:51 --- quit: Logan (Remote closed the connection) 22:45:35 --- join: Logan (~logan@up112.blacksburg.ntc-com.net) joined #haskell 22:51:57 Hmm, can't figure out what's wrong with this: 22:51:58 rowends :: [Int] 22:51:58 rowends = map (\ x -> (x * (x + 1)) div 2) [1..] 22:52:22 I get: 22:52:23 triver.hs:2: 22:52:23 No instance for (Num ((a -> a -> a) -> t -> Int)) 22:52:23 arising from the literal `1' at triver.hs:2 22:52:23 In the second argument of `map', namely `[1 .. ]' 22:52:29 (and several other errors) 23:20:39 it should be `div` 23:21:30 Ohhhh. 23:21:36 I'm so blind. 23:22:07 Wow, that was the only compile error in over 100 lines. A first! 23:22:13 nice 23:22:32 Oh, wait, there were a few minor things before then, I guess I should count those as well. 23:22:35 it's very easy to do misstakes like that, everyone does it.. 23:22:37 Still, those were more like typos. 23:22:49 I usually have a dozen errors that are caught by the type system. 23:23:17 Now to fix the bugs. 23:23:27 that is something that usually decreases when one is used to haskell 23:23:40 (I assume you are not, but what do I know) 23:24:10 I get them even in C alltough i've written C for many years and the typesystem is simple 23:25:30 Hmm, I've been writing C for far too long to notice. 23:27:07 but in C type errors are very simple to fix 23:28:12 Well, type errors in haskell usually result from a mistake on my part regarding precedence or improperly formed expressions. 23:28:25 Whereas in C I understand all the syntax. 23:59:59 --- log: ended haskell/02.01.25