←2012-01-12 2012-01-13 2012-01-14→ ↑2012 ↑all
00:01:40 -!- Klisz has quit (Ping timeout: 240 seconds).
00:03:23 -!- Guest50440 has joined.
00:05:46 <kallisti> `pastelogs
00:05:49 <kallisti> `pastelog
00:06:08 <kallisti> `log >.*palindromes
00:06:17 <HackEgo> http://codu.org/projects/hackbot/fshg/index.cgi/raw-file/tip/paste/paste.9465
00:06:42 <HackEgo> No output.
00:06:57 <kallisti> `log \>.*palindromes.*iterate
00:07:19 <HackEgo> http://codu.org/projects/hackbot/fshg/index.cgi/raw-file/tip/paste/paste.15923
00:07:26 <HackEgo> 2012-01-13.txt:00:06:57: <kallisti> `log \>.*palindromes.*iterate
00:08:56 <kallisti> http://en.wikipedia.org/wiki/Palindromic_number
00:09:01 <kallisti> every number is a palindromic number...
00:09:17 <kallisti> there exists at least one base in which that number is a palindrome.
00:09:48 <oerjan> actually, infinitely many
00:10:41 <monqy> for any number n, all bases m > n?
00:10:57 <monqy> e
00:11:00 <monqy> yes
00:11:31 <monqy> i mistyped the empty string and then fumbled a bit but now i'm ok
00:11:57 <oerjan> also m=n-1, it seems
00:12:05 -!- NihilistDandy has quit (Quit: Linkinus - http://linkinus.com).
00:12:10 <oerjan> http://en.wikipedia.org/wiki/Strictly_non-palindromic_number
00:13:38 <kallisti> a
00:13:43 <kallisti> oopses mistyped empty string
00:13:49 <kallisti> I meant to say:
00:21:07 <kallisti> oerjan: m = n-2 as well, for most bases I think
00:21:38 -!- myndzi has quit (Read error: Connection reset by peer).
00:21:39 <oerjan> um no, that's 12
00:21:50 <kallisti> oh rite
00:21:57 <kallisti> that's not a palindrome ha ha ha ha ha ha ha ha ha
00:21:58 <kallisti> ha
00:22:04 <oerjan> ^ha
00:22:04 <fungot> ha. ha. ha ha. ha ha ha. ha ha ha ha ha. ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ...too much output!
00:22:08 -!- myndzi has joined.
00:22:28 <kallisti> in my opinion bash has the best support for infinite data structures.
00:22:42 <oerjan> i...c
00:23:13 <monqy> hi
00:23:20 <kallisti> maybe the human mind is an infinite data structure.
00:23:25 <monqy> hi
00:23:48 <kallisti> the human body is like a cellular automata of infinite structures.
00:24:06 <kallisti> an
00:24:09 <kallisti> infinite matrix of solidity
00:24:15 <monqy> hi
00:25:15 <kallisti> if our minds are like operating systems, does that mean our operating system has a really shitty memory addressing scheme?
00:25:33 <kallisti> how many cores does it have?
00:25:41 <kallisti> :>
00:25:48 <monqy> mysterys of life
00:32:45 <oerjan> a few billion cores
00:34:49 -!- Guest50440 has quit (Quit: SLEEP, GLORIOUS SLEEP).
00:57:26 -!- esowiki has joined.
00:57:31 -!- esowiki has joined.
00:57:31 -!- esowiki has joined.
00:58:30 -!- esowiki has joined.
00:58:35 -!- esowiki has joined.
00:58:35 -!- esowiki has joined.
00:59:11 -!- esowiki has joined.
00:59:16 -!- esowiki has joined.
00:59:16 -!- esowiki has joined.
00:59:42 -!- esowiki has joined.
00:59:47 -!- esowiki has joined.
00:59:47 -!- esowiki has joined.
01:00:26 -!- esowiki has joined.
01:00:30 -!- esowiki has joined.
01:00:31 -!- esowiki has joined.
01:01:06 -!- esowiki has joined.
01:01:10 -!- esowiki has joined.
01:01:11 -!- esowiki has joined.
01:01:43 -!- esowiki has joined.
01:01:48 -!- esowiki has joined.
01:01:48 -!- esowiki has joined.
01:02:29 -!- esowiki has joined.
01:02:34 -!- esowiki has joined.
01:02:34 -!- esowiki has joined.
01:03:09 -!- esowiki has joined.
01:03:14 -!- esowiki has joined.
01:03:14 -!- esowiki has joined.
01:03:44 -!- esowiki has joined.
01:03:49 -!- esowiki has joined.
01:03:49 -!- esowiki has joined.
01:04:28 -!- esowiki has joined.
01:04:28 -!- glogbot has joined.
01:04:28 <?unknown?> [freenode-info] channel flooding and no channel staff around to help? Please check with freenode support: http://freenode.net/faq.shtml#gettinghelp
01:04:33 -!- esowiki has joined.
01:04:33 -!- esowiki has joined.
01:54:34 -!- azaq23 has joined.
01:54:48 -!- azaq23 has quit (Max SendQ exceeded).
01:55:16 -!- azaq23 has joined.
02:19:59 <kallisti> @src iterate
02:20:00 <lambdabot> iterate f x = x : iterate f (f x)
02:22:28 -!- oerjan has set topic: I'm not a number, I'm a cheesy and grating topic | http://codu.org/logs/_esoteric/.
02:33:44 <kallisti> @src (.)
02:33:44 <lambdabot> (f . g) x = f (g x)
02:33:44 <lambdabot> NB: In lambdabot, (.) = fmap
02:35:13 <oerjan> @src (++)
02:35:14 <lambdabot> [] ++ ys = ys
02:35:14 <lambdabot> (x:xs) ++ ys = x : (xs ++ ys)
02:35:14 <lambdabot> -- OR
02:35:14 <lambdabot> xs ++ ys = foldr (:) ys xs
02:35:21 <oerjan> @src flip
02:35:21 <lambdabot> flip f x y = f y x
02:35:31 <oerjan> some NB's lacking
02:36:39 <oerjan> :t flip
02:36:40 <lambdabot> forall (f :: * -> *) a b. (Functor f) => f (a -> b) -> a -> f b
02:45:07 <shachaf> More like Nofunctor!
02:57:01 -!- cswords has joined.
03:18:48 <Sgeo> kallisti, there was an update
03:18:55 <kallisti> I see.
03:19:15 -!- oerjan has set topic: I'm not a number, I'm a cheesy and grating update | http://codu.org/logs/_esoteric/.
03:49:07 <kallisti> @src (>=>)
03:49:07 <lambdabot> Source not found. You speak an infinite deal of nothing
03:49:34 <oerjan> @src >=>
03:49:34 <lambdabot> Source not found. BOB says: You seem to have forgotten your passwd, enter another!
03:49:58 <oerjan> it's probably (f >=> g) x = f x >>= g , anyway
03:59:21 <kallisti> that fills up the entire width of my terminal
03:59:45 <oerjan> that leaves one char at the end of mine
04:00:00 <kallisti> ah so you too do not maximize
04:00:05 <kallisti> we are non-maximize buddies then
04:01:10 <kallisti> would it be accurate to say that...
04:01:24 <kallisti> =<< and <=< are analogous to $ and . ?
04:01:55 <oerjan> a bit.
04:02:15 <oerjan> although =<< needs to fight with <*> / ap for that.
04:02:23 <kallisti> indeed
04:02:31 <kallisti> <*> is a different kind of application. :P
04:02:54 <oerjan> . is generalized in Control.Category, and Kleisli is one based on <=<
04:02:54 <kallisti> it's like application lifted into another type.
04:03:20 <kallisti> $ should be generalized somehow.
04:03:25 <kallisti> ......er
04:03:30 <kallisti> I guess that's ap
04:04:07 <oerjan> fmap is another
04:04:24 <oerjan> which lambdabot uses for .
04:04:53 <kallisti> you're completely clusterfucking my analogy.. :P
04:04:57 <oerjan> and lambdabot's weird flip is yet one
04:04:59 <oerjan> :t flip
04:05:01 <lambdabot> forall (f :: * -> *) a b. (Functor f) => f (a -> b) -> a -> f b
04:05:11 <kallisti> BIND FUNCTOR
04:05:25 <kallisti> except the f is on the outside
04:05:32 <kallisti> f (a ->b) instead of a -> f b
04:05:41 <oerjan> it's all about different ways to put in the f's
04:05:47 <kallisti> yes I've noticed.
04:06:20 <kallisti> flip is some kind of mixture of bind and ap isn't it?
04:06:52 <oerjan> flip f x = fmap ($ x) f
04:07:02 <kallisti> >_> oh
04:07:32 <kallisti> ah yes
04:07:39 <kallisti> I see how that generalizes the function case
04:07:53 <oerjan> and there's also comonad whateverit'scalled
04:08:03 <kallisti> yes of course...
04:08:10 <kallisti> (what?)
04:08:15 <oerjan> extend, iirc
04:08:18 <oerjan> :t extend
04:08:19 <lambdabot> Not in scope: `extend'
04:08:27 <oerjan> ):
04:08:31 <kallisti> @src Comonad
04:08:31 <lambdabot> Source not found.
04:08:43 <oerjan> i guess lambdabot may not have them at all
04:08:47 <oerjan> :k Comonad
04:08:48 <lambdabot> Not in scope: type constructor or class `Comonad'
04:08:53 <oerjan> :k CoMonad
04:08:54 <lambdabot> Not in scope: type constructor or class `CoMonad'
04:08:57 <kallisti> yes functions are not pokemon.
04:09:05 <oerjan> :k Monad
04:09:06 <lambdabot> Class `Monad' used as a type
04:09:06 <lambdabot> In the type `Monad'
04:09:11 <oerjan> sheesh
04:10:00 <oerjan> @hoogle extend
04:10:00 <lambdabot> System.Posix.Terminal ExtendedFunctions :: TerminalMode
04:10:00 <lambdabot> Text.Regex.Posix.Wrap compExtended :: CompOption
04:10:00 <lambdabot> Text.Regex.Posix.String compExtended :: CompOption
04:10:06 <oerjan> didn't think so
04:10:53 <kallisti> ah yes the classic regex comonad
04:11:28 <oerjan> careful, it might exist
04:11:40 <kallisti> well Parsec is pretty close I guess.
04:11:49 <oerjan> ...is a Monad.
04:11:53 <kallisti> oh rite
04:12:04 <kallisti> see...
04:12:10 <kallisti> I shouldn't talk so much when I'm tired.
04:12:25 <oerjan> aslobutely
04:12:50 <monqy> :t (=>>)
04:12:51 <lambdabot> Not in scope: `=>>'
04:12:53 <monqy> lambdabot...................
04:12:56 <monqy> how could you
04:13:04 <oerjan> oh that maybe was it
04:13:12 <monqy> (=>>) is flip extend
04:13:13 <oerjan> @hoogle (=>>)
04:13:13 <lambdabot> No results found
04:13:21 <monqy> at least I think it's flip extend??
04:13:38 <kallisti> extend flip
04:13:53 <kallisti> extend tail
04:13:54 <oerjan> :t (>>= flip)
04:13:55 <lambdabot> forall (f :: * -> *) a b. (Functor f) => (a -> f (a -> b)) -> a -> f b
04:14:04 <monqy> extend is defined by the Extend typeclass in Data.Functor.Extend which is exported by Control.Comonad, I think?????????
04:14:18 <monqy> and all Comonads are Extends
04:15:20 <monqy> I thought lambdabot had this stuff though
04:17:07 <kallisti> oerjan: you should make sure that the f has been put in all the places and if not list out all of combinations you can put the f in and then write functions for them
04:19:56 <oerjan> O KAY
04:21:33 <kallisti> here's a good one
04:21:46 <kallisti> f a -> f b -> (f a -> f b)
04:22:19 <monqy> const const?
04:22:28 <kallisti> yes yes
04:22:42 <kallisti> no?
04:22:43 <kallisti> maybe
04:22:49 <monqy> :t const const
04:22:50 <lambdabot> forall a b b1. b1 -> a -> b -> a
04:23:03 <monqy> :t const const :: (Functor f) => f a -> f b -> (f a -> f b)
04:23:04 <lambdabot> forall (f :: * -> *) a b. (Functor f) => f a -> f b -> f a -> f b
04:23:31 <kallisti> oh okay.
04:23:54 <kallisti> here's another good one:
04:24:10 <kallisti> (f a -> f b) -> (f a -> f b)
04:25:04 -!- qfr has left.
04:25:09 <kallisti> I will pay you $200 to figure this one out
04:25:33 <kallisti> unsolved porbelm fro matemathics
04:27:42 <kallisti> > id id id id id id id id 2
04:27:42 <lambdabot> 2
04:27:54 <kallisti> > fix id 2
04:27:58 <lambdabot> mueval-core: Time limit exceeded
04:28:16 <kallisti> damn you consequences of halting problem.
04:29:57 <monqy> hi
04:30:08 <kallisti> .hi
04:40:36 -!- MSleep has changed nick to MDude.
05:06:22 <shachaf> kallisti: "consequences of the halting problem" being "everything"?
05:06:29 <shachaf> (Everything provable, anyway.)
05:09:43 <Lymia> ...
05:09:46 <Lymia> I'm speechless.
05:09:58 <Lymia> I downloaded a Windows game, and tried to run it on WINE. It did not work.
05:10:08 <monqy> :o
05:10:10 <Lymia> Since it included source, I tried typing in "make"
05:10:24 <Lymia> After adding a few imports, against all reason, it actually compiled...
05:10:41 <Lymia> Ya-- Segmentation Fault
05:10:45 <Lymia> ;.;
05:11:06 <monqy> :o
05:11:13 <oerjan> but did you try running _that_ in wine?
05:11:16 * oerjan helpful
05:11:50 <Lymia> oerjan, I compiled it to a Linux native binary, dummy.
05:12:14 <shachaf> If you ran it under WINE you might get a General Protection Fault.
05:12:40 <Lymia> The Linux version, at least, manages to bring up a window before crashing.
05:17:52 -!- pikhq has joined.
05:18:27 -!- pikhq_ has quit (Ping timeout: 268 seconds).
05:20:10 -!- augur has quit (Read error: Connection reset by peer).
05:20:34 -!- augur has joined.
05:34:49 <kmc> "Even in math there seems to be a general consensus about which problems are hard to solve, and what constitutes a good solution. But hacking is like writing. Who can say which of two novels is better? Certainly not the authors."
05:34:50 <kmc> ...
05:37:30 -!- pikhq_ has joined.
05:37:38 -!- pikhq has quit (Ping timeout: 240 seconds).
05:50:26 <shachaf> I thought it was like painting.
05:56:49 <kmc> all the best writers of history have been painters and vice versa
05:56:51 <kmc> duh, everyone knows that
06:14:35 -!- azaq23 has quit (Quit: Leaving.).
06:27:36 -!- MDude has quit (Ping timeout: 240 seconds).
06:40:59 -!- oerjan has quit (Quit: Good night).
06:56:46 <shachaf> kmc: Doesn't look like your tolerance for doses of #-blah is increasing with practice.
06:57:34 <kmc> no it's just wli
06:59:43 <pikhq_> Determined to die, so why bother trying to find alternatives. That's him.
07:00:27 <kmc> i mean he has got a really raw deal in life
07:00:35 <kmc> his bitterness is totally justified
07:00:44 <kmc> but that doesn't make it any more pleasant to be around
07:01:22 <pikhq_> True, *but* nevertheless. He might actually be able to wrangle refugee status. Or leave the US somehow...
07:07:42 <kmc> "Thinking in typeclasses is IMO the best thing to do: it's really the most Haskellish."
07:08:52 <kmc> anyway I'm surprised people are apparently willing to pay $250/day to program in Haskell rather than another language
07:08:56 <kmc> re http://www.reddit.com/r/haskell/comments/odv3t/welltyped_are_hiring_haskell_consultant/
07:09:17 <shachaf> Are people actually willing to do that?
07:09:38 <kmc> i was talking about this in #haskell-blah but wli took over with his AMERIKKKA rants so now y'all get to hear about it
07:09:40 <shachaf> It was copumpkin's assertion that if someone takes the job, then they're willing to do that.
07:10:01 <kmc> shachaf, it's possible the number is too low and that well-typed won't get any applications
07:10:17 <kmc> i mean, price discovery is hard, double so in labor markets
07:10:27 <kmc> i'm taking one party's bid as a crude approximation of market price
07:11:09 <kmc> i think one danger is that you get someone with intermediate Haskell skill who is super naive
07:12:22 <kmc> someone who thinks Haskell magically eliminates all of the annoyances of programming in the real world
07:12:41 <pikhq_> Alas, Haskell doesn't eliminate the real world.
07:12:44 <pikhq_> That's what @'s for!
07:13:11 <kmc> if the language really were as good as those people think, it would be worth the pay cut
07:13:15 <kmc> but it's not, and no language ever will be
07:13:40 <kmc> it's just a pretty good programming language
07:13:57 <kmc> and there are many other companies that will pay you twice as much to use a different pretty good programming language
07:14:13 <Sgeo> What are some other pretty good programming languages?
07:15:06 <pikhq_> And I'm pretty sure $55k is more like (somewhat low) starting wages for a halfway competent programmer literally just out of college...
07:15:15 <shachaf> kmc: I think the consensus in that thread in general was that they're underpaying.
07:15:30 <kmc> pikhq_, last I knew Google, Facebook, etc. would start around $80k, plus health insurance and other benefits
07:15:33 <pikhq_> ... In the Midwest.
07:15:51 <kmc> if you're working remotely from the USA, take like $500/mo off that Well-Typed money for health insurance
07:16:26 <kmc> Sgeo, languages i like include Haskell, Python, OCaml, Clojure, Scheme, C (for certain things)
07:16:29 <kmc> none of them is perfect
07:16:56 <kmc> for many tasks none of the first five will dominate, assuming you have skill in all
07:17:11 <pikhq_> kmc: Sorry, my scale of wages is somewhat set by the region I live in, which has significantly lower cost-of-living than the Valley.
07:17:20 <kmc> fair enough
07:17:36 <kmc> and that is one reason Well-Typed's offer might be more reasonable than it looks
07:17:38 <kmc> you can live somewhere cheap
07:17:49 <kmc> but cheap places suck
07:17:55 <pikhq_> Yeah.
07:18:13 <kmc> either you really need the money, in which case you can get more anyway, or you're young and healthy and single, in which case you probably don't want to live in the middle of nowhere
07:18:29 <kmc> (i mean that's a false dichotomy but you get the point)
07:18:46 <pikhq_> Well, you're presuming a fairly high level of skill.
07:18:53 <pikhq_> Which makes the dichotomy pretty applicable.
07:19:27 <kmc> well also you might be stuck in the middle of nowhere for other reasons
07:20:19 <kmc> personally i think working from home is Not For Me
07:20:34 <pikhq_> I've done that. I've learned the hard way that it's Not For Me.
07:20:47 <kmc> why?
07:21:16 <pikhq_> I've discovered I'm not very productive in a home environment at all.
07:21:19 <kmc> one problem for me was the lack of separation between "work" and "not-work", meaning I'd spend all day not-working but also spend all day feeling guilty about the fact that I should be working
07:21:25 <pikhq_> Like some mental switch in my head goes "home" = "fuck around"
07:21:51 <kmc> with a physical office job I might enter that state too but only for 8-10 hours at a time :)
07:21:59 <Sgeo> Nohjf
07:22:01 <Sgeo> Niughji
07:22:02 <Sgeo> Night
07:22:06 <kmc> O_O
07:22:08 <kmc> 'night Sgeo
07:22:08 <monqy> night sgeo
07:22:48 <kmc> the other problem was lack of contact with my coworkers and employers
07:22:59 <kmc> just seeing them around being productive makes me more productive
07:23:12 <kmc> it's not about explicit communication
07:23:19 <pikhq_> That, too, is a factor.
07:23:23 <kmc> (though in my experience with WFH we were also bad about explicit communication)
07:23:55 <kmc> some companies have employees who WFH most of the time and come in like one day a week
07:23:58 <kmc> maybe i'd like that
07:26:49 <shachaf> I may have an ingrown fingernail.
07:26:59 <kmc> sucks :(
07:27:14 <shachaf> Hopefully it'll pass on its own. Sometimes that happens.
07:27:21 <kmc> really?
07:28:48 <shachaf> Well, sometimes I think "this might be an ingrown fingernail" and then the thing passes on its own.
07:28:52 <kmc> heh
07:29:03 <kmc> is this a subtle hint that the previous topic is less pleasant than an ingrown fingernail
07:29:29 <shachaf> I think the previous topic was *more* pleasant than an ingrown fingernail, come to think of it.
07:29:44 <shachaf> But if I'm going to suffer, why not share it with the rest of you?
07:29:51 <kmc> why not share it with wli
07:31:18 <shachaf> What's a place where I can ask experts questions about category theory without bothering to figure out anything about category theory, including what my question means?
07:31:32 <kmc> is the answer "#haskell"?
07:31:50 <shachaf> The answer is probably "don't".
07:32:59 <kmc> i mean probably the best reason to take a pay cut for a job using Haskell specifically
07:33:08 <kmc> is that it's a proxy for the kind of people you'll be working with
07:33:40 <kmc> but i think the dollar value there is pretty low
07:34:44 <kmc> i'm not sure how much it tells you versus being extra attentive during the process of interview etc.
07:35:04 <kmc> (i think it's much more valuable in the other direction, for companies assessing candidates)
07:35:06 <pikhq_> kmc: Also, much more relevant if you're working in the office.
07:35:07 <shachaf> Well, in this case it's not just "the kind of people" but a specific group of people in particular.
07:35:33 <kmc> right
07:37:23 <kmc> pikhq_, why more relevant if you're working in the office?
07:38:16 <kmc> by "kind of people" i mean that they're probably pretty smart and have some respect for sophisticated and unconventional approaches, stuff like that
07:38:29 <kmc> not really like the personality aspect
07:39:10 <kmc> i'm thinking of stuff that is relevant if you're working together on some code, whether or not you're in the same physical location
07:40:20 <pikhq_> Ah.
07:40:50 <kmc> i doubt you can infer that much about personality from someone's choice of programming language
07:41:08 <kmc> except for Lisp of course
07:41:25 <pikhq_> :P
07:41:38 <kmc> Lisp programmers are all geniuses from a higher plane of existence, tragically misunderstood in this brutal, unenlightened era
07:42:08 -!- cheater has quit (Ping timeout: 240 seconds).
07:42:34 <kmc> destined to die young and crazy of syphilis, like the great painters and writers
07:42:46 <pikhq_> Also doomed to die rich.
07:42:51 <pikhq_> :P
07:42:58 <kmc> no hackers are painters/writers
07:43:07 <kmc> dying rich is super nega-cred for those folks
07:43:21 <kmc> you're supposed to die poor and then have your art become ultra-valuable hundreds of years later
07:43:23 <pikhq_> Then what about Paul Graham?
07:43:30 <pikhq_> Oh, wait, right. Do as I say, not as I do.
07:43:41 <kmc> :D
08:00:15 -!- cheater has joined.
08:41:16 -!- cheater has quit (Ping timeout: 240 seconds).
08:59:12 -!- GreaseMonkey has quit (Quit: The Other Game).
09:06:56 -!- cheater has joined.
09:12:24 -!- pikhq_ has quit (Ping timeout: 252 seconds).
09:12:25 -!- pikhq has joined.
09:34:11 -!- augur has quit (Read error: Connection reset by peer).
09:34:33 -!- augur has joined.
09:49:15 <fizzie> There's some sort of a thing that in some PDF files, evince has replaced capital-sigma sum signs with large dots. This is not the first such file I've seen.
10:08:43 -!- elliott has joined.
10:08:51 <elliott> -NickServ- Last failed attempt from: elliott!~elliott@c-69-181-214-206.hsd1.ca.comcast.net on Jan 13 03:36:38 2012.
10:09:01 <elliott> My nick, fucker.
10:09:32 -!- Vorpal has joined.
10:09:41 <shachaf> Oh my, is that my IP address?
10:09:43 <shachaf> (No.)
10:10:01 <fizzie> elliott: "My, nickfucker."
10:15:08 <monqy> my oh my
10:15:13 <monqy> nickfuckers can only mean trouble
10:16:11 <elliott> 07:09:38: <kmc> i was talking about this in #haskell-blah but wli took over with his AMERIKKKA rants so now y'all get to hear about it
10:16:21 <elliott> shachaf: I'm so glad I didn't listen to you when you told me to join -blah.
10:17:09 <kmc> hi elliott
10:17:13 <shachaf> elliott: FASCIST
10:17:24 * shachaf expected to be asleep a couple of hours ago.
10:17:25 <elliott> hi monqy
10:17:26 <elliott> *kmc
10:17:38 <shachaf> And by "expected" I mean "planned but didn't really expect".
10:17:50 <monqy> hi elliott
10:18:49 * Lymia flails
10:18:50 <elliott> shachaf: You should pay someone to knock you unconscious at a prearranged time.
10:18:52 <Lymia> CRAP CRAP CRAP
10:18:57 <Lymia> Run under valgrind? No segfault
10:19:01 <Lymia> Run without valgrind? Segfault
10:19:02 <shachaf> elliott: I'll be happy to pay you to do that.
10:19:03 <Lymia> Heisingbug... :(
10:19:17 <elliott> shachaf: Okay. My going rate is $2,000/knockout.
10:19:19 <shachaf> Lymia: Does valgrind report errors?
10:19:26 <Lymia> shachaf, I'm going to examine that
10:19:29 <shachaf> elliott: I have these wooden nickels...
10:19:56 <elliott> shachaf: [Hilarious Monkey Island quote I'm too tired to think of.]
10:20:11 <elliott> "In the Mayan calendar, 2012 is suppose to be a year of deep cleansing and rebirth for the world. In this spirit, I’ve been branching out into new fields and broadening my conceptual view of software development."
10:20:13 <elliott> Thanks, Mayans.
10:20:16 <elliott> Thayans.
10:21:22 <monqy> i have these nickel woodens
10:21:25 <monqy> absolutely useless
10:22:54 <elliott> wickel noodens
10:22:56 <shachaf> elliott: Why am I not on that list?
10:23:12 <shachaf> "shachaf, IRC idling genius"
10:24:10 <kmc> elliott, yeah i lolled at that post
10:24:13 <elliott> shachaf: Wait, what list?
10:24:29 <shachaf> elliott: From the post you just quoted.
10:24:46 <elliott> Oh. I didn't actually read beyond that.
10:25:05 <elliott> Wait, it's literally just a list of people who use functional languages?
10:25:07 <shachaf> Well, thanks for nothing, elliott. Thfnelliott.
10:25:25 <shachaf> elliott: No, it also has Haskell B. Curry.
10:26:06 <elliott> shachaf: He programmed in ML.
10:26:19 <elliott> It's like how Jesus was Jewish.
10:26:32 <elliott> 07:21:59: <Sgeo> Nohjf
10:26:32 <elliott> 07:22:01: <Sgeo> Niughji
10:26:32 <elliott> 07:22:02: <Sgeo> Night
10:26:35 <elliott> godrijgromorngoirdg
10:26:38 <elliott> mogirdg nogidr
10:26:39 <elliott> good morning
10:26:49 <monqy> hi ieelieiote
10:26:53 <monqy> hoe eihgleiont
10:26:55 <monqy> hi helioent
10:26:56 <elliott> 07:26:49: <shachaf> I may have an ingrown fingernail.
10:26:57 <monqy> hi heliot
10:26:59 <monqy> hi elliott
10:26:59 <shachaf> elliott: He programmed in ML like how Jesus was Jewish?
10:27:04 <elliott> shachaf: I thought that wasn't possible.
10:27:08 <elliott> At least ais said that wasn't possible.
10:27:16 <kmc> hey guys i like haskell and fp, i have nothing to say about it, just wanted you all to know
10:27:18 <elliott> Also, yes.
10:27:49 <elliott> kmc: Here's my spj shrine *strokes framed photo lovingly*
10:28:00 <elliott> Wait, why haven't I set up an SPJ shrine yet?
10:28:06 <elliott> That's like #1 on my list of things to do.
10:28:51 <elliott> 07:43:21: <kmc> you're supposed to die poor and then have your art become ultra-valuable hundreds of years later
10:29:02 <elliott> kmc: which is why you should found a startup that everybody hates and is lost to the mists of time
10:29:09 <elliott> make sure that the servers keep running when you die
10:29:14 -!- Lymia has changed nick to Madoka-Kaname.
10:29:22 <elliott> and in a few hundreds of years everyone will rediscover it and it'll become the talk of the web2.0sphere
10:29:32 <elliott> artist style(tm)
10:29:54 <monqy> web2.0 in hundreds of years?
10:30:02 <monqy> haven't they moved on to web a billion point oh by then
10:30:10 <elliott> monqy: no its classique
10:30:16 <elliott> "Father of Haskell foundations" hahaha i didn't even
10:30:18 <elliott> see that part
10:30:19 <monqy> oh a special sphere
10:30:25 <monqy> for web2.0 archaeologists
10:31:20 <elliott> everyone has their own sphere in the future
10:31:57 <shachaf> elliott: Oh, you got that post from /r/haskell.
10:32:00 <shachaf> I like how it has 4 points.
10:32:22 <shachaf> I should do some experiments on how bad I can make posts before they get downvoted on /r/haskell.
10:32:33 <elliott> shachaf: I'm balancing the satisfaction of commenting with something like "You forgot to add the content." and the chance that it'll make people think I'm a jerk and not upvote me on SO.
10:32:53 <shachaf> elliott: That's why you make the second account.
10:33:01 <elliott> http://stackoverflow.com/questions/8834582/is-haskell-a-lisp-dialect ;; this question got 3 upvotes
10:33:09 <shachaf> Anyway, people upvote jerks on SO.
10:33:22 <elliott> http://stackoverflow.com/questions/8829194/why-are-types-with-no-data-constructors-valid ;; this one got 10
10:34:16 <shachaf> Did you know that typedefs can shadow variable names in C?
10:34:36 <shachaf> int foo; void v() { typedef int foo; ... }
10:34:47 <elliott> shachaf: Isn't that what causes that context-sensitive bit?
10:35:00 <elliott> "Waterstones, the bookshop, has dropped the apostrophe in its trading name and logo, sparking outrage among some of its customers.
10:35:00 <elliott> "It's just plain wrong", said John Richards, chairman of the Apostrophe Protection Society"
10:35:23 <shachaf> "Its just plain wrong", wrote John Richard's, chairman of the Apostrophe Protection Society"
10:35:30 <elliott> *'Society
10:35:39 <shachaf> "Its just plain wrong", wrote John Richard's, chairman of the Apostrophe Protection *'Society"
10:35:50 <fizzie> I was going to go with S'ociety, but that's all right too.
10:36:08 <monqy> ch'man
10:36:14 <monqy> o' th'
10:36:37 <monqy> 'postraph' 'rotectin'
10:36:48 <elliott> apo'strophe
10:36:58 <elliott> "thanks for the trophe" --apo
10:37:41 <shachaf> The apostrophe, named after the apostles of Jesus Christ.
10:38:08 -!- pikhq_ has joined.
10:38:09 -!- pikhq has quit (Ping timeout: 252 seconds).
10:39:31 <elliott> Since I don't know much C I shall upvote you, but from what I DO know; WHY not use C++ instead? You'll just have your instance of a pushbutton, and call functions from within it, Instead of having 430983852 different functions in a really messy API. Tidyness disappears. However, for those of you who are experienced in both C and C++, what is the benefits of programming like a nutcracker (in C) ?
10:39:31 <shachaf> elliott: "Of course, for the single-constructor, single-item cases, newtype is preferred over data."
10:39:50 <kmc> what
10:39:53 <elliott> shachaf: Don't. I already held back the tears.
10:39:55 <kmc> nutcracker?
10:40:05 <elliott> kmc: if i suddenly say something really weird it's a quote
10:40:11 <elliott> unless it's me
10:40:12 <kmc> i got that, but?
10:40:14 <elliott> oh
10:40:21 <elliott> http://www.reddit.com/r/programming/comments/oek2t/any_interest_in_a_c_binding_to_wxwidgets_from/c3gp4si
10:40:31 <elliott> interpretation is left to the reader
10:42:00 <shachaf> elliott: I'm going to write a preprocessor for GHC that replaces all instances of "data" with "newtype" if the file remains valid.
10:43:03 <elliott> shachaf: I bet the author of that comment thinks that "newtype" exists as a separate keyword for historical reasons. :(
10:44:21 <shachaf> From today, 430983852 will be known as "the C++ overhead constant".
11:05:35 -!- monqy has quit (Quit: hello).
11:10:11 <elliott> hi
11:11:59 <kmc> <elliott> everyone has their own sphere in the future
11:12:02 <kmc> this, a thousand times
11:13:22 <elliott> kmc: deep
11:13:29 <kmc> <elliott> Wait, it's literally just a list of people who use functional languages? <shachaf> elliott: No, it also has Haskell B. Curry. <elliott> shachaf: He programmed in ML.
11:13:36 <kmc> irrelevant because Haskell was the first functional language
11:13:48 <kmc> ML is "almost-functional"
11:13:59 <kmc> source: _Gentle Introduction to Haskell 98_, chapter 1
11:20:32 <elliott> kmc: Well, I wouldn't really call ML functional either. I guess I'm a zealot.
11:20:38 <Jafet> kmc, irc is hard real time
11:20:56 <kmc> IRC is real, hard time
11:20:59 <kmc> (for computer hacking)
11:21:16 <kmc> elliott, a language can't be considered functional unless it uses {- -} for multi-line comments
11:21:23 <kmc> as should be trivially obvious to the most casual observer
11:21:45 <kmc> (in college we had a house office named Most Casual Observer)
11:21:54 <kmc> (their job was to observe things casually and thus know all)
11:22:09 <elliott> kmc: i wonder how the {--} syntax came abou
11:22:09 <elliott> t
11:22:40 <Jafet> Well, it combines the worst bits of imperative programming languages, that we don't have a use for any more
11:22:43 <Jafet> {} and --
11:22:50 <elliott> :D
11:23:28 <kmc> they represent a pair of dwarvish fire-daggers
11:23:36 <kmc> as should be trivially obvious to the most casual observer
11:23:43 <fizzie> The most causal observer.
11:24:05 <kmc> together they cast a powerful Spell of Warding +5 which prevents execution of the code by any compiler with armor class 12 or lower
11:26:43 <fizzie> fungot: All Witchaloks are hermaphroditic androgynites.
11:26:44 <fungot> fizzie: oh, no, man... i forgot. i've got some mashed potatoes over here, it means you're a math teacher.
11:27:06 <kmc> another benefit is that you can write {-∗-} should you need to represent Darth Vader's TIE Fighter Advanced x1 within Haskell source code
11:27:47 <elliott> "the ideal comment syntax is smalltalks"
11:28:05 <kmc> seriously, the Gentle Introduction does say that ML and Scheme are "almost-functional"
11:45:06 <elliott> Alas, GHC 7.0 still cannot handle equality superclasses:
11:45:06 <elliott> Rep t ~ rep
11:45:09 <elliott> Not again!
11:45:56 <kmc> alas and alack
11:46:32 -!- Phantom_Hoover has joined.
11:46:58 <elliott> this is way too difficult
11:50:22 <kmc> it works in newer GHC
11:50:44 <Phantom_Hoover> blomg
11:51:00 <Phantom_Hoover> elliott, please send me messages so I don't look like an idiot again.
11:51:38 <elliott> @tell Phantom_Hoover Hi.
11:51:38 <lambdabot> Consider it noted.
11:51:48 <Phantom_Hoover> Better.
11:51:49 <lambdabot> Phantom_Hoover: You have 1 new message. '/msg lambdabot @messages' to read it.
11:51:53 <Phantom_Hoover> @messages
11:51:53 <lambdabot> elliott said 15s ago: Hi.
11:55:42 <kmc> @tell lambdabot u suck
11:55:43 <lambdabot> Nice try ;)
11:56:22 <fizzie> @tell me something new
11:56:22 <lambdabot> Consider it noted.
11:56:30 <fizzie> I wonder how many messages "me" has.
12:00:28 <Phantom_Hoover> me's not an allowed nick, is it?
12:01:07 <fizzie> Information on me (account spb): blah blah blah.
12:01:10 <fizzie> It's someone else's.
12:08:13 <Phantom_Hoover> Whoever it is, they have MemoServ set up to prevent them getting sent anything.
12:08:26 <elliott> * me :Nick/channel is temporarily unavailable
12:08:36 <Phantom_Hoover> And they haven't been seen for 40 weeks in any case.
12:08:39 -!- elliott has changed nick to elliott_.
12:08:41 <elliott_> @messages?
12:08:42 <lambdabot> Sorry, no messages today.
12:08:46 -!- elliott_ has changed nick to ehird.
12:08:48 <ehird> @messages?
12:08:48 <lambdabot> Sorry, no messages today.
12:08:50 -!- ehird has changed nick to elliott.
12:09:03 -!- elliott has changed nick to Phantom__Hoover.
12:09:05 <Phantom__Hoover> @messages?
12:09:05 <lambdabot> Sorry, no messages today.
12:09:07 -!- Phantom__Hoover has changed nick to elliott.
12:09:24 <Phantom_Hoover> How does lambdabot deal with ident stuff?
12:10:36 <elliott> It doesn't.
12:11:47 <fizzie> They haven't used the "me" nick in 40 weeks, you mean; the account is online right now.
12:12:45 <fizzie> The owner of "you" similarly hasn't used you in 62 weeks.
12:12:57 <fizzie> I'm thinking nicknames for punnery or such.
12:15:46 -!- ais523 has joined.
12:16:05 <elliott> @hoogle try
12:16:05 <lambdabot> Control.OldException try :: IO a -> IO (Either Exception a)
12:16:06 <lambdabot> System.IO.Error try :: IO a -> IO (Either IOError a)
12:16:06 <lambdabot> Control.Exception.Base try :: Exception e => IO a -> IO (Either e a)
12:17:13 <fizzie> Trying times.
12:18:20 <elliott> :t reads
12:18:21 <lambdabot> forall a. (Read a) => String -> [(a, String)]
12:18:42 * Sgeo wants to see an example of there being more than one element in the list
12:22:12 <kmc> me too
12:23:23 -!- cheater has quit (Ping timeout: 255 seconds).
12:23:24 <Phantom_Hoover> Is try a typeclass thing then, or not?
12:23:36 <kmc> what's "a typeclass thing"
12:23:41 <kmc> mean
12:23:48 <Phantom_Hoover> Is it a typeclass method, or based on them.
12:24:01 <Phantom_Hoover> Erm, wait, no, not based on them.
12:24:18 <Phantom_Hoover> Are those functions all independently defined, or are they parts of instances?
12:24:30 <kmc> which functions? the three that hoogle mentioned?
12:24:34 <Phantom_Hoover> Yes.
12:24:35 <Sgeo> I was able to make an Exception instance without defining any methods, somehow
12:24:55 <Sgeo> It occurs to me that that doesn't mean much
12:24:56 <elliott> Phantom_Hoover: http://hackage.haskell.org/packages/archive/base/latest/doc/html/Control-Exception.html
12:25:01 <kmc> Phantom_Hoover, those are independent functions. basically, three different generations of the exception system
12:25:04 <elliott> Exception is just
12:25:09 <elliott> toException :: e -> SomeException
12:25:09 <elliott> fromException :: SomeException -> Maybe e
12:25:13 <elliott> so no, try isn't a typeclass method.
12:25:15 <kmc> Sgeo, that's expected, and documented
12:25:21 <Phantom_Hoover> Yeah, I just checked that in ghci.
12:25:35 <Sgeo> kmc, yes, but for some reason I thought that was relevant to Phantom_Hoover's question
12:25:39 <Sgeo> When it really wasn't
12:25:40 <kmc> oh
12:26:30 <Sgeo> Eh, the things need to be Typeable?
12:26:42 <kmc> Phantom_Hoover, so in standard Haskell you have try for IOError only, and then that was generalized to a larger fixed set of exceptions (in what's now Control.OldException), and then to the extensible system in Control.Exception
12:26:56 <kmc> Sgeo, yes, the extensible exception system uses Typeable
12:29:04 <kmc> basically exceptions are dynamically typed
12:29:10 <kmc> and catching does a run-time type check
12:29:33 <ais523> <spambot> The use of the phrase "pozycjonowanie google cottages" can be considered a little bit misleading.
12:29:47 <elliott> :D
12:29:53 <kmc> is that polish or gibberish
12:30:06 <elliott> ais523: I'm glad you have correctly left alone the asd pages
12:30:08 <elliott> as they're claerly not spam
12:30:09 <ais523> I think it's a foreign language from context, polish wouldn't surprise me
12:30:13 <elliott> <Sgeo> Eh, the things need to be Typeable?
12:30:17 <kmc> seems to mean "positioning" in Polish
12:30:18 <elliott> Sgeo: that's how the entire exception system works
12:30:19 <ais523> elliott: I haven't reached them yet
12:30:41 <ais523> but meh, I'll leave them
12:30:42 <elliott> Sgeo: if you unlayer the abstractions far enough, the exception system is based on comparing two strings and using unsafeCoerce if they're equal
12:30:49 <elliott> which is: gross
12:31:29 <kmc> anything is gross if you unlayer the abstractions far enough
12:31:47 <elliott> kmc: yeah but you can still define your own Typeable instances today :P
12:31:58 <kmc> yeah that's unfortunate
12:32:36 <elliott> data a :=: b where { Refl :: a :=: a}; class TypeEq a where { typeEq :: (TypeEq b) => Maybe (a :=: b) }
12:32:41 <elliott> and a magic deriving (TypeEq)
12:32:54 <elliott> that's what we need, it would be perfectly safe ... and also really confusing
12:33:14 <kmc> you want things besides decidable equality
12:33:30 <elliott> kmc: do you? I thought that's all Exception needed
12:33:31 <elliott> cast
12:33:39 <kmc> it's convenient if you can order and hash TypeReps
12:33:47 <elliott> kmc: Typeable is useful, yeah
12:33:47 <kmc> maybe Exception doesn't need that
12:33:49 <kmc> but in general
12:33:49 <elliott> but Exception doesn't need it
12:34:06 <elliott> well i think it's kind of a misuse of Typeable, Exception wants dynamic typing and uses the reflection mechanism to accomplish it
12:34:53 <kmc> Dynamic is also implemented with Typeable, is that an abuse?
12:35:26 <elliott> kmc: well, yes :)
12:35:31 <elliott> i mean it's not terrible or anything
12:35:40 <elliott> but Typeable gives you a lot more than you need for that
12:35:44 <Sgeo> Why is the more useful function's name longer?
12:35:48 <elliott> and it definitely feels like conflating two things
12:35:54 <elliott> Sgeo: ?
12:36:03 <Sgeo> fromDynamic vs fromDyn
12:36:10 <elliott> historical reasons?
12:36:10 <kmc> yeah that's terrible
12:36:15 <Sgeo> fromDyn could easily be expressed in terms of fromDynamic
12:37:06 <kmc> elliott, I see your point
12:37:15 <Sgeo> fromDyn dyn default = fromMaybe default (fromDynamic dyn)
12:37:37 <Sgeo> from is now semantically saturated for me
12:37:38 <kmc> yes yes
12:37:40 <Sgeo> from from from
12:38:43 <kmc> fromDynamic (Dynamic t v) = case unsafeCoerce v of r | t == typeOf r -> Just r | otherwise -> Nothing
12:38:57 <kmc> that's a fun tangle
12:42:06 <elliott> kmc: haha is that seriously the implementation?
12:42:09 <kmc> yes
12:42:18 <fizzie> Funtangled particles.
12:42:20 <elliott> that scares me, I wouldn't be able to bring myself to type unsafeCoerce until I'm safely in the right branch
12:42:43 <kmc> yeah it's pretty sketchy
12:43:01 <elliott> kmc: i wonder if Dynamic is actually more efficient than an existential these days
12:43:10 <elliott> i guess (a -> TypeRep) is a bit heavier than TypeRep
12:43:29 <kmc> you mean, an existential with a Typeable constraint?
12:43:43 <kmc> *nod*
12:43:43 <elliott> yeah
12:43:51 <kmc> someone should write abenchmark
12:43:54 <elliott> at least i was told it's a deliberate optimisation of that
12:44:03 <kmc> interesting
12:44:12 <elliott> benchmarks? meh, that's work, and I might be proven wrong
12:44:23 <elliott> it's easier to sit here and make people think i'm smart for having seen the better way
12:44:30 <kmc> bravo
12:44:57 <kmc> better use some hash tables too, I hear they're O(1)
12:45:21 <elliott> O(1) EVERYTHING
12:45:33 <elliott> find :: (a -> Bool) -> HashTable k a -> Maybe a -- O(1)
12:45:53 * Sgeo pokes the argument order of that
12:46:28 <Sgeo> Didn't I once yell at Factor for its sensitivity to argument order? And for the endless required imports?
12:46:32 <Sgeo> Yet Haskell does both
12:46:35 <kmc> haha
12:46:54 <kmc> but Haskell is the best language
12:47:07 <elliott> "sensitivity to argument order"?
12:47:08 <kmc> so sensitivity to argument order and endless required imports must somehow be virtues
12:47:34 <elliott> anyway that argument order is obviously correct
12:47:39 <Sgeo> elliott, a decision about order of arguments can make a function easier or harder to use
12:47:41 <kmc> i'm gonna say that sensitivity to argument order makes you pay attention to something important that the Java Monkeys ignore
12:47:44 <kmc> doesn't really matter what
12:48:07 <kmc> and required imports are great for all those static analysis and refactoring tools Haskell has
12:48:25 <kmc> (by "has" I mean "someone would have to write from scratch", but that's a matter of trivial engineering)
12:50:21 <elliott> Sgeo: Yeah, API design matters. That's a big language flaw.
12:51:05 <elliott> It's maybe annoying in a language where curried functions (<-- I will kill anyone who objects to this terminology) aren't the standard, but when they are it's obviously a benefit, since partial application is so common.
12:51:08 <Sgeo> The thing is argument order is a more significant part of the API in Haskell and Factor than it is in Python
12:51:48 <elliott> Relatedly, I consider it a /good/ thing if functions with 5+ arguments are a pain to use; it's a sign you should be factoring out those arguments into data types, or taking a more combinator-based approach, etc. (Although the record hack is acceptable for interfacing with foreign libraries at a low level.)
12:52:09 <elliott> kmc: You're really grumpy.
12:52:36 <Sgeo> elliott, I love how the Haskell standard libraries got API design wrong so often
12:52:39 <kmc> it's a good thing that <language flaw> because <flimsy rationalization>
12:52:44 <Sgeo> :t Map.lookup
12:52:45 <lambdabot> Couldn't find qualified module.
12:52:48 <Sgeo> :t Data.Map.lookup
12:52:50 <lambdabot> forall k a. (Ord k) => k -> M.Map k a -> Maybe a
12:52:55 <elliott> Sgeo: They did?
12:53:05 <Sgeo> :t head
12:53:05 <elliott> That's the correct way around.
12:53:06 <lambdabot> forall a. [a] -> a
12:53:14 <kmc> elliott, I may be grumpy but I'm right, and that's all that counts on The Internet
12:53:27 <elliott> kmc: I don't consider it a rationalisation of a language flaw; I have no real vested interest in making people think Haskell is good.
12:53:48 <kmc> elliott, which "record hack"? the one where your function takes a big record, and you provide a default value for that record, and callers can use record-update syntax?
12:53:57 <elliott> Sgeo: head is evil; what's that got to do with Map.lookup?
12:54:06 <Phantom_Hoover> Wait, why's head evil.
12:54:08 <Phantom_Hoover> Oh, wait.
12:54:11 <kmc> > head []
12:54:12 <lambdabot> *Exception: Prelude.head: empty list
12:54:14 <Sgeo> head is evil is a separate example of bad API design
12:54:20 <Sgeo> :t lookup
12:54:20 <lambdabot> forall a b. (Eq a) => a -> [(a, b)] -> Maybe b
12:54:22 <kmc> so much bad API design in Prelude
12:54:33 <elliott> kmc: Yes. It's a blatant hack, and it's awful, but if you want to interface with something that uses keyword arguments or whatever at a low level...
12:54:59 <kmc> elliott, can you explain what makes it a "blatant hack" and "awful"?
12:55:01 <elliott> kmc: I'd usually just bind N-parameter-for-huge-N functions directly, since they're almost always from languages without keyword arguments, anyway (since almost all languages don't have keyword arguments).
12:55:10 <Sgeo> Isn't it preferred to make a function that takes the object immediately, so you could try different keys with the partially applied function, etc?
12:55:18 <kmc> i like that trick and I don't see what it has to do with "interfacing with foreign libraries at a low level"
12:55:32 <elliott> kmc: You're misinterpreting me.
12:55:40 <kmc> it's common to have a procedure with a bunch of customizable behavior, for which most callers only want to change a few parts
12:55:45 <elliott> I'm not saying that the trick exists to do such interfacing.
12:56:02 <kmc> you're saying it's gross and has cooties and should only be used when touching the unclean terrible world of anything not Haskell
12:56:14 * elliott yawn
12:56:15 <kmc> but why
12:56:21 <kmc> why is it a hack and awful
12:56:24 <elliott> I'm not going to bother if you're just going to twist everything I say into "HASKELL R AWSUM".
12:56:43 <kmc> ok
12:57:01 <kmc> well i'm going to continue to use this "blatant hack" in APIs i design
12:57:17 <kmc> until I see a problem with it or someone points one out to me
12:57:21 <kmc> if you're fine with that, so am i
12:57:34 <elliott> I also don't see why you're blowing a parenthical remark in a completely different context out of proportion...
12:58:40 <elliott> I do consider most uses of the record thing a hack, and I do think it's fairly awful, but I was talking about it in a completely different context to the use-case you suggested.
12:59:01 <kmc> <kmc> why is it a hack and awful
12:59:14 <kmc> and which context?
12:59:33 <kmc> you just keep saying it's bad without explaining why
13:00:15 <elliott> kmc: The context I was talking about is the awkwardness of using functions with a large number of parameters (which a lot of people think explicitly named arguments like in Smalltalk (not overriding-defaults style like in Python or whatever) alleviates).
13:00:37 <kmc> ok
13:01:38 <kmc> i agree that functions with a large number of required parameters are bad
13:01:46 <elliott> For representing something like a Smalltalk-named-argument call, a record with a default is supremely ugly because you have to use "undefined" or whatever as a default, and failing to specify an argument is just silently accepted.
13:02:16 <Sgeo> What about using Nothings as a default?
13:02:21 <elliott> I do think that a lot of the procedure-with-a-bunch-of-customisable-behaviour situations can be done more nicely combinator-style or similarly, but records-with-defaults are fine for such configuration.
13:02:25 <Sgeo> Although admittedly it's ugly to call, but still
13:02:36 <elliott> Sgeo: That doesn't solve anything, since the underlying function will have to fromJust them.
13:02:58 <Sgeo> Oh, when all the things should be required?
13:03:03 <Sgeo> Don't provide a default then
13:03:18 <Sgeo> Oh, right, SomeRecord {} fills things in with undefined?
13:03:20 <Sgeo> :/
13:03:27 <kmc> yeah, at least GHC will warn though
13:03:38 <elliott> kmc: Anyway, my main point was that a lot of people point to e.g. an OpenGL or Win32 call with a billion parameters and say "look how much cleaner this would be if we you named arguments; therefore it's a language flaw not to have them", but in reality those functions have more like 3 parameters, it's just that those parameters are data-types left implicit because of limited abstraction facilities.
13:03:50 <kmc> yeah
13:03:56 <elliott> Or sometimes it's even that one function is doing the work of five because of limited composability, etc.
13:04:15 <elliott> Not having named arguments simplifies the language and discourages such things. Of course you have to make up for it with sufficient abstractional facilities.
13:04:28 <kmc> glLoadMatrix16(float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float)
13:04:49 <kmc> i think the record trick is fine (not perfect) when you want to selectively override defaults
13:04:50 <elliott> Is that a real example? :D
13:04:54 <kmc> i don't think so
13:04:56 <elliott> :(
13:05:24 <kmc> for a while i worked on a C++ codebase where one of the most important classes had a constructor like this:
13:05:41 <kmc> Thing::Thing(Foo, const Bar*, bool, bool, bool, bool, bool, bool, bool, bool, bool, bool, bool, bool, bool)
13:05:52 <kmc> all of those bools had default values; some were true and some were false
13:06:18 <kmc> also you had to be careful because the order would change between development and production branches, as new features were merged
13:06:22 <elliott> Was the class called Thing too?
13:06:25 <kmc> no
13:06:26 <elliott> :(
13:06:27 <kallisti> I can't think of a situation where named parameters beats a properly designed abstraction.
13:06:36 <elliott> kallisti: naming parameters
13:07:04 <kallisti> well, it's better at that I suppose.
13:07:04 <kmc> kallisti, overriding default settings
13:07:14 <kallisti> meanwhile data structures are better at naming record fields.
13:07:15 <kmc> for example how would you replace this with a "properly designed abstraction"? http://hackage.haskell.org/packages/archive/concorde/0.1/doc/html/Algorithms-Concorde-LinKern.html#t:Config
13:07:27 <elliott> [[
13:07:27 <elliott> (I wonder: is this for beginn...@haskell.org ?)
13:07:27 <elliott> toA_IO = openFile (dir "toA") WriteMode :: IO Handle
13:07:27 <elliott> fromA_IO = openFile (dir "fromA") ReadMode
13:07:27 <elliott> -- used as global values
13:07:27 <elliott> toA = unsafePerformIO toA_IO --
13:07:29 <elliott> fromA = unsafePerformIO fromA_IO --
13:07:31 <elliott> ]]
13:07:33 <elliott> thank god for beginners
13:07:40 <elliott> s/\?\)/?)\n[...]\n/
13:07:56 <kmc> kallisti, maybe what you meant by "properly designed abstraction" is in fact a record like this
13:08:02 <kallisti> kmc: yes
13:08:02 <kmc> but i don't think it's much of an abstraction
13:08:16 <kallisti> kmc: defConfig is your default parameter set
13:08:18 <kmc> it's just a hodgepodge of all the ways you can change the behavior of 'tsp'
13:08:19 <elliott> kmc: TBH I'd probably represent that like...
13:08:36 <elliott> Well, similarly, I guess. But with a Monoid interface.
13:08:42 <elliott> That doesn't really buy you all that much in this situation, though.
13:08:47 <kmc> in a language with default keyword args I probably wouldn't define a separate type
13:08:53 <elliott> Hmm, do I actually want a Monoid interface there.
13:08:53 <kmc> for simplicity's sake
13:09:07 <kmc> the Monoid instance is sometimes useful; I think it's dubious here
13:09:08 <elliott> kmc: Anyway, I think that's actually preferable to named parameters.
13:09:11 <elliott> Because you can pass around Configs.
13:09:20 <fizzie> elliott: gluProject(GLdouble, GLdouble, GLdouble, const GLdouble *, const GLdouble *, const GLint *, GLdouble*, GLdouble*, GLdouble*). (Okay, so last three are just output parameters; they pretty consistently take 4x4 matrices as pointers, and only go up to 4-vectors as separate parameters.)
13:09:32 <elliott> fizzie: SO ELEGANT.
13:09:32 <kallisti> to the function user it's not a huge difference. To the implementor it's a bit more work to define a data type and a default constructor.
13:09:41 <kmc> elliott, sure, you can, but you usually don't need to
13:09:47 <elliott> kallisti: "default constructor"? you have to specify the defaults anyway :P
13:09:56 <kallisti> true.
13:10:01 <kmc> an airplane is better than a car because it can also fly
13:10:03 <kallisti> it's just abit more typing is all.
13:10:12 <Phantom_Hoover> fizzie, why 4-vectors?
13:10:13 <elliott> kmc: If you used more-notation, I think you could specify the defaults inline with the fields.
13:10:14 <kmc> however the airplane is harder to build and more expensive ;P
13:10:15 <kallisti> same amount of information though, I suppose. (except you also need types in a statically typed language of course)
13:10:24 <kmc> M O R E N O T A T I O N
13:10:27 <Phantom_Hoover> Has OpenGL cornered the 4D gaming market while I wasn't looking?
13:10:35 <kmc> haha
13:10:38 <fizzie> elliott: GLint gluUnProject4(GLdouble, GLdouble, GLdouble, GLdouble, const GLdouble *, const GLdouble *, const GLint, GLdouble, GLdouble, GLdouble*, GLdouble*, GLdouble*, GLdouble*); /* real function */
13:10:40 <elliott> kmc: http://www.haskell.org/haskellwiki/User:Zzo38/Proposal_for_more-notation#Fields_in_record_syntax
13:10:40 <Phantom_Hoover> /kick kmc
13:10:42 <fizzie> Phantom_Hoover: Homogenous coordinates.
13:10:47 <elliott> fizzie: :D
13:10:53 <kmc> Phantom_Hoover, perspective transformation is linear with homogeneous coordinates
13:11:10 <kmc> meaning that (x, y, z, w) represents the 3D point (x/w, y/w, z/w)
13:11:23 <kallisti> and then for the cases in Python where a function basically treats its parameter set as a hash table you'd use some equivalent mapping structure.
13:11:25 <fizzie> elliott: Sorry, I droppeded one star.
13:12:05 <kmc> you start with some vectors where w=1 and then get something else
13:12:12 <kmc> and renormalize them before you draw them
13:12:44 <kallisti> also I can't, for the life of me, figure out how named parameters are supposed t work in conjunction with currying.
13:12:45 <kmc> believe this corresponds to 3D projective space, where the extra "point at infinity" is (anything, anything, anything, 0)
13:14:50 <kallisti> some other minor issues that could be amended are that named parameters require you to know the names of parameters. In Haskell these are lovely things such as "m f g h x y z". Also, currently documentation doesn't list parameter names and doing so look pretty ugly in most cases.
13:14:52 <fizzie> kmc: It's a "sphere at infinity" with antipodal points made the same; there's a difference between (1, 0, 0, 0) and (0, 1, 0, 0) even though they're both "at infinity".
13:15:08 <kmc> hmm
13:15:10 <fizzie> But (1, 0, 0, 0) and (-1, 0, 0, 0) are the same thing.
13:15:15 <kallisti> these are problems with introducing a language feature into an existing codebase rather than problems with the feature itself.
13:15:26 <kmc> interesting
13:15:43 <elliott> wait why the fuck am i amending my answer to help this guy, their accept rate is 33%
13:15:57 <kallisti> elliott: DO IT
13:15:59 <elliott> kmc: I bet you didn't even LOOK at that more-notation link.
13:16:11 <kmc> elliott, I've seen the more notation...
13:16:34 <elliott> kmc: Yeah, but did you know it can simplify default parameter records?!
13:16:44 <elliott> It's almost as if it's ten different notations in one!
13:16:50 * kallisti begins writing a proposal for "not enough" notation
13:16:52 <kmc> it's too early to understand this
13:16:59 <kmc> i was there in #haskell when zzo38 first arrived
13:17:16 <elliott> You can thank me for that.
13:17:20 <kmc> haha
13:17:34 <kmc> now i have a better understanding of all the ways Haskell is unlike INFORM 7 and Magic: the Gathering
13:17:44 <elliott> Too many ways, is the answer!
13:18:59 <fizzie> It's like the projective plane is the R^2 plus one "point at infinity" for each class of parallel lines, so that the added points form a single "line at infinity". The Riemann sphere is the version where there's a plane and a single point.
13:19:52 <kmc> aha, that makes some sense
13:20:09 <kallisti> data REcord = { x :: Foo = YEAAAAh }
13:20:50 <kallisti> actually
13:20:51 <elliott> hmm... GArrowSum is confusing, I don't think it lets you actually have a conditional
13:20:54 <elliott> oh wait yes it does duh
13:20:54 <kallisti> you could have it this
13:21:03 <kallisti> data REcord = { x = YEAAAAh :: Foo }
13:21:05 <Sgeo> Would be nice if you could say that the things in the record have no defaults
13:21:10 <kallisti> and the :: could be omitted because of type inference.
13:21:13 <Sgeo> So Record {} is a compile-time error
13:21:24 <kallisti> Sgeo: that would be the default, sir.
13:21:34 <kallisti> the default is to have no defaults. :P
13:21:44 <elliott> kallisti: you did not click the more notation link
13:21:51 <kallisti> I did not
13:21:54 <kallisti> does it involve the "more" keyword?
13:22:16 <kallisti> the main reason I didn't click is that gnome-terminal's link regex breaks on colons
13:22:34 <kallisti> so to click it I would have to actually DRAG AND DROP MY MOUSE CURSOR OVER IT AND COPY AND PASTE IT MANUALLY
13:22:37 <kallisti> yikes
13:23:20 * kmc sleep
13:24:19 <fizzie> Phantom_Hoover: Also the homogenous coordinates are nice because when all your vectors are normalized [x y z 1]^T vectors you can do translation (and any affine operations) by multiplying with a 4x4 matrix [x x x x; x x x x; x x x x; 0 0 0 1] to get another [x' y' z' 1]^T, so you can just concatenate sequences of translations and rotations and whatever by multiplying them all up.
13:28:58 <kallisti> I think once I have a working implementation of portal chess I'll start working on a generic interface to define chess games with arbitrary pieces, movement rules, starting positions, etc.. and have that available as a different module.
13:29:57 -!- sebbu2 has joined.
13:29:58 -!- sebbu2 has quit (Changing host).
13:29:58 -!- sebbu2 has joined.
13:30:24 <kallisti> I'm not sure but I /think/ type families would be useful for this.
13:30:27 -!- itidus20 has joined.
13:30:42 <fizzie> elliott: Can't seem to find anything that'd take >13 parameters, though gluLookAt takes 9 doubles in a row (three 3-vectors), which is at least nice and uniform.
13:33:04 -!- itidus21 has quit (Ping timeout: 240 seconds).
13:33:24 -!- sebbu has quit (Ping timeout: 240 seconds).
13:34:46 <fizzie> Bah. The "sum is denoted by ●" was one thing, but this thing-as-seen-by-evince also has limits as "N → °", and it's not talking about zero there.
13:34:57 -!- sebbu3 has joined.
13:34:58 -!- sebbu3 has quit (Changing host).
13:34:58 -!- sebbu3 has joined.
13:35:01 <fizzie> Creator: dvipsk 5.58f Copyright 1986, 1994 Radical Eye Software
13:35:01 <fizzie> Producer: Acrobat Distiller Command 3.01 for Solaris 2.3 and later (SPARC)
13:35:07 <fizzie> Going to blame Adobe here.
13:37:35 <kallisti> fizzie: how do you render that white dot on white paper?
13:38:00 -!- sebbu2 has quit (Ping timeout: 240 seconds).
13:38:32 <kallisti> fizzie: in fact all of that text is white
13:38:35 <kallisti> isn't it jujst going to be invisible?
13:38:39 <kallisti> :)
13:39:43 <fizzie> Bah. The "sum is denoted by " was one thing, but this thing-as-seen-by-evince also has limits as "N → °", and it's not talking about zero there.
13:40:07 <kallisti> oooooooh
13:40:08 <kallisti> now I see.
13:40:11 <kallisti> pleasing to the eyes.
13:41:50 <kallisti> I think type-directed name resolution isn't too terrible of an idea
13:41:52 <kallisti> the only problem
13:41:56 <kallisti> is it needs a better name.
13:42:14 <kallisti> also it's playing "how many ways can we overload . ? " game
13:42:18 <kallisti> +the
13:42:28 <fizzie> (Maybe I should've s/(●|N → °)/$1/g instead.)
13:45:12 <elliott> :D
13:45:41 <kallisti> if ' weren't already an identifier character, record'field would be a good alternative to using .
13:45:42 <elliott>
13:45:42 <elliott>
13:45:42 <elliott> Ok I don't know how to use it for my problem : I want somthing like this: loadfunction = do { x <- string2int getLine if( failed parsing int ) call somefunction y <- string2int getLine if( failed parsing int ) call somefunction } – user606521 10 mins ago
13:45:42 <elliott>
13:45:44 <elliott>
13:45:46 <elliott> Ok I don't know how to use it for my problem : I want somthing like this: loadfunction = do { x <- string2int getLine if( failed parsing int ) call somefunction y <- string2int getLine if( failed parsing int ) call somefunction otherfunction x y } I dont know how to do it using your anserws... – user606521 2 mins ago
13:45:50 <elliott> *sigh*
13:45:53 <elliott> shachaf: Should I bother?
13:46:21 <kallisti> elliott: sounds easy enough. just talk about read and catch.
13:46:45 <kallisti> :):):):):)
13:46:48 <elliott> kallisti: http://stackoverflow.com/questions/8850299/catching-errors-during-string-parsing
13:47:03 -!- itidus20 has quit (Read error: Connection timed out).
13:47:11 <kallisti> oh... okay
13:47:23 <kallisti> what do you think about record'field for TDNR?
13:47:41 * elliott decides not to bother.
13:47:43 <elliott> kallisti: ugly
13:48:03 <kallisti> unfortunately all the non-ugly symbols are taken.
13:48:58 <kallisti> (except for, you know, all of those unicode characters)
13:50:58 <kallisti> oh I know
13:51:04 <kallisti> a non-breaking space could indicate TDNR
13:51:06 <kallisti> :)
13:54:55 <kallisti> I think
13:55:01 <kallisti> ' is the best choice aside from .
13:55:19 <kallisti> because it doesn't really break anything (how many people put a ' in the middle of a variable name?) and doesn't look very bad.
13:57:17 <elliott> it breaks don't
13:57:33 <kallisti> oh shit...
13:57:48 <Phantom_Hoover> http://lal0nde.deviantart.com/art/problem-sleuth-279003657
13:57:50 <Phantom_Hoover> this
13:57:54 <Phantom_Hoover> this must be moddable
13:58:57 <kallisti> elliott: you're banned from ever naming another variable "eVal"
13:59:28 <kallisti> oh
13:59:30 <kallisti> that was the guy
13:59:31 <kallisti> oops
13:59:51 <kallisti> he's banned forever.
14:02:41 <kallisti> @C.A.McCann: How can you sleep when there's rep to be gained?! :) – ehird Jan 8 at 18:51
14:02:41 <lambdabot> Unknown command, try @list
14:02:47 <kallisti> bahahahahahahahahahahahahahahahahahahahahahahahahahahahaha
14:02:50 <kallisti> ^ha
14:02:50 <fungot> ha. ha. ha ha. ha ha ha. ha ha ha ha ha. ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha. ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ha ...too much output!
14:08:10 <kallisti> http://stackoverflow.com/questions/8793736/haskell-to-javascript-compilers/8793958#8793958
14:08:18 <kallisti> elliott: btw there's also Selenium bindings for Haskell.
14:08:29 -!- Gregor` has set topic: Update grating, and Cheesy A! I'm Number A, not IM. | http://codu.org/logs/_esoteric/.
14:08:33 <Gregor`> Wha
14:08:35 -!- Gregor` has changed nick to Gregor.
14:08:50 -!- Gregor has set topic: Update grating, and Cheesy A! I'm Number A, not IM. | http://codu.org/logs/_esoteric/.
14:11:26 <elliott> kallisti: i don't think selenium is relevant.
14:12:25 <kallisti> it's as relevant as Ji..
14:13:00 <elliott> Nope.
14:13:12 <elliott> It might be if you make incorrect assumptions about what Ji does, though.
14:13:54 <kallisti> "it lets a Haskell server control a browser connected to it via AJAX."
14:14:27 <elliott> I call you an idiot in T-10, T-9...
14:15:07 <elliott> This happens because you deliberately ignore people rather than, say, doing something as simple as clicking a link to clarify your impression after someone points out that you're wrong.
14:17:26 <kallisti> oh right, that's why I was ignoring you.
14:18:25 <elliott> Yes, because I call you an idiot after I point out you're wrong and you continue to insist you're not rather than doing the most cursory research.
14:18:38 <Phantom_Hoover> elliott, selenium is always relevant.
14:18:59 <kallisti> elliott: I discovered how I was wrong. happy?
14:19:10 <elliott> When people who aren't me say "no, that's not related", they usually mean "You clearly know more than me about what both of these things do. Please, quote something I said back at me."
14:19:29 <elliott> kallisti: Sorry, I hate life and everyone and existence.
14:20:33 <kallisti> I don't really see how any of what I did implied that I think I "know more about something"
14:20:47 <kallisti> instead, I was just quoting you... to show you where I got that impression.
14:20:48 <kallisti> ????
14:20:50 <kallisti> whatever
14:23:06 <Sgeo> Blargh
14:23:16 <Sgeo> Just got a terrible thought for API design
14:40:11 <kallisti> "it is always better to work continuously over the course of the term, rather than in discrete bursts around the time of examinations."
14:49:38 <ais523> hmm, back
14:49:45 <ais523> that was a fun seminar
14:49:52 <ais523> we spent a whole hour talking about call-by-name
14:50:01 <ais523> then another 40 minutes after the seminar talking about product types
14:50:19 <coppro> ais523: see #nomic
14:54:24 -!- ais523 has quit (Ping timeout: 240 seconds).
14:57:08 <kallisti> @tell ais523 can you actually talk about product types alone for 40 minutes?
14:57:08 <lambdabot> Consider it noted.
15:18:03 <Phantom_Hoover> http://en.wikipedia.org/wiki/File:Carlos_segundo80.png
15:18:08 <Phantom_Hoover> Ngevd's family tree.
15:21:27 <kallisti> http://en.wikipedia.org/wiki/File:Undirected_6_cycle.svg Phantom_Hoover's family tree
15:21:39 <oklopol> kallisti: especially as all discrete bursts have measure zero.
15:22:14 <Phantom_Hoover> This is also known as the Hexagon of Hoover.
15:24:34 <elliott> <Phantom_Hoover> http://en.wikipedia.org/wiki/File:Carlos_segundo80.png
15:24:41 <elliott> Phantom_Hoover: Every time I see this I just grin and gawp at it.
15:24:51 <elliott> It's like they're optimising for inbreeding.
15:25:37 <Phantom_Hoover> It's the way that the guy has exactly five ancestors who weren't inbred there.
15:26:10 <elliott> Phantom_Hoover: (The comments on the SO question whose reddit thread I presume you found that in are really annoying.)
15:26:17 <Phantom_Hoover> Yes, they are.
15:26:34 <elliott> "This might be one of those cases where you need to ask yourself: Do I really want to make business with that guy?" INCEST IN FAMILY TREES HAS LITERALLY NEVER HAPPENED, JUST IGNORE IT
15:26:58 <Phantom_Hoover> Well, in this case, the complainer /was/ a man who said he'd had two children with his daughter.
15:27:11 <elliott> A man with money to spend on family tree software!!!
15:27:15 <elliott> CAPITALISM: the movie
15:27:43 <Phantom_Hoover> "What the guy should have asked is how to handle nodes that can be reached via two or more distinct paths. Every family tree has cases like this (no exceptions)."
15:27:52 <elliott> <kallisti> http://en.wikipedia.org/wiki/File:Undirected_6_cycle.svg Phantom_Hoover's family tree
15:27:54 <Phantom_Hoover> Um excuse me what do you say to Cain and Abel??
15:28:05 <elliott> All the vertices are Phantom_Hoover.
15:28:18 <Phantom_Hoover> Yes.
15:28:31 <Phantom_Hoover> http://en.wikipedia.org/wiki/File:Complete_graph_K7.svg
15:28:35 <Phantom_Hoover> elliott's family tree.
15:28:53 <elliott> Yes.
15:30:50 -!- ais523 has joined.
15:31:44 <kallisti> ais523: hi
15:31:48 <ais523> hi
15:31:48 <lambdabot> ais523: You have 1 new message. '/msg lambdabot @messages' to read it.
15:31:50 <ais523> stupid connection
15:32:08 <ais523> sure you can talk about product types for 40 minutes
15:32:32 <ais523> note that it was in the context of impure languages
15:32:58 <ais523> in particular, we were debating the expression that in ICA would be written as "print(1);(2,3)"
15:33:24 <ais523> (you could write something similar in various other impure CBN languages, but there aren't a whole lot of those in existence)
15:33:45 <ais523> both in call-by-name, and in call-by-value
15:38:52 <kallisti> what is ICA
15:39:36 <kallisti> Immaculate Conception Academy-Greenhills, an elite private all-girls Chinese school in Greenhills, San Juan, Metro Manila, Philippines. (Not to be confused with ICA Manila (ICAM) or ICA Dasmariñas)
15:40:18 <kallisti> International Council on Archives <--- aka elliott
15:41:55 <Phantom_Hoover> http://en.wikipedia.org/wiki/File:EgyptianPtolemies2.jpg
15:42:02 <Phantom_Hoover> Ngevd's other family tree.
15:42:37 <Phantom_Hoover> Jesus Christ, the most recent new stock in that family tree is Antiochus III.
15:42:43 <kallisti> impressive pedigree
15:42:48 <ais523> kallisti: idealized concurrent algol
15:42:55 <Phantom_Hoover> Well, right up until Caesar and Antony.
15:43:02 <kallisti> also note how Antiochus III of Syria manages to birth Cleopatra I by himself
15:43:05 <kallisti> impressive.
15:43:36 <Phantom_Hoover> Cleopatra VII's family were completely inbred for 5 generations.
15:44:06 <kallisti> I don't even know how to interpret these family relations....
15:44:27 <kallisti> also what happened to Ptolomy, the son, the sequel.
15:45:10 <kallisti> for example what is the relationship between Ptolomey XIII and Cleopatra VII... they appear to be brother and sister twice.
15:45:36 <Phantom_Hoover> They married, you dolt.
15:45:45 <elliott> Phantom_Hoover: What is marriage but being brother and sister twice?
15:45:58 <Phantom_Hoover> They just didn't have any children, which is not exactly surprising given the circumstances.
15:46:12 <kallisti> I'm sorry it looked strange.
15:46:23 <kallisti> Cleopatra wasn't lined up with all the others
15:46:32 <kallisti> and the elbow line didn't register as "marriage" at that point
15:46:52 <Phantom_Hoover> Charles II clearly got the short end of the homozygous stick, seeing as Cleopatra isn't generally remembered as a twisted freak.
15:48:33 <elliott> Phantom_Hoover: I was going to say "I wonder what the maximally inbred family would be like" and then I realised it's called LIFE.
15:48:35 <kallisti> http://bisserjeta.hsara.com/2012/01/100-year-old-prostitute-still-going-strong/?article
15:48:36 <elliott> DEEP.
15:49:07 <kallisti> I wonder what her family tree looks like.
15:49:18 <elliott> kallisti: "surrounded by prominent politicians, businessmen, lawyers and members of the clergy, all of whom were in costume to protect their identities. “I so enjoyed lapping up their warm greetings,” she beams." Somehow I doubt this is: legit.
15:50:19 <kallisti> really?
15:50:22 <kallisti> I don't see how
15:51:25 <kallisti> this looks like a completely legit site to me.
15:54:40 <kallisti> I wonder who the audience is for this material.
15:55:14 <kallisti> this creepily written probably fake story about a 100-year-old prostitute.
15:55:33 <kallisti> what is its purpose.
16:03:04 <Sgeo> I still need to play Ally Cat
16:03:16 <Sgeo> It's still on my Todo list
16:03:19 <Sgeo> *Alley Cat
16:03:32 <fizzie> In Ally Cat, the cat is your ally.
16:04:21 <elliott> I am glad people take my decrees so seriously.
16:04:29 <elliott> Or at least I can't imagine anyone else having told Sgeo to play Alley Cat.
16:04:45 <Sgeo> elliott, you may have been telling someone else to play Alley Cat
16:04:51 <fizzie> Did the PC version of that thing have rather horrible PC speaker beeping.
16:04:55 <fizzie> I think it did.
16:04:57 <Sgeo> The 10/2/2011 logs
16:05:17 <Sgeo> (As in October 2nd, not as in February 10th)
16:05:30 <fizzie> As in 2011-10-02.
16:05:50 <Sgeo> 04:54:08: <elliott> Sgeo|web: Play alley cat.
16:05:50 <Sgeo> 04:54:14: <elliott> FOREVERRR
16:05:50 <Sgeo> 04:54:17: <Sgeo|web> elliott: on Thursday, I will
16:07:12 <Phantom_Hoover> What is this alley cat
16:07:56 <Sgeo> Some old game
16:08:05 <elliott> :t runWriter
16:08:06 <lambdabot> forall w a. Writer w a -> (a, w)
16:08:14 <elliott> :t execWriter
16:08:15 <lambdabot> forall w a. Writer w a -> w
16:08:52 <elliott> fizzie: Yes, it did.
16:09:01 <elliott> Phantom_Hoover: The BEST GAME.
16:10:38 <fizzie> The CGAest game.
16:10:52 <elliott> :t msum
16:10:53 <lambdabot> forall (m :: * -> *) a. (MonadPlus m) => [m a] -> m a
16:13:39 <Sgeo> How many lives do I have?
16:13:56 <Sgeo> I suck at games
16:14:46 <Sgeo> I think I'm dead. I wasn't counting, but 9 would make sense
16:15:10 <Sgeo> Oh
16:15:14 <Sgeo> It says next to cat
16:15:30 <elliott> Wait 'til Sgeo discovers you can JUMP IN THE WINDOWS.
16:15:38 <Sgeo> The windows have minigames
16:15:40 <Sgeo> I think
16:15:58 <Sgeo> I've only been in 1 window
16:16:05 <fizzie> It's JUST like Mario Party. Almost.
16:16:55 <elliott> :D
16:16:57 <elliott> Without the party part.
16:16:58 <elliott> Solo party.
16:17:00 <Sgeo> There's a weird clicking coming from the speakers
16:17:05 <elliott> Yes.
16:17:28 <Sgeo> I mean, while it tries to play the music, I don't think it is the music
16:17:35 <elliott> No, there's no "music".
16:17:45 <elliott> That's patter sounds.
16:18:04 <Sgeo> "patter sounds"?
16:18:08 <elliott> Like, feet.
16:18:26 <Sgeo> Feet that play a melody with different pitches?
16:18:53 <elliott> Well.
16:19:07 <elliott> Oh.
16:19:11 <elliott> No, that's the music.
16:19:56 <Sgeo> Hmm, no music during gameplay, I guess, just at game over/intro screen
16:22:25 <elliott> Right.
16:27:49 -!- Ngevd has joined.
16:28:20 <elliott> :t evalWriter
16:28:21 <lambdabot> Not in scope: `evalWriter'
16:28:28 <elliott> @hoogle evalWriter
16:28:28 <lambdabot> No results found
16:29:36 <Ngevd> Hello!
16:31:29 <kallisti> elliott: am I actually gaining anything by defining this Storable instance and converting square data to Word16. Wouldn't it already kind of work that way internally?
16:31:48 <kallisti> oh, no, it would be Word32 or Word64 or whatever. :P
16:31:50 <kallisti> nevermind.
16:34:11 <kallisti> it seems to me that it's optimizing for space over time.
16:44:24 <kallisti> better spatial locality of the vector seems to be cancelled out by using a map...
16:46:01 <elliott> What?
16:48:49 <kallisti> :t succ . fromEnum $ maxBound
16:48:50 <lambdabot> Ambiguous type variable `a' in the constraints:
16:48:50 <lambdabot> `Enum a' arising from a use of `fromEnum' at <interactive>:1:7-14
16:48:50 <lambdabot> `Bounded a'
16:50:53 <ais523> here's a line from my IOCCC submission: echo '(find-file "./prog.c" t) (indent-region (point-min) (point-max)) (write-file "./emacs.c" t)' > reindent-prog.el
16:51:26 <kallisti> :t fromEnum
16:51:26 <ais523> my submission was specifically designed to confuse reindentors, so I decided to put a few reindentors in an optional part of the Makefile, so that it could easily be tested
16:51:26 <lambdabot> forall a. (Enum a) => a -> Int
16:51:30 <kallisti> ah
16:51:34 <ais523> and then left it in to show the judges that I wasn't afraid of them
16:52:56 <elliott> ais523: hmm, this must be some other submission to the one i saw
16:53:38 <ais523> which one did you see?
16:53:48 <ais523> (that's part of the Makefile, not of the C code)
16:54:28 <elliott> ais523: the one with a bunch of setjmps
16:54:33 <elliott> or maybe it's the same one
16:54:34 <ais523> same one
16:54:47 <elliott> that one was pretty
16:54:48 <elliott> i think
16:54:50 <kallisti> > maxBound :: Just Bool
16:54:50 <lambdabot> Not in scope: type constructor or class `Just'
16:54:51 <elliott> i don't remember what it looked like
16:54:53 <ais523> I consider setjmp pretty much mandatory in obfuscated C
16:54:55 <kallisti> > maxBound :: Maybe Bool
16:54:55 <lambdabot> No instance for (GHC.Enum.Bounded (Data.Maybe.Maybe GHC.Bool.Bool))
16:54:55 <lambdabot> aris...
16:55:01 <ais523> elliott: each function consists of nothing but declarations
16:55:12 <ais523> which are very complicated expressions, overparenthesized
16:55:23 <ais523> and indented in columns, using Lisp-style indentation for each column
16:55:39 <kallisti> is there any reason why writing an instance for (Bounded a) => Maybe a is a bad idea?
16:55:40 <elliott> ais523: can i see it :( i lost my copy :(
16:55:53 <kallisti> er
16:55:54 <elliott> kallisti: is minBound (Just minBound) or Nothing
16:56:01 <ais523> well, we're past the deadline now, so I can paste it somewhere and PM people the link
16:56:01 <kallisti> Nothing, I would say.
16:56:08 <kallisti> though I realize that's arbitrary.
16:56:10 <elliott> well I guess that's consistent with Maybe's Ord instance
16:56:15 <kallisti> yes.
16:56:21 <kallisti> also Enum
16:56:23 <elliott> ais523: you realise that there's no rule against sharing them in the first place, right?
16:56:26 <kallisti> I think it has an enum...
16:56:26 <elliott> at least Gregor didn't find one
16:56:30 <ais523> elliott: right, indeed
16:56:34 <ais523> just it has to be your own work
16:56:35 <kallisti> > toEnum 0 :: Maybe True
16:56:35 <lambdabot> Not in scope: type constructor or class `True'
16:56:39 <kallisti> > toEnum 0 :: Maybe Bool
16:56:40 <kallisti> lol
16:56:40 <lambdabot> No instance for (GHC.Enum.Enum (Data.Maybe.Maybe GHC.Bool.Bool))
16:56:40 <lambdabot> arising...
16:56:42 <kallisti> oh neverminde
16:56:46 <ais523> I'm just a little overprotective of it
16:56:48 <Gregor> They even allow team submissions.
16:56:57 <Gregor> Publicly sharing is probably not wise though.
16:57:01 <ais523> Gregor: I think that's a change
16:57:32 <ais523> int r,u,y, getchar(), putchar(), b();
16:59:53 <Gregor> ais523: Now if only you could do int r, u, y, main() { ... };
16:59:54 <Gregor> :)
17:00:17 <ais523> is that legal? it'd be awesome if it were
17:00:23 <Gregor> 'snot.
17:00:39 <ais523> incidentally, the reason I did getchar and putchar like that rather than including stdio.h is so that I could give them the wrong number of arguments
17:01:06 <Gregor> Which is ... so useful ... for getchar and putchar ... ?
17:02:02 <ais523> the extra arguments don't do anything but make the code look nicer
17:02:04 <kallisti> :t fromEnum
17:02:05 <lambdabot> forall a. (Enum a) => a -> Int
17:02:08 <ais523> and it's a free obfuscation
17:02:22 <ais523> (a () out of context in the wrong column makes people realise the code isn't meant to be read in columns)
17:04:02 <ais523> Gregor: where's your submission, btw? I'm interested in seeing it now the deadline's passed
17:04:02 <kallisti> @hoogle asTypeOf
17:04:02 <lambdabot> Prelude asTypeOf :: a -> a -> a
17:04:18 <Gregor> ais523: I'll PM
17:06:39 <kallisti> what's an example of a type that is Bounded but not Enum.
17:07:11 <Sgeo> kallisti, real numbers between -1 and 1?
17:07:23 <kallisti> oh, yes I suppose that counts.
17:07:36 <kallisti> but then what would that look like in Haskell
17:09:31 <elliott> Float and Double are Enum but shouldn't be.
17:09:43 <elliott> But they're bounded.
17:09:46 <elliott> Since IEEE has -inf and +inf.
17:09:57 -!- sebbu3 has changed nick to sebbu.
17:10:05 <kallisti> ah yes
17:10:39 <elliott> kallisti: More generally, you can make any type bounded like
17:10:52 <elliott> data WithBounds a = MinBound | Middle a | MaxBound
17:10:57 <elliott> but can't necessarily give it an Enum instance.
17:11:12 <elliott> (You need `Ord a` for the Boudned instance to mean much, though.)
17:11:34 <kallisti> that's an interesting type.
17:11:52 <elliott> It's the "free Bounded". :p
17:12:19 * kallisti isn't sure why he didn't generalize his gross Enum code earlier...
17:12:51 <Sgeo> elliott, I was thinking, something like that makes more sense than your WithNegInfinity and WithPosInfinity, I think
17:13:14 <Sgeo> It's not nonsensical for a lower bound to be positive infinity
17:13:29 <elliott> Sgeo: My types were like that for a reason.
17:13:50 <elliott> Namely, WithBounds didn't make sense for the usecase in question.
17:16:00 <ais523> you know what? less needs syntax highlighting
17:16:09 <ais523> I know you could just use an editor, but good editors aren't necessarily good viewers
17:17:30 <elliott> http://stackoverflow.com/questions/8850299/catching-errors-during-string-parsing
17:17:32 <elliott> http://stackoverflow.com/questions/8853896/throwing-exceptions-in-haskell-and-xderivedatatypeable
17:17:32 <elliott> http://stackoverflow.com/questions/8854471/io-string-and-io-data-type
17:17:35 <elliott> this guy
17:17:37 <elliott> sigh
17:17:44 <elliott> ais523: highlight foo | less -R
17:17:57 <ais523> ooh, interesting
17:18:21 <Deewiant> Where highlight = e.g. code2color
17:18:29 <ais523> there's an actual command highlight, it seems
17:18:33 <ais523> I'm not sure what engine it's based on
17:18:40 <Deewiant> lesspipe also has some kind of support
17:18:41 <elliott> Deewiant: I think there's a program that does that actually called "highlight", which is why I said "highlight".
17:18:51 <ais523> elliott: right, and I found it in the repos
17:18:52 * ais523 installs it
17:18:53 <Deewiant> elliott: It sounded generic so I wasn't sure. :-P
17:18:59 <elliott> ais523: I think more also does syntax highlighting, but who the fuck uses more.
17:19:03 <elliott> Er.
17:19:03 <elliott> most.
17:19:05 <elliott> Not more.
17:19:07 <ais523> heh
17:19:22 <ais523> I hope highlight's a no-op on stuff it doesn't understand
17:19:26 <ais523> in that case, I could just add it into l
17:19:32 <elliott> into l
17:19:39 <ais523> l is my ls-or-less program
17:19:46 <ais523> that runs ls or less depending on whether you give it a directory or a file
17:20:00 <ais523> aww, highlight doesn't do INTERCAL
17:20:19 <elliott> ais523: you realise less has preprocessor support built in, right?
17:20:27 <ais523> yes
17:20:28 <elliott> LESSOPEN
17:20:30 <elliott> or w/e
17:20:42 <ais523> it's more annoying than anything else, as it tries to interpret .doc as Word files rather than text files
17:20:42 <elliott> ais523: be careful about -R, though; you won't want to do that on binary files
17:20:43 <ais523> and errors out
17:20:47 <elliott> also, err, what?
17:20:52 <elliott> we're not talking about the same thing
17:20:56 <ais523> elliott: less foo.doc
17:21:02 <ais523> gives an error message "no catdoc available"
17:21:19 <elliott> INPUT PREPROCESSOR
17:21:19 <elliott> You may define an "input preprocessor" for less. Before less opens a file, it first gives your input preprocessor a chance to modify the way the contents
17:21:19 <elliott> of the file are displayed. An input preprocessor is simply an executable program (or shell script), which writes the contents of the file to a different
17:21:19 <elliott> file, called the replacement file. The contents of the replacement file are then displayed in place of the contents of the original file. However, it will
17:21:21 <elliott> appear to the user as if the original file is opened; that is, less will display the original filename as the name of the current file.
17:21:24 <elliott> An input preprocessor receives one command line argument, the original filename, as entered by the user. It should create the replacement file, and when
17:21:27 <elliott> finished, print the name of the replacement file to its standard output. If the input preprocessor does not output a replacement filename, less uses the
17:21:30 <elliott> original file, as normal. The input preprocessor is not called when viewing standard input. To set up an input preprocessor, set the LESSOPEN environment
17:21:33 <elliott> variable to a command line which will invoke your input preprocessor. This command line should include one occurrence of the string "%s", which will be
17:21:36 <elliott> replaced by the filename when the input preprocessor command is invoked.
17:21:38 <elliott> etc.
17:21:44 <ais523> elliott: yes, I believe it's lessopen that's responsible
17:21:54 <elliott> I doubt it, since it just executes a script you pass it...
17:22:00 <elliott> s/pass it/specify/
17:22:05 <ais523> $ echo $LESSOPEN
17:22:07 <ais523> | /usr/bin/lesspipe %s
17:22:29 <elliott> ais523: OK, so since lesspipe does something wrong, you're saying LESSOPEN is to blame?
17:22:40 <ais523> and indeed, /bin/lesspipe (=/usr/bin/lesspipe) complains on 104
17:22:48 <ais523> elliott: I'm saying the default value of $LESSOPEN is to blame
17:22:53 <elliott> how is that relevant?
17:22:53 <ais523> because it's set to lesspipe
17:23:03 <elliott> I was telling you you didn't need a wrapper script to accomplish what you want
17:23:06 <elliott> sheesh
17:23:13 <Deewiant> LESSOPEN="|highlight -qOxterm256 --force %s" seems to work. elliott: Thanks for the pointer to highlight, it seems to be an improvement over code2color.
17:23:18 <ais523> elliott: well, I either need to wrap less, or lesspipe
17:23:36 <elliott> ais523: wtf?
17:23:40 <elliott> ais523: just do what Deewiant said
17:23:48 <elliott> nobody forces you to pue lesspipe in that variable
17:23:50 <elliott> *put
17:23:55 <elliott> Deewiant: np
17:23:59 <ais523> elliott: well, it processes gzip files
17:24:04 <ais523> which is a useful thing for it to do
17:24:25 <elliott> LESSOPEN="| /usr/bin/lesspipe %s | highlight -qOxterm256 --force"
17:24:26 <fizzie> Deewiant: highlight (via the libhighlight-perl bindings) is what p.zem.fi uses.
17:24:32 <Vorpal> hi
17:24:50 <elliott> ais523: you're complaining "I don't want to use LESSOPEN to accomplish this because of <problem I have /anyway/ that is tangentially related to what LESSOPEN is currently set to>"
17:25:16 <Deewiant> fizzie: I don't recall seeing anything syntax highlighted on p.zem.fi. Which may just be due to the fact that I hardly ever see links to p.zem.fi, for obvious reasons. :-P
17:25:32 <elliott> Deewiant: Is the obvious reason that Finns are blind to each other's words?
17:25:57 <fizzie> Deewiant: It's syntax-highlighted if you add a ".foo" to it, I've sometimes pasted a link to the highlighted version.
17:25:59 <Deewiant> The reason is that fizzie is the only one I know of who has write access to it.
17:26:45 <fizzie> Deewiant: http://p.zem.fi/w3mimgdisplay.c
17:27:28 <elliott> fizzie: You should use a content-disposition header on that .bin to set the filename correctly.
17:27:37 <Deewiant> I note that http://p.zem.fi/w3mimgdisplay.x is ASCII but served as application/xhtml+xml
17:28:08 -!- itidus21 has joined.
17:28:21 <elliott> http://p.zem.fi/w3mimgdisplay.sybase
17:28:26 <fizzie> Deewiant: Yes, I sort of forgot to handle errors there.
17:29:03 <Deewiant> This committee is not addressing lazy programmers.
17:29:09 <elliott> :D
17:29:23 <elliott> fizzie: "
17:29:23 <elliott> XXX = unsupported language: x"
17:29:26 <elliott> Looks like error handling to me!
17:29:33 <fizzie> Well, for some values of "handling", maybe.
17:29:54 <elliott> s/"\n/"/
17:30:04 <elliott> Oops, now fizzie's line is squashed into mine. :/
17:33:00 <kallisti> > let _ = 2 in _
17:33:01 <lambdabot> Pattern syntax in expression context: _
17:33:07 <kallisti> mmk
17:34:48 <elliott> "Thinking in typeclasses is IMO the best thing to do: it's really the most Haskellish."
17:34:56 <kallisti> wat
17:34:56 <elliott> Starting to become convinced that everyone but me is just crazy.
17:37:27 <elliott> ais523: btw, shouldn't it run less or ls | less, for consistency?
17:46:11 <fizzie> Deewiant: 'highlight' doesn't seem to do "pass through unrecognized data" all that well. I gave it a four-megabyte binary file and it just outputs the bytes 00000000 1b 5b 33 38 3b 35 3b 30 6d 1b 5b 6d 0a |.[38;5;0m.[m.| with --force.
17:47:30 <Deewiant> Meh, evidently so.
17:47:39 <Deewiant> $ highlight -qOxterm256 --force /bin/ls
17:47:39 <Deewiant> highlight: Undefined language definition. Use --syntax option.
17:47:39 <Deewiant> zsh: segmentation fault highlight -qOxterm256 --force /bin/ls
17:48:04 <fizzie> Personally I think it should just exec cat or something when it doesn't have a clue based on the file extension.
17:48:13 <Deewiant> That's what I thought --force would do.
17:48:32 <Deewiant> (With -q.)
17:48:33 <fizzie> "less /bin/ls" outputs "^?ELF^B^A^A" in blue now.
17:49:54 <elliott> yay! http://stackoverflow.com/users/1097181/ehird
17:50:12 <elliott> Deewiant: Couldn't you just use || cat %s?
17:50:17 <elliott> Assuming you can silence errors.
17:50:38 <Deewiant> I told it to be quiet and it still said "Undefined language definition" (and segfaulted).
17:51:28 <kallisti> I'm assuming sharing applies to typeclass constants right?
17:51:30 <Deewiant> Evidently it says that whenever the file has no extension.
17:51:36 <kallisti> it would be silly to calculate minBound for a type multiple times.
17:52:10 <elliott> Deewiant: You might want to report a bug. :p
17:52:15 <elliott> Anyway, 2>/dev/null and so on.
17:54:27 <fizzie> elliott: You're reputation is apostrophical.
17:54:32 <kallisti> http://sprunge.us/ELCM some code to generate Enum instances for 2-operand product types. feedback welcome.
17:54:41 <Deewiant> Well, -q is just "supress progress info in batch mode" [sic], so maybe 2>/dev/null is the canonical solution.
17:55:28 <elliott> http://en.wikipedia.org/wiki/Talk:Stack_Overflow#Partisanship_section_recuringly_censored_by_MICROSOFT_vendors
17:55:29 <elliott> http://en.wikipedia.org/wiki/Talk:Stack_Overflow#Criticism_.28October_2011.29
17:55:36 <elliott> TIL people on [[Talk:Stack Overflow]] are insane.
17:55:36 <fizzie> Deewiant: It does quiet the "unknown extension" message, though.
17:55:59 * elliott yells "MICROSOFT" every time it says "MICROSOFT".
17:56:15 <elliott> "but that discussing a (much faster) Free Web server using full ANSI_C scripts is "obvious advertising" (citation missing after the user account and all its posts have been censored)."
17:56:19 <elliott> this is amazing :D
17:56:30 <Deewiant> fizzie: Yes, that it does. In fact it seems a bit random about what it quiets and what it doesn't, based on a cursory reading of https://syntaxhighlight.svn.sourceforge.net/svnroot/syntaxhighlight/highlight/src/cli/main.cpp
17:56:46 <elliott> Hmm, it's by the vendors of this thing, which I have seen before: http://g-wan.com/
17:57:12 <kallisti> the only thing I can't generalize very well is the enum instance for PieceInfo, because it's essentially all special cases...
17:57:27 <fizzie> elliott: You'd better be a bit careful in gaining reputation, because once you clear the 50k mark you turn into MICROSOFT C# developper [sic] and a C# book author.
17:57:34 <elliott> "G-WAN (~100 KB) makes it a breeze by transparently parallelizing legacy procedural code."
17:57:36 <elliott> I'm sure it does.
17:57:44 <elliott> Also I like how you can't select text on that site.
17:57:49 <elliott> fizzie: Does that mean I get money?
17:58:06 <fizzie> It doesn't say.
17:58:13 <elliott> It sounds like money!
17:58:18 <elliott> More money than Haskell, anyway.
17:58:38 <elliott> "G-WAN makes C/C++ libraries fly:
17:58:38 <fizzie> Developping C# though... are you sure it's worth it?
17:58:41 <elliott> #pragma link "sqlite3""
17:58:48 <elliott> FLIGHT.
17:58:59 <elliott> fizzie: Well, I must be pretty good at it, if I've written books about it.
17:59:06 <elliott> Actually I suppose that doesn't hold for an awful lot of tech books out there.
17:59:43 <elliott> That's remarkably convenient.
18:00:11 <fizzie> elliott: You'll also start to make blattant lies.
18:00:21 <elliott> "who claimed during a conflict that he is a RUBY developer while in fact he works as a C# developer."
18:00:27 <elliott> fizzie: I might even start programming in more than one language!
18:00:38 <fizzie> "The fact that you are FAKING to be willing to investigate this issue is raising the question of the neutrality of Wikipedia moderators.."
18:00:42 <fizzie> The conspiracy, it's spreading.
18:01:01 <elliott> They're all MSFTies too.
18:01:07 <elliott> Once you get past 50k edits...
18:01:27 <elliott> "You are "only an Ordinary user" -of course. With a Wikipedia "User" page and the ability to lock-up (sorry, "Protect") a page against a properly documented MICROSOFT-BIAS"
18:01:27 <elliott> :D
18:01:32 <elliott> This just keeps getting better.
18:01:43 <elliott> You "Ordinary users" with your Wikipedia "User" pages.
18:02:13 <fizzie> I think he's drinking the Microsoft Kool-Aid. (Is that what you say?)
18:02:24 <fizzie> I don't know about idioms.
18:02:37 <elliott> And your bias in adding the notice is evident from the fact that you've added the "Criticism" the moment you were suspended from Super User. SathyaBhat (talk) 14:55, 24 October 2011 (UTC)
18:02:38 <elliott> As you list yourself as a StackOverflow moderator on your profile, I hardly consider you an unbiased source. [...]
18:02:38 <elliott> I'm not a Stack Overflow moderator. SathyaBhat (talk) 15:18, 24 October 2011 (UTC)
18:04:27 <fizzie> What's this "Super User" thing?
18:04:37 <kallisti> > toEnum 256 :: Word8
18:04:38 <lambdabot> *Exception: Enum.toEnum{Word8}: tag (256) is outside of bounds (0,255)
18:04:38 <elliott> fizzie: It's the Third Site in the Stack Overflow Trilogy.
18:04:45 <Deewiant> What's the second?
18:04:46 <elliott> fizzie: I swear this terminology is not made up.
18:04:50 <elliott> Deewiant: Server Fault.
18:04:58 <elliott> Server Fault is sysadmin stuff; Super User is general "computery" stuff.
18:05:13 <Deewiant> Oh, I thought Super User was the sysadmin one.
18:05:20 <Deewiant> Okay then.
18:05:51 <kallisti> I wonder if there's a way to automatically determine the minimal WordN type needed to represent maxBound of a type.
18:05:53 <elliott> fizzie: Help! Microsoft just hired me! http://en.wikipedia.org/w/index.php?title=Stack_Overflow&diff=471179936&oldid=469906030
18:06:08 <elliott> kallisti: Represent howso?
18:06:11 <elliott> Bounded doesn't imply integral.
18:06:14 <kallisti> well yes.
18:06:42 <elliott> kallisti: So I don't see how it makes sense.
18:06:48 <kallisti> hmmm...
18:06:56 <kallisti> for a Bounded Enum
18:07:00 <kallisti> how about that?
18:07:16 <elliott> kallisti: Well, Enum only offers ->Int conversion.
18:07:21 <elliott> So it fits into an Int.
18:07:25 <elliott> Apart from wrong instances.
18:07:30 <elliott> @src Integer fromEnum
18:07:31 <lambdabot> Source not found. I can't hear you -- I'm using the scrambler.
18:07:34 <elliott> Wrong instances like that.
18:07:40 <elliott> (Fuck the Prelude.)
18:07:57 <kallisti> right but you could convert it to a smaller integer type right?
18:08:12 <ais523> <elliott> ais523: btw, shouldn't it run less or ls | less, for consistency? <-- it's not about consistency, it's about convenience
18:08:13 <kallisti> how would you determine the minimum at compile time.
18:08:45 <kallisti> or is that generally an impossible thing to do because it requires runtime information (namely fromEnum (maxBound))
18:08:51 <elliott> kallisti: At compile-time? You can't, maxBounded isn't accessible at compile time; types can't depend on values, because Haskell is not Agda.
18:08:52 <fizzie> elliott: Hackage/Prelude "fromEnum :: a -> Int: Convert to an Int. It is implementation-dependent what fromEnum returns when applied to a value that is too large to fit in an Int." See, it can be bigger too, it just doesn't work then.
18:09:00 <elliott> fizzie: IT'S IMMORAL.
18:09:14 <fizzie> It's in YOUR oral.
18:09:27 <fizzie> I don't know what that meant.
18:09:36 <elliott> This channel is rated PG, man.
18:10:11 <ais523> hmm, what's responsible for printing "Segmentation fault" on a segfault? the kernel, sending to the process's stderr? to its controlling terminal?
18:11:16 <elliott> bash
18:11:17 <Deewiant> ais523: waitpid() and company return an exit status, from which the parent process (the shell) can determine that the child exited due to a segfault. Right?
18:11:17 <elliott> i think
18:11:27 <fizzie> I'd strongly suspect the shell, but I've never thought about it.
18:11:31 <fizzie> It'd sound the logical place.
18:11:31 <kallisti> I feel as though this Enum generator thing is probably something that someone has already done somewhere.
18:11:47 <elliott> :D there's a "bloomier filter"
18:12:06 <Deewiant> Given that zsh says "zsh: segmentation fault" it'd be very unexpected if it weren't the shell. :-P
18:12:24 <kallisti> do modules implicitly export typeclass instances that they import?
18:12:36 <kallisti> oh wait irrelevant
18:13:22 <elliott> kallisti: There is no control over importing/exporting instances.
18:13:26 <elliott> Instances just permeate the natural vacuum.
18:13:30 <kallisti> ah good
18:13:32 <elliott> If they can get to your code, they will.
18:13:36 <kallisti> that's what I thought
18:13:41 <elliott> (That's required by the open world assumption.)
18:13:42 <kallisti> but wasn't sure.
18:14:08 <elliott> (See my answer to http://stackoverflow.com/questions/8728596/explicitly-import-instances.)
18:14:45 <kallisti> maxBoundProd looks lonely without a minBoundProd. but in most cases it would just be toEnum 0
18:15:09 <kallisti> but it could NOT be that... I guess.
18:15:09 <Deewiant> elliott: Please leave a space after URLs so that hyperlinkifiers get it right; thanks.
18:15:45 <elliott> Deewiant: Your hyperlinkifier is seriously broken if it includes final dots.
18:15:57 <elliott> Also, <space><dot> is incredibly ugly. :(
18:16:01 <Deewiant> elliott: It includes the dot and the period.
18:16:09 <Deewiant> And that's a completely valid resulting URL.
18:16:14 <elliott> Deewiant: There's a difference between a dot and a period?
18:16:17 <Deewiant> Erm.
18:16:21 <Deewiant> The dot and the bracket.
18:16:42 <elliott> And yes, it is, but hyperlinkifiers have to extract URLs from language; there's a trade-off to be made where you must reject some valid URLs to be useful in the majority case.
18:16:55 <elliott> I suppose I could half-heartedly make an effort to enclose them <in brackets> in cases of ambiguity?
18:17:02 <elliott> (See my answer to <http://stackoverflow.com/questions/8728596/explicitly-import-instances>.)
18:17:04 <elliott> does that work?
18:17:06 <elliott> s/^d/D/
18:17:10 <Deewiant> Yeah, that seems to work.
18:17:54 <Deewiant> I'd rather have an inclusive linkifier and tell people to be machine-helpful when they paste URLs; it's easier to backspace characters off the end than add missing stuff, too. :-P
18:18:12 <fizzie> Deewiant: Also:
18:18:14 <fizzie> [htkallas@pc112 ~]$ echo "./segfault" | bash
18:18:14 <fizzie> bash: line 1: 24141 Segmentation fault ./segfault
18:18:14 <fizzie> [htkallas@pc112 ~]$ echo "./segfault" | env LC_ALL=fi_FI.UTF-8 bash
18:18:14 <fizzie> bash: rivi 1: 24144 Muistialueen ylitys ./segfault
18:18:30 <fizzie> (For some reason it won't obey LC_ALL if I give it -c "./segfault" instead.)
18:18:47 <Deewiant> Heh.
18:18:56 <elliott> fizzie: Probably it bubbles the signal up.
18:19:04 <elliott> Because -c is generally for non-interactive use.
18:20:52 <kallisti> ha ha ha monomorphism restriction you're funny.
18:21:34 <fizzie> elliott: It looks as if it execve's ./segfault without forking if I do a simple-command -c like that.
18:22:12 <fizzie> [htkallas@pc112 ~]$ LC_ALL=fi_FI.UTF-8 bash -c "./segfault"
18:22:12 <fizzie> Segmentation fault
18:22:12 <fizzie> [htkallas@pc112 ~]$ LC_ALL=fi_FI.UTF-8 bash -c "./segfault > /dev/null"
18:22:12 <fizzie> bash: rivi 1: 24200 Muistialueen ylitys ./segfault > /dev/null
18:22:21 <fizzie> I guess it makes sense, even if it's not quite what I'd expect.
18:22:24 <Deewiant> File a bug report about that changing behaviour.
18:22:45 <fizzie> At least it won't leave all those useless 'bash' processes around when people do "sh -c ..." from wherever.
18:23:04 <elliott> fizzie: Yes, file a bug. It will, at least, be amusing to see the laughter.
18:24:11 * kallisti notes that while the SO user from before was not allowed to use eVal as a variable name, it is perfectly acceptable for kallisti to do so.
18:24:18 <fizzie> I don't know, then I'd have to dig around the documentation first to see if it's mentioned somewhere.
18:24:30 <elliott> fizzie: That's what maintainers are there for!
18:24:36 <elliott> To do that for you and yell at you about it.
18:27:17 <ais523> is eVal hungarian notation?
18:30:56 <kallisti> no...
18:31:00 <kallisti> well, maybe
18:31:02 <kallisti> it is a value
18:31:03 <kallisti> >_>
18:31:12 <fizzie> According to one list, "e" is a prefix for enums.
18:31:35 <kallisti> it stands for "enum value" which is a shitty way of saying "the integer returned by the value in this expression that had an Enum instance and not the one that had both Enum and Bounded"
18:31:43 <kallisti> I'll let you determine which is shittier.
18:32:58 <elliott> foo
18:32:59 <elliott> :: (GArrow g (**3) u,
18:32:59 <elliott> GArrowDrop g (**2) b,
18:32:59 <elliott> GArrowCopy g (**) u1,
18:32:59 <elliott> GArrowCopy g (**2) b,
18:32:59 <elliott> GArrowSum g (**1) ((**2) a1 (Mu (Foo a1))),
18:33:01 <elliott> GArrowLoop g (**) u1) =>
18:33:03 <elliott> g a (Mu (Foo a1))
18:33:05 <elliott> Well this is going to be painful.
18:33:20 <pikhq_> So much type!
18:33:29 <fizzie> Also so full of stars.
18:33:40 <elliott> The best part is that those (**2) things aren't actually valid syntax.
18:33:47 <elliott> It just appends numbers without thinking, to operators.
18:34:13 <pikhq_> Is there some sort of GHC extension to make that work, or was this just written by a blithering idiot?
18:34:37 <elliott> pikhq_: "This" was written by the blithering idiot known as GHCi.
18:35:46 <pikhq_> Ah, classy.
18:38:28 <elliott> *Main> putStrLn . runHask $ foo
18:38:28 <elliott> \a -> let (b,c) = (((((\a -> (a,a)) . (Mu)) . (Foo)) . (\x -> case x of { Left y -> Left ((\_ -> ()) y); Right y -> Right y })) . (Right)) (a,c) in b
18:38:29 <elliott> Yay!
18:39:09 <kallisti> :t toInteger
18:39:10 <lambdabot> forall a. (Integral a) => a -> Integer
18:39:23 <elliott> Phantom_Hoover: Behold.
18:39:52 <kallisti> > fromEnum . succ . toInteger $ (maxBound :: Int)
18:39:53 <lambdabot> -9223372036854775808
18:39:55 <kallisti> lolwat
18:40:16 <elliott> > succ (maxBound :: Int)
18:40:17 <lambdabot> *Exception: Prelude.Enum.succ{Int}: tried to take `succ' of maxBound
18:40:21 <elliott> > 1 + (maxBound :: Int)
18:40:22 <lambdabot> -9223372036854775808
18:40:25 <elliott> kallisti: I simplified it for you.
18:40:33 <kallisti> well... yes.
18:40:53 <kallisti> negative enum indexes seem... bad.
18:41:13 <elliott> kallisti: Not really?
18:41:20 <elliott> enum foo { MAGIC_BLAH = ~0 }
18:41:22 <elliott> *};
18:42:09 -!- Vorpal has quit (Ping timeout: 240 seconds).
18:42:16 <elliott> Phantom_Hoover: I SAID BEHOLD.
18:42:20 <kallisti> well I guess now that I've rewritten numOf to not assume that minBound is 0, it's less of a problem.
18:42:46 <kallisti> still it makes the assumption that it's a contiguous interval (i.e. the enum doesn't only use even numbers or powers of two etc)
18:48:30 -!- pikhq has joined.
18:48:34 -!- pikhq_ has quit (Ping timeout: 252 seconds).
18:51:00 <kallisti> elliott: also are you sure that "they're used in C" is a good defense?
18:53:22 <elliott> kallisti: That's what Enum is for.
18:53:24 <elliott> An enumeration of values.
19:00:15 <Ngevd> Hello!
19:01:15 <elliott> hi
19:17:44 -!- ais523 has quit (Remote host closed the connection).
19:20:56 -!- MDude has joined.
19:49:59 -!- ais523 has joined.
20:03:05 -!- pikhq_ has joined.
20:03:23 -!- pikhq has quit (Ping timeout: 268 seconds).
20:04:15 <kallisti> what is the topological structure of the universe?
20:04:25 <kallisti> er rather
20:04:26 <kallisti> space
20:04:32 <kallisti> in the universe
20:05:00 <Ngevd> I read it was some sort of mobiusy dodecahedron or something somewhere
20:05:03 <Ngevd> Also...
20:05:06 -!- Ngevd has quit (Quit: ice cream).
20:05:23 <kallisti> dodecahedron wat
20:06:13 <elliott> kallisti: http://en.wikipedia.org/wiki/Shape_of_the_Universe
20:06:23 <elliott> kallisti: flat
20:06:45 <Phantom_Hoover> No.
20:06:56 <elliott> Phantom_Hoover: No? "The Wilkinson Microwave Anisotropy Probe (WMAP) has confirmed that the universe is flat with only a 0.5% margin of error.[1] Within the Friedmann-Lemaître-Robertson-Walker (FLRW) model, the presently most popular shape of the Universe found to fit observational data according to cosmologists is the infinite flat model,[2]"
20:07:51 <Phantom_Hoover> a) flat isn't a topological thing, it's a differential geometric thing; b) the Poincaré dodecahedron is homeomorphic to the 3-sphere, which isn't flat.
20:08:51 <Phantom_Hoover> a) is kind of splitting hairs, admittedly, and b) was due to a misunderstanding
20:09:09 <elliott> Phantom_Hoover: (a) Well, I was being liberal with my interpretation of kallisti; he tends to yell at me when I'm not. (b) Yeah, but that's just one of the models.
20:10:38 <Phantom_Hoover> elliott, no, I mean I assumed you were following on from Ngevd.
20:11:14 <elliott> Ah.
20:11:49 -!- oerjan has joined.
20:11:49 <kallisti> so uh... which one is it? :P
20:12:23 <elliott> kallisti: Which one of what?
20:12:27 <elliott> It's flat.
20:12:44 <kallisti> "flat" isn't a topological structure is it?
20:13:00 <elliott> Phantom_Hoover: Okay, I was too liberal.
20:13:04 <Phantom_Hoover> Flat here means R^3.
20:13:14 <kallisti> oh. okay.
20:13:17 <Phantom_Hoover> (With the usual topology, of course.)
20:13:52 <kallisti> I thought most scientists believe that the universe "wraps around"
20:13:55 <elliott> Phantom_Hoover: http://upload.wikimedia.org/wikipedia/commons/1/16/World_line.svg I like how this is indistinguishable from pseudoscience.
20:14:01 <elliott> kallisti: You thought wrong.
20:14:12 <elliott> kallisti: Also, it's not like you could ever find out, to my understanding.
20:14:15 <elliott> i.e. there is no way to reach the edge.
20:14:50 <Phantom_Hoover> You could find out, at least through application of the Copernican principle and measurement of the large-scale curvature.
20:16:07 <elliott> Well, OK, but I mean "you couldn't actually do it".
20:17:28 -!- Ngevd has joined.
20:17:31 <Ngevd> Hello!
20:18:12 <kallisti> I suppose it's entirely possible for the universe to be expanding and also infinite, given that the "expanding universe" thing technically means something more like "the distance between two parts of the universe grows over time" and less "lol it's finite and expanding into nothingness"
20:18:41 -!- pikhq_ has quit (Ping timeout: 240 seconds).
20:18:41 -!- pikhq has joined.
20:21:53 <kallisti> hm. so enumerating an arbitrary product type is actually kind of like a mixed radix numeral system.
20:22:50 -!- zzo38 has joined.
20:23:24 <kallisti> if I were to extend my code to product types with 3 operands I would be adding a "digit" whose base is multiplied by a power of two.
20:27:00 <ais523> kallisti: projectable product types, or patternmatchable product types?
20:27:11 <kallisti> I don't know the difference. "Haskell product types" :P
20:27:22 <ais523> Haskell's pure, so it doesn't matter ther
20:27:22 <kallisti> so probably the latter/
20:27:24 <ais523> *there
20:27:26 <kallisti> oh.
20:28:09 <kallisti> http://sprunge.us/Gcbh this is the 2-operand case. you can see how it looks like a 2-digit numeral system.
20:28:14 <kallisti> with mixed radix.
20:28:18 <ais523> I'm not going to spend 40 minutes discussing product types with someone and then not /use/ the resulting knowledge
20:28:31 <kallisti> lol
20:28:46 <kallisti> basically in fromEnumProd is where you can see the mixed radix.
20:29:38 <kallisti> numOf b returns the total number of elements of b's type. numOf True would return 2.
20:29:56 <kallisti> (it makes some assumptions about how the Enum instance is defined)
20:30:01 <Phantom_Hoover> <kallisti> I suppose it's entirely possible for the universe to be expanding and also infinite, given that the "expanding universe" thing technically means something more like "the distance between two parts of the universe grows over time" and less "lol it's finite and expanding into nothingness"
20:30:16 <Phantom_Hoover> This is precisely the current scientific consensus.
20:30:58 <kallisti> oh good.
20:31:00 <elliott> Phantom_Hoover: Eventually we're going to need big magnets to keep everything close enough.
20:31:20 <kallisti> does this mean I'm actually increasing in volume? :P
20:31:48 <zzo38> I don't think so
20:31:49 <Phantom_Hoover> I don't think it's possible to stop it; one of the scenarios for the end of the universe is the expansion overwhelming all binding forces and ripping every particle into its constituents.
20:31:51 <Phantom_Hoover> kallisti, no.
20:32:13 <Phantom_Hoover> The bonds holding you together are slightly strained by the expansion, but they aren't pulled apart.
20:32:31 <kallisti> that doesn't sound like an "end of the universe" but just "an end of matter as we know it"
20:33:22 * kallisti isn't sure how to write the inverse function for an n-operand product type...
20:33:31 <kallisti> I guess I could define an applicative? maybe
20:35:09 <kallisti> I need a way to take an integer and a constructor with any number of arguments and fill all of its fields with values.
20:35:41 <kallisti> every field needs to be Bounded and Enum, except for the last one, which can be just Enum.
20:36:21 <kallisti> oh wait no they all need to be Bounded I think.
20:36:37 <elliott> <Phantom_Hoover> I don't think it's possible to stop it; one of the scenarios for the end of the universe is the expansion overwhelming all binding forces and ripping every particle into its constituents.
20:36:43 <elliott> Phantom_Hoover: Excuse me are you suggesting magnets will get less powerful.
20:36:48 <elliott> (Also I know that you dolt.)
20:36:53 <Phantom_Hoover> Yyyyes.
20:37:39 <elliott> Phantom_Hoover: But what will ICP do?
20:40:04 <elliott> Phantom_Hoover: Also couldn't you just use a really really dense powerful magnet.
20:40:11 <elliott> We just need to keep creating larger magnet galaxies.
20:40:54 <kallisti> yes this is exactly like a mixed radix numeral system. shocking.
20:43:54 <oerjan> kallisti: see also instance Ix for tuples
20:47:29 <kallisti> it's pretty difficult to read..
20:47:39 <elliott> @src (,) index
20:47:40 <lambdabot> Source not found. The more you drive -- the dumber you get.
20:47:41 <elliott> @src (,) range
20:47:42 <lambdabot> Source not found. There are some things that I just don't know.
20:47:42 <elliott> hmph
20:47:53 <elliott> wouldn't it be nice if @src actually worked.
20:47:55 <kallisti> http://www.haskell.org/ghc/docs/6.12.2/html/libraries/base-
20:48:25 <elliott> kallisti: "6.12.2"
20:48:33 <kallisti> whatever
20:48:57 <oerjan> it's not immensely likely to have changed
20:49:18 <elliott> oerjan: considering that the latest docs do _not_ include ghc.arr...
20:49:28 <oerjan> O KAY
20:49:31 <elliott> though http://www.haskell.org/ghc/docs/latest/html/libraries/base/src/GHC-Arr.html works
20:49:42 <elliott> oerjan: if you keep replying to everything with O KAY it'll become annoying :P
20:49:51 <oerjan> O KAY
20:49:58 <elliott> cough
20:50:07 <oerjan> oh no, not the coughing
20:53:14 <Ngevd> I am GOING TO READ A BOOK.
20:53:16 <Ngevd> MADE OF PAPER
20:55:42 <elliott> Phantom_Hoover: Have I told you about how we don't have electricity in Hexham?
20:55:48 <Phantom_Hoover> Linear algebra is not as boring as I'd thought.
20:55:50 <elliott> Ngevd: What's the book.
20:56:03 <Ngevd> The Girl with the Dragon Tatyoo
20:56:06 <elliott> Tatyoo.
20:56:13 <Ngevd> That was a ytpo
20:56:25 <kallisti> oaky
20:58:01 <zzo38> I also read the books made of paper, when resting in bed
20:58:17 <elliott> Phantom_Hoover: What are the books made out of in Edinburgh?
20:58:25 <Ngevd> This book is set in Sweden.
20:58:36 <Phantom_Hoover> Raw abstraction.
20:58:47 <Ngevd> I understand there is at least one person who lives in Sweden who frequents this channel
20:58:58 <elliott> Ngevd: Yes, and he's terrible.
20:59:11 <Ngevd> Ooh, maybe he's the killer!
20:59:22 <oerjan> Ngevd: it's originally in swedish, yes
20:59:24 <Ngevd> Dammit, elliott, you've ruined the ending for me!
20:59:43 <elliott> oerjan: Just like you.
21:00:20 <oerjan> elliott: jag fattar inte vad du pratar om
21:00:29 <kallisti> zzo38: in that chess server program you were talking about a long time ago, does the server randomly select who's black and white?
21:01:08 <elliott> oerjan: "You're fat, also bad; do you pratar om?"
21:01:24 <zzo38> kallisti: Free Internet Chess Server? I do not remember now, but I think there is an option to do that but it does not always do that
21:01:43 <oerjan> elliott: hey i cannot disagree with you making a translation that insults you
21:01:47 <kallisti> zzo38: the way I see it working is you choose a preference.
21:01:53 <kallisti> either white, black, or no preference
21:01:55 <kallisti> or
21:02:03 <kallisti> if there's a ranking system, then unfavored players are given white.
21:02:06 <zzo38> kallisti: That does make sense is one way
21:02:16 <kallisti> or some mix of the two.
21:02:20 <zzo38> I think, choose the preference.
21:02:37 -!- monqy has joined.
21:02:48 <kallisti> yes. a ranking gsystem implies a) an actual userbase b) a consistent set of rules
21:02:51 <kallisti> of which I have neither.
21:03:09 <kallisti> now if there were a tournament, with a consistent set of rules between each game, then a ranking system would be reasonable.
21:03:11 <zzo38> Possibly in case both player preference, players with lower ranking preference override, but in general you match up such that preferences agree instead of conflict so you do not have to use the rankings
21:03:32 <kallisti> yes that sounds good.
21:05:42 <kallisti> so the preference should be indicated as part of the standard "greeting" between a client and server.
21:06:27 <Ngevd> Is 2.4 million kronor a lot?
21:07:01 <elliott> Phantom_Hoover: So wait, is everything in Edinburgh made out of raw abstraction?
21:07:06 <zzo38> "Do you want to play [f]irst, [s]econd, or [n]o preference?"
21:07:15 <Phantom_Hoover> elliott, yes.
21:07:23 <elliott> Phantom_Hoover: What about the sandstone?
21:07:25 <Phantom_Hoover> How else do you think a Phantom_Hoover such as myself could live there.
21:07:36 <Phantom_Hoover> elliott, raw abstraction and sandstone.
21:07:54 <elliott> Phantom_Hoover: Ah.
21:08:07 <elliott> Phantom_Hoover: I forget, are you a hoover that hoovs phantoms or a hoover that is a phantom?
21:08:08 <Phantom_Hoover> Sandstone is a very good abstract building material.
21:08:13 <elliott> I always forget.
21:08:19 <Phantom_Hoover> A hoover that is phantom.
21:08:27 <kallisti> zzo38: I don't really know if I intend to set it up that way. perhaps.
21:08:37 <Ngevd> I'm a Taneb who is a Ngevd who is about to leave
21:08:38 -!- Ngevd has quit (Quit: Goodbye).
21:08:45 <elliott> Phantom_Hoover: I really hope you one day use the name Phantom Hoover in an official capacity and get sued by the Hoover company.
21:08:49 <Sgeo> kallisti, elliott Phantom_Hoover darnnit Ngevd left update
21:08:53 <Sgeo> Who else?
21:08:55 <elliott> Phantom_Hoover: Wait why don't you change your name to Phantom Hoover, it's way more pronouncable.
21:09:08 <kallisti> zzo38: I do want it to be text-based in a way that allows you to connect through telnet. or a simple text-based client that memorizes settings for you, so that you can automate any kind of client-server greeting
21:09:20 <elliott> Sgeo: You LIED to me.
21:09:30 <Sgeo> elliott, what?
21:09:50 <Phantom_Hoover> monqy
21:10:01 <kallisti> zzo38: so there would be a prefer command. if you don't send a prefer command then it defaults to no preference.
21:10:06 -!- ais523 has quit (Write error: Connection reset by peer).
21:10:06 <Phantom_Hoover> elliott, my name was Phantom_Hoover until IRC ruined it.
21:10:06 <Phantom_Hoover> cf. the wiki.
21:10:13 <monqy> hi
21:10:17 <kallisti> zzo38: other settings would work similarly. for example, there are a number of rule preferences you can make.
21:10:29 -!- ais523_ has joined.
21:10:33 -!- ais523 has joined.
21:10:33 -!- ais523 has quit (Write error: Broken pipe).
21:10:38 -!- ais523_ has changed nick to ais523.
21:11:16 <Sgeo> Phantom_Hoover, I don't think monqy wants to be on my list?
21:11:18 <Sgeo> I may be wrong
21:11:27 <Sgeo> I should make a macro or something
21:11:41 <Phantom_Hoover> Sgeo, i want him to suffer
21:11:50 <elliott> <Phantom_Hoover> elliott, my name was Phantom_Hoover until IRC ruined it.
21:11:53 <elliott> Phantom_Hoover: I meant your IRL name?
21:12:06 <elliott> Sgeo: There was no update.
21:12:15 <Phantom_Hoover> Because everyone would give me funny looks.
21:12:17 <Phantom_Hoover> elliott, there was.
21:12:28 <Sgeo> elliott, yes there was, unless you checked like two seconds before I announced and read it already
21:12:36 <elliott> Oh, there it is.
21:12:44 <elliott> Phantom_Hoover: Dude, you're called Ahamhmahnahmnhahhnahanin McCuil.
21:12:50 <elliott> Phantom_Hoover: Your funny lookage would *decrease*.
21:13:06 <Phantom_Hoover> elliott, I don't actually recall saying you could disclose that in the channel.
21:13:38 <elliott> Phantom_Hoover: (a) I spelled it terribly (b) Dude it was originally in the channel.
21:13:54 <elliott> It's also been in the channel multiple times since originally being in the channel?
21:14:21 <Phantom_Hoover> I still don't recall saying that.
21:14:43 <elliott> 2011-04-15.txt:08:55:14: -!- Phantom_Hoover is now known as A_McCuil.
21:14:56 <Phantom_Hoover> Humm.
21:15:08 <elliott> First occurrence of "McCuil" (case insensitive) 2010 onwards.
21:16:22 <elliott> Phantom_Hoover: Other reasons to change your name to Phantom Hoover: You'll no longer be named after a crappy search engine.
21:16:36 <Phantom_Hoover> Cuil was not crappy.
21:17:00 <elliott> Phantom_Hoover: OK, *innovative search engine
21:17:10 <shachaf> elliott: I see that you bothered.
21:17:13 <elliott> Innovative in areas such as, for example, not returning relevant results.
21:17:24 <elliott> shachaf: I was running close to the cap and wanted accept rep.
21:17:33 <elliott> shachaf: :(
21:17:34 <kallisti> elliott: the innovation has been around since long before.
21:17:35 <Phantom_Hoover> It did, however, produce extremely entertaining results.
21:17:37 <kallisti> *that
21:17:39 -!- Ngevd has joined.
21:17:42 <Ngevd> Hello!
21:18:01 <Phantom_Hoover> It didn't get you where you meant to go, but where you secretly wanted to go, and is that not the greater journey.
21:18:06 * oerjan recalls cuils are very abstract
21:18:14 <elliott> Phantom_Hoover: FWIW I'm happy not to mention the string that is approximately 100x too ridiculous to be your name in-channel if you don't want me to.
21:18:18 <elliott> Ngevd: How quickly did you read.
21:18:21 <oerjan> Ngevd: 2.4 million Swedish kronor = 223 598.928 British pounds
21:18:26 <Ngevd> Not quickly enough
21:18:29 <elliott> Phantom_Hoover: Also, slapping B-coloured paint on A, etc.
21:18:36 <Ngevd> oerjan, hmm... I could do with that amount of money
21:19:06 <kallisti> > let (a, a) = (2,2) in a
21:19:06 <lambdabot> Conflicting definitions for `a'
21:19:06 <lambdabot> Bound at: <interactive>:1:5
21:19:07 <lambdabot> <in...
21:19:10 <kallisti> this should be a thing.
21:19:27 * shachaf should create fake SO questions that steadily grow more and more annoying.
21:19:30 <elliott> kallisti: gb2Prolog HTH HAND
21:19:37 <Phantom_Hoover> gb2?
21:19:39 <Ngevd> > let (a, _) = (2, 2) in _
21:19:41 <lambdabot> Pattern syntax in expression context: _
21:19:41 <kallisti> get back to
21:19:41 <elliott> Phantom_Hoover: Go back to.
21:19:50 <elliott> shachaf: That would be indistinguishable from SO.
21:20:03 <shachaf> elliott: I think you underestimate me.
21:20:10 <Sgeo> Ngevd, in a, not in _
21:20:13 <kallisti> elliott: I'm trying to think of a situation where such a thing would be useful.
21:20:24 <shachaf> The goal would be to see how long you could last before going *actually* insane.
21:20:29 <kallisti> but I don't think it would be too difficult to implement would it?
21:20:36 <shachaf> kallisti: What do you want this to do, exactly? Compare with (==)?
21:20:48 <kallisti> whatever case does.
21:20:58 <shachaf> No, you don't want structural equality.
21:21:04 <shachaf> What if a is a function?
21:21:27 <shachaf> What if a is a Set, and you have two equivalent sets that are represented using different trees?
21:21:29 <Sgeo> > let f id = 5 in f id
21:21:30 <lambdabot> 5
21:21:33 <Sgeo> !
21:21:36 <kallisti> I... don't know.
21:21:42 <shachaf> What if a is a data structure that has cycles in it?
21:21:44 <Sgeo> How... what
21:21:48 <kallisti> I guess Eq would work, but maybe isn't the best way?
21:21:56 <shachaf> > let f q = 5 in f id
21:21:56 <Sgeo> > let f id = 5 in f (id . id)
21:21:57 <lambdabot> 5
21:21:57 <lambdabot> 5
21:22:07 <Sgeo> > let f id = 5 in f undefined
21:22:08 <lambdabot> 5
21:22:14 <shachaf> kallisti: The best way is probably not to do it.
21:22:14 <Sgeo> Oh
21:22:33 <Sgeo> ...oh
21:22:33 <Ngevd> :t let f id = 5 in f
21:22:34 <lambdabot> forall t t1. (Num t1) => t -> t1
21:22:41 * Sgeo suddenly sees the obvious
21:22:46 <Sgeo> (Before the type)
21:23:02 <shachaf> Before the type, all IRC users are equal.
21:23:31 <Sgeo> > let num = (1::Int) in let f num = num in f 2
21:23:32 <kallisti> I am great confused waht tpye
21:23:32 <lambdabot> 2
21:24:04 <Sgeo> I guess there's no way to make the pattern thing see variables outside the pattern, nor any meaning towards trying to do so
21:24:29 <kallisti> correct
21:26:18 <elliott> <Sgeo> > let f id = 5 in f id
21:26:18 <elliott> <lambdabot> 5
21:26:18 <elliott> <Sgeo> !
21:26:18 <elliott> <Sgeo> How... what
21:26:34 <elliott> On this day elliott died by putting his palm on his face so hard that it went straight through.
21:27:11 <kallisti> elliott: hi now is the time where you have an opportunity to talk me out of using a monad transformer.
21:27:15 <Sgeo> elliott, I managed to trick myself into thinking it was magically pattern matching on the function known as id
21:27:32 -!- oerjan has set topic: Scottish clan invades Hexham, demands apology for calling their name "ridiculous" | http://codu.org/logs/_esoteric/.
21:27:43 <elliott> kallisti: You're stupid and dumb and your code sucks and I hate you.
21:27:45 <elliott> Oh, *monad* transformer.
21:27:51 <elliott> Uh, shachaf doesn't like them.
21:28:05 <Phantom_Hoover> shachaf, why do you not like monad transformers.
21:28:14 <Phantom_Hoover> They're like burrito transformers!
21:28:19 <elliott> oerjan: Unfortunately they're made out of pure abstraction and thus pass right through normal matter.
21:28:27 <Sgeo> > let f (\x -> x) = 5 in f id
21:28:27 <Phantom_Hoover> They turn burritos into spacesuits containing toxic waste.
21:28:27 <lambdabot> <no location info>: Parse error in pattern
21:28:28 <elliott> Phantom_Hoover: I don't like them either, if that means anything to you.
21:29:11 <Ngevd> Oh dear, the Scottish clan is invading Hexham again
21:29:19 <Ngevd> Don't forget to burn the Abbey!
21:29:30 <oerjan> elliott: you shouldn't underestimate their sandstone ballistas
21:29:38 <kallisti> well I will make use of both IO and State. I will begin coding with both monads seperate and see if I ever need them at the same time.
21:29:52 <kallisti> or if I can avoid doing so altogether
21:30:00 <Phantom_Hoover> Ngevd, we will abstract burn them.
21:30:01 <monqy> Sgeo: do you not understand what was happening
21:30:16 <elliott> Phantom_Hoover: Yes, so they'll be abstractly burned but not concretely.
21:30:20 <Phantom_Hoover> elliott, I don't know much about them; I'm interested in what's wrong with them?
21:30:27 <Phantom_Hoover> Monad transformers, that is.
21:30:29 <Sgeo> monqy, I figured it out
21:30:39 <Sgeo> * Sgeo suddenly sees the obvious
21:30:54 <elliott> Phantom_Hoover: They don't compose well.
21:31:03 <Sgeo> id in f id = was just a variable in the pattern to be assigned to whatever the argument was
21:31:37 <elliott> Phantom_Hoover: The order you apply transformers in can have often confusing changes to the semantics; also, there's no real unified "theory" or definition of monad transformers. They're just things that turn Monad instances into other Monad instances where you can lift actions of the inner Monad in.
21:31:38 <monqy> > let 2 + 2 = text "~the wonders of shadowing~" in 2 + 2
21:31:39 <lambdabot> ~the wonders of shadowing~
21:31:50 <elliott> Phantom_Hoover: That sounsd specific, but in reality it means that monad transformers can pretty much do anything.
21:31:59 <Phantom_Hoover> elliott, no, I get what you mean.
21:32:02 <elliott> When turning a monad into its transformer, there's no mechanical rule for telling where you layer on the "m"s.
21:32:28 <elliott> As far as operational concerns go, they can be pretty damn slow, because every single bind you perform has to go through N layers of wrapping.
21:32:41 <elliott> I mean, there's a RWST that's just ReaderT, WriterT, and StateT bundled together for performance.
21:33:01 <kallisti> I'm not entirely sure I understand the purpose of RWS
21:33:04 <elliott> (I guess "convenience" too, but it could just be a type synonym if that was the real reason.)
21:33:12 <kallisti> it seems that State works well for all three of these things.
21:33:23 <elliott> kallisti: Yes, and you can write all your code in IO, too.
21:33:33 <elliott> Using State for all of those is great, because you can write to your read-only state!
21:33:38 <elliott> And reverse your monoidal accumulator.
21:33:40 <shachaf> MONAD TRANSFORMERS R DUM
21:33:42 <shachaf> That's why.
21:33:46 * shachaf QED
21:33:56 <elliott> shachaf: I think Phantom_Hoover will find your criticism tau times as convincing as mine.
21:34:03 <elliott> s/sounsd/sounds/
21:34:06 <Sgeo> So basically, needing to learn new semantics for each monad transformer independent of the semantics of the monad?
21:34:08 <elliott> s/}/ }/ way up
21:34:24 <elliott> Sgeo: Well, no, what they do is usually intuitively obvious.
21:34:27 <elliott> That's not saying much, though.
21:34:34 <elliott> Oh, yeah, and it's really hard to "combine" monad transformer stacks.
21:34:38 <elliott> You pretty much have to define one stack and stick to it.
21:34:53 <elliott> You can't say "this code needs <list of effects>, this other code needs <other list of effects>, and this code uses both the previous codes".
21:34:57 <shachaf> elliott: So at least one of our criticisms was irrational.
21:35:04 <elliott> At least not without a LOT of threading stuff manually to run it all.
21:35:09 -!- Ngevd has quit (Quit: Goodbye).
21:35:10 <shachaf> Oh, wait, you're giving actual justifications.
21:35:11 <oerjan> what we need is a monad transformer zipper!
21:35:52 <elliott> Phantom_Hoover: FWIW my current favourite solution to the problem of composable effects is http://math.andrej.com/2010/09/27/programming-with-effects-ii-introducing-eff/, which I especially like because there's no leap of syntax from pure code to an effect.
21:36:00 <elliott> With Haskell you need to, at the very least, interleave <$> and <*> everywhere.
21:36:04 <oerjan> elliott: hey that's what Monad* classes are for
21:36:14 * kallisti considers what he could possibly use RWS for in his portal chess implementation.
21:36:27 <kallisti> writer could be used for a log.... but, do I need one of those?
21:36:30 <elliott> oerjan: Yeah, and you can't define context synonyms, so all your method signatures are 10x larger! \o/
21:36:46 <elliott> oerjan: Also, if the compiler doesn't inline it away, you get to pass around a hundred typeclass dictionaries everywhere!
21:36:53 <elliott> s/method signatures/definition signatures/
21:37:06 <elliott> oerjan: Oh, and you can't have two pieces of state in the same stack.
21:37:15 <elliott> That's just not allowed. Everyone only needs one piece of state.
21:37:44 <Sgeo> elliott, hmm? Surely you can if you drop the convenience of MonadState?
21:37:55 <elliott> Sgeo:
21:38:00 <elliott> <elliott> Oh, yeah, and it's really hard to "combine" monad transformer stacks.
21:38:00 <elliott> <elliott> You pretty much have to define one stack and stick to it.
21:38:00 <elliott> <elliott> You can't say "this code needs <list of effects>, this other code needs <other list of effects>, and this code uses both the previous codes".
21:38:00 <elliott> <elliott> At least not without a LOT of threading stuff manually to run it all.
21:38:03 <elliott> <oerjan> elliott: hey that's what Monad* classes are for
21:38:13 <elliott> Phantom_Hoover: I BET YOU'RE NOT EVEN READING THAT
21:38:33 <Phantom_Hoover> I was reading, does that count??
21:38:34 <oerjan> elliott: Phantom_Hoover thinks this was far too concrete for an abstraction
21:38:35 <elliott> shachaf: You should read it too, unless you did since I told you ages ago.
21:39:14 <Sgeo> What's with the def and nonsense?
21:39:39 <Sgeo> Tastes like... ML?
21:39:46 <kallisti> I wonder if Valve will hunt me down if I make advertisement money off of portal chess. :P
21:39:56 <ais523> kallisti: just name it something other than portals
21:40:00 <elliott> Sgeo: Well, it's not like you can do mutually-recursive definitions any other way at a REPL.
21:40:04 <shachaf> elliott: Read what? "introducting eff"?
21:40:05 <elliott> But yes, the authors are ML people.
21:40:13 <elliott> shachaf: Yes. I told you to the last time monad transformers came up.
21:40:19 <shachaf> It's in my list-of-things-that-I'll-ostensibly-read-someday!
21:40:25 <shachaf> Isn't that enough for you, elliott?
21:40:32 <ais523> elliott: I had an INTERCAL REPL idea that each line you wrote would append to a program
21:40:36 <elliott> shachaf: NO READ NOW.
21:40:37 <shachaf> There are only about a hundred other tabs in that list!
21:40:44 <elliott> shachaf: It's like 3 pages long, dude
21:40:45 <ais523> and it'd rerun the program from scratch each time, discarding any output that was the same as last time
21:40:46 <elliott> DUDE.
21:40:48 <elliott> ais523: heh
21:40:51 <ais523> that way, even COME FROM would work properly
21:41:27 <shachaf> elliott: Fine, I'll move it to the end of that list.
21:41:32 <shachaf> I always start from the end.
21:41:47 <elliott> shachaf: OK, and then start now.
21:41:55 * shachaf should probably wake up now.
21:42:13 <oerjan> alles hat ein ende nur die wurst hat zwei
21:42:53 <elliott> ais523: In an emergency situation, could you crudely fashion an antistatic wristband by crouching on a computer case?
21:43:15 <ais523> elliott: depends on if the case is earthed
21:43:25 <ais523> which it probably will be if it's made of metal, not painted, and plugged in
21:43:29 <ais523> 1 and 3 are likely, 2 may not be
21:43:32 <kallisti> liftCatch :: (m (a, s, w) -> (e -> m (a, s, w)) -> m (a, s, w)) -> RWST l w s m a -> (e -> RWST l w s m a) -> RWST l w s m a
21:43:35 <kallisti> mmmmmm
21:43:39 <ais523> (the paint would make the outside not earthed, although the inside would be)
21:44:04 <elliott> ais523: thanks, I'll let my supernatural vacuum cleaner friend know
21:44:10 <oerjan> earth tone painting
21:44:33 <ais523> elliott: this is a really bizarre question, anyway
21:44:42 <ais523> a good emergency antistatic wristband is water pipes, anyway
21:44:44 <elliott> wow, TPB are switching to magnet links exclusively
21:44:49 <ais523> they're often unpainted, and quite commonly found around houses
21:45:15 <Phantom_Hoover> 'Often'?
21:45:23 <Phantom_Hoover> I don't think I've ever seen painted water pipe— oh wait you don't mean taps.
21:45:32 <Phantom_Hoover> (I used a tap to assuage my paranoia.)
21:45:33 <ais523> and pretty much every house has their entire water supply system earthed because it saves on money for earth wires
21:45:45 <elliott> Phantom_Hoover/tap otp
21:45:49 <ais523> well, on the flip side, sometimes taps are made of plastic
21:46:18 <Phantom_Hoover> elliott, no, I'd have to be one of those hoovers that works with water (these are a thing apparently, it said so on Postman Pat once).
21:46:32 <ais523> Phantom_Hoover: I think we actually own one
21:46:41 <ais523> haven't used it in years, though
21:46:44 <elliott> Phantom_Hoover: Reference 1. Postman Pat
21:46:58 <oerjan> Phantom_Hoover: my aunt has one
21:47:07 <ais523> used it occasionally to wash the carpet, rather than just vacuum-clean it
21:47:25 <shachaf> elliott: You're missing out on #haskell
21:47:41 <shachaf> <carpi> okay.. i solved the problem.. but it really makes me think that haskell is dead slow. when it was taking more than 20 minutes.. i thought i made a mistake somwhere.. but that doesn't seem to be the case.. after 20 minutes my code gav me the right answer..which leads me to believe that my code was correct..but haskell was dead slow..
21:47:47 <shachaf> <carpi> 20 minutes is simply inexcusable
21:48:19 <monqy> is carpi for real
21:50:14 <shachaf> <carpi> koeien: could you please tell me why do you recommend data.set? what aspect of the problem makes you think that using data.set would make it run faster?
21:50:15 <kallisti> so if I use Lazy RWS, this means I can call runRWS and get things like i.e. infinite lists of output to pass to channels/sockets/filehandles etc
21:50:24 <kallisti> right?
21:50:58 <elliott> shachaf: Did you suggest -O2?
21:51:02 <elliott> Did anyone suggest -O2?
21:51:02 <kallisti> if I used strict RWS I would want to add IO to the stack.
21:51:05 <elliott> I bet carpi is running in GHCi.
21:51:29 <kallisti> elliott: yes oxygen is generally helpful when problem solving.
21:51:31 <shachaf> ghci -O2 is the obvious answer.
21:51:38 <elliott> kallisti: Don't use lazy input.
21:51:51 <elliott> shachaf: Come on, you have to suggest -O2, it hurts me inside.
21:52:10 <kallisti> elliott: okay, so then I don't want to use lazy RWS, because I'm pretty sure I'd want lazy input.
21:52:11 <shachaf> elliott: Why don't you suggest it?
21:52:47 <elliott> 02:36:01 <Eduard_Munteanu> carpi: think of 'main' as a function that produces a list of things the runtime has to do, like write a file, read stdin etc.
21:52:47 <elliott> 02:36:43 <Eduard_Munteanu> carpi: the things the runtime does for you is stuff that gets "executed"
21:52:47 <elliott> 02:38:40 <carpi> and by runtime are you referring to the part where actions are performed by systems outside haskell on behalf of haskell?
21:52:47 <elliott> 02:39:47 <Eduard_Munteanu> carpi: the RTS
21:52:48 <elliott> 02:42:57 <carpi> ah okay.. i googled RTS for haskell.. seems like its an option for ghc where i can tweak the environment in which the haskell code can run. This is exciting..so it means i can make code more faster this way
21:52:58 <elliott> shachaf: Because I'd join and go "HI, SHACHAF PASTD ME LOGS TO MOCK YOU, USE -O2" and no.
21:53:03 <kallisti> elliott: or are you saying /in general/ not to use lazy input?
21:53:11 <elliott> kallisti: In general.
21:53:16 <shachaf> elliott: Hey, I wasn't *mocking*! I was sharing.
21:53:40 <kallisti> elliott: ...really?
21:53:44 <elliott> kallisti: Unless you want space leaks, resource allocation problems, unpredictable performance, ...
21:53:47 * shachaf imagines it: * elliott has join #haskell <elliott> USE -O2! <elliott> WHY ISN'T ANYONE TALKING ABOUT -O2??? <elliott> SOMEONE MENTION -O2, YOU USELESS CHANNEL! * elliott has left #haskell [RAGE]
21:53:51 <elliott> ... difficult-to-debug IO problems ...
21:54:11 <kallisti> elliott: so you mean lazy input is a bad idea for programs that are moderately complicated.
21:54:20 <kallisti> but okay for simple things.
21:54:35 <elliott> kallisti: No.
21:54:45 <pikhq> Lazy IO is "good" for the following: trivial examples.
21:54:45 <elliott> Lazy input is useful only for toy hacks.
21:54:59 <elliott> i.e. programs you will run less than 5 times ever.
21:55:02 <kallisti> I see.
21:55:10 <elliott> Or, I suppose, programs that are thiny-veiled wrappers over a trivial pure function.
21:55:15 <shachaf> elliott: Nonsense.
21:55:25 <shachaf> There's also the second thing you mentioned.
21:55:34 <shachaf> And probably there are other justified uses for lazy I/O.
21:55:34 <kallisti> elliott: and here I thought lazy input was something that made Haskell awesome to use. :P
21:55:54 <elliott> shachaf: Well, "interactive multi-user network server" isn't one.
21:56:21 <oerjan> who cares about multiple users anyway
21:56:25 <elliott> kallisti: You might like enumerators or conduits or whatever, since they were designed to offer the convenience of lazy IO without the problems.
21:56:41 <elliott> They don't really succeed at the convenience part, but I hear the problems they have are new and specific to their solutions.
21:57:21 <kallisti> elliott: I'm guessing they generalize to many different sources of IO? i.e. sockets, filehandles, concurrent channels
21:57:28 <elliott> shachaf: 13:10:18 <carpi> koeien: yea in ghci
21:57:30 <elliott> shachaf: Told you.
21:57:41 <elliott> kallisti: Yes, although in GHC sockets are Handles.
21:57:48 <elliott> (Yes, there's the lower-level interface, but you almost never need to use it.)
21:57:50 <kallisti> oh that's right.
21:58:15 <elliott> kallisti: Conduits are the hip new thing, but I have a predisposed bias against them. On the other hand, enumerator is possibly even more overcomplicated, so...
21:58:16 <shachaf> elliott: I'm pretty sure Haskell is just dead slow.
21:58:27 <Deewiant> elliott: What bias?
21:58:35 <elliott> Conduits are better at the resource management thing, anyway.
21:58:36 <kallisti> elliott: what about things like.... a simple recursive loop.
21:58:47 <elliott> Deewiant: Well, I don't like them. :p
21:58:52 <Deewiant> elliott: Why not? :-P
21:59:03 <elliott> Deewiant: They use mutable references to maintain basic internal state, for one.
21:59:25 <elliott> Just because their interface is basically "stateless" but, hey, they run in ST or IO, so let's just use refs!
22:00:18 <elliott> Also, they seem very much "engineer-designed", in that there's no coherent underlying semantics or theory at all, there's just a bunch of types that usually have too many members and appear to be essentially "ad-hoc" OOP-ish object records where more things were added on to accomplish additional needs like resource management.
22:00:39 <elliott> Which works, sure, but is bad news for something so "basic" and underlying as stream processing.
22:00:48 <elliott> Also, "quotes".
22:01:00 <Deewiant> Alright.
22:01:51 <elliott> Deewiant: Anyway, not necessarily that enumerator or anything seems any more coherently designed, but at least there's good signs like functions, simple ADTs, use of closures to maintain internal state, etc.
22:02:25 <kallisti> elliott: a simple glance at the top-level module for both enumerator and conduit suggests that enumerator is conceptually simpler.
22:02:39 <elliott> Deewiant: Mostly I think that we're close enough to coming up with a consistent and simple underpinning for iteratees that throwing everything away to start afresh right before that happens is a waste.
22:02:49 <elliott> kallisti: I suspect people will begin abandoning enumerator in droves.
22:02:55 <elliott> kallisti: Anyway, enumerator is painful to use in practice.
22:03:07 <elliott> Largely because there's about 10 composition operators and you usually just have to guess which one you need.
22:03:32 <elliott> http://hackage.haskell.org/packages/archive/conduit/0.0.3/doc/html/Data-Conduit.html#g:5 -- at least conduit's are simple.
22:03:50 <kallisti> there's many more types though. I don't really know where to start.
22:04:48 <kallisti> SourceResult is simple enough. :P
22:04:51 <elliott> kallisti:
22:04:55 <elliott> http://www.yesodweb.com/blog/2011/12/resourcet
22:04:55 <elliott> http://www.yesodweb.com/blog/2011/12/conduits
22:05:00 <elliott> http://www.yesodweb.com/blog/2011/12/conduits-sink
22:05:05 <elliott> http://www.yesodweb.com/blog/2012/01/conduits-conduits
22:05:07 <elliott> http://www.yesodweb.com/blog/2012/01/conduits-buffering
22:05:13 <elliott> is the blog post series they were introduced in that just concluded.
22:06:03 -!- NihilistDandy has joined.
22:06:41 <shachaf> elliott: I'm glad to hear that the conduit's are out of the bag.
22:07:16 <elliott> shachaf: conduit's [composition operators].
22:07:24 <shachaf> Oh.
22:07:30 <shachaf> That's what I get for not reading context.
22:07:42 * shachaf should probably just leave IRC.
22:07:46 <shachaf> At this rate.
22:12:11 <oerjan> yeah internet damages your brain, you hear.
22:23:53 <kallisti> elliott: I sure am learning a lot about how to abstract ResourceT to non-IO monads!
22:24:28 <elliott> Sorry, next time I won't link you the material presented introducing an abstraction you find confusing.
22:25:12 <kallisti> elliott: oh no it's useful material I'm just drudging through it waiting for the punchline.
22:25:32 <kallisti> (the probably three or four functions I need)
22:25:49 <elliott> kallisti: If you're writing a network server, you'll probably need more than that.
22:26:06 <kallisti> assuming I have an actual need to scale, yes. a good assumption to make.
22:28:24 <kallisti> psh, you mean resourceT can only have (maxBound :: Int) registered actions!?
22:29:05 <zzo38> kallisti: OK. Yes, it could just be a "prefer" command, so you can connect using telnet or MUD client or whatever, and if a graphical client is used it can be a menu.
22:29:13 <kallisti> zzo38: yep
22:29:27 <kallisti> the actual syntax I'll work out later.
22:29:38 <kallisti> as "prefer" could be many different kinds of preferences.
22:29:45 <kallisti> regarding player color and rule set.
22:29:52 <kallisti> and possibly other unforseen options.
22:30:48 <kallisti> aha, I figured out what my reader data is. :P
22:31:48 -!- _Slereah has quit (Ping timeout: 255 seconds).
22:35:42 -!- _Slereah has joined.
22:36:17 -!- MDude has quit (Ping timeout: 240 seconds).
22:38:33 <zzo38> kallisti: Yes, you can have those kind of option too, I suppose. And then "help prefer" lists the available preferences (a graphical client can simply list all of them on a menu).
22:39:09 <zzo38> Such as, "prefer color black" to set the preference for playing black, and "prefer -color" to unset that preference.
22:41:42 <kallisti> yes something along those lines.
22:43:19 <kallisti> elliott: okay now that I've stubmled through the ResourceT article the actual conduit article itself is significantly less painful.
22:43:35 <zzo38> While "prefer" by itself should probably display the current settings.
22:45:53 <elliott> kallisti: *articles
22:52:29 <kallisti> it appears that $= =$= and =$ have considerable variation in the ways you can equivalently piece sources/conduits/sinks together.
22:53:13 <elliott> It's just (a $= b =$= c =$= d =$ e), isn't it?
22:53:19 <elliott> i.e. you only use ($=) and (=$) at the end-points.
22:53:50 <kallisti> elliott: well, if I'm understanding correctly you could could continue to use them until the midpoints
22:53:57 <elliott> Phantom_Hoover: Is lambda l or h, I forget.
22:54:15 <elliott> kallisti: That's just (f . g . h $ x) vs. (f $ g $ h $ x), isn't it?
22:54:18 <Phantom_Hoover> elliott, l.
22:54:39 <kallisti> elliott: yes.
22:54:43 <elliott> Phantom_Hoover: thx
22:55:22 <kallisti> elliott: it's just a question of how you want to use the abstraction. What you want to be considered a start point, mid point, and end point.
22:56:53 <kallisti> I haven't learned how enumerators work to compare, but the basics of conduits are pretty intuitive.
22:58:51 <elliott> shachaf:
22:58:52 <elliott> The type of function is off, but without seeing it we probably can't tell why. – Xodarap 10 mins ago
22:58:52 <elliott>
22:58:52 <elliott>
22:58:52 <elliott> It doesn't need a type – GoodGuyGreg 4 mins ago
22:59:05 <elliott> IT DOESN'T NEED A TYPE.
22:59:08 <kallisti> lol
22:59:47 <kallisti> "It doesn't need a type" are probably, out of context, words I would never associate with Haskell.
23:01:44 <kallisti> so for example, the function that transforms text input into sybolic "commands" I would probably make a source.
23:02:01 <kallisti> s/function/thing/
23:02:04 <kallisti> (????)
23:02:11 <kallisti> conduit-thingy
23:04:09 <elliott> kallisti: Presumably you'd write a parser first.
23:04:33 <kallisti> I was actually going to define what the commands are first..
23:04:39 <kallisti> and then do the parser afterwards
23:04:42 <kallisti> or well
23:04:44 -!- Patashu has joined.
23:04:45 <kallisti> do both kind of at the same time.
23:04:50 <elliott> I meant before writing a conduit thing.
23:04:53 <kallisti> oh yes.
23:05:20 <kallisti> the first thing is to implement the "pure" chess game, playable by absolutely no one. it just sits there and exists.
23:05:36 <kmc> lots of things in haskell don't have types
23:05:38 <kmc> like types
23:05:39 <kallisti> then I'm going to add all the things that are required for the interface.
23:06:22 <kallisti> well, someone could play it in GHCI by feeding it a list of commands (in the form of an ADT), actually.
23:08:48 -!- FireFly has quit (Excess Flood).
23:09:23 <Phantom_Hoover> Omegle... now lets you log in through Facebook.
23:09:57 <oerjan> types have a type, kind of
23:10:09 <Phantom_Hoover> Not in Haskell, surely.
23:10:35 <oerjan> the whoosh is strong in this one.
23:11:07 <Phantom_Hoover> I'm Vorpalling.
23:11:25 * kallisti Vorpals the Ngevd.
23:12:17 <oerjan> sorry, *with
23:14:34 * oerjan notes that you can say "kind of" or "sort of", but not really "type of"
23:15:38 <oerjan> well not in that idiom.
23:16:36 <elliott> kmc: They don't need types.
23:16:42 <elliott> Only things that need types have them in Haskell.
23:16:45 <kmc> :D
23:16:47 <elliott> So, not functions.
23:19:24 <kallisti> is Data.Conduit correct?
23:19:32 <kallisti> I would think... Control.Conduit is a better name
23:19:37 <kallisti> perhaps.
23:19:50 <elliott> There's no difference.
23:20:14 <kallisti> well, yes. that's the bottom line.
23:20:17 <elliott> Data.List; shouldn't it be Control.List, because its Applicative and Monad instances model nondeterministic computation?
23:20:24 <elliott> Data.Functor but Control.Applicative?
23:20:41 <elliott> Why, shouldn't Control.Applicative be Data.Applicative, considering how many containers are instances of it?
23:20:44 <kmc> such a stupid distinction
23:21:00 <elliott> Why are monads in Control.Monad, but if you just chop off the type parameter it ends up in Data.Monoid?
23:21:31 <kallisti> oh wait I've got the best module name:
23:21:32 <kallisti> Conduit
23:21:43 <kallisti> Monad
23:21:46 <kallisti> Applicative
23:21:53 <elliott> Conduit.Monad.Applicative
23:21:59 <kallisti> yes exactly
23:22:55 <kallisti> I guess it would make sense for Data to contain actual data structures
23:22:59 <kallisti> and related functions
23:23:06 <elliott> kmc: Anyway, we need to sharply distinguish Data and Control to distance ourselves from the Lispers.
23:23:08 <kallisti> with Control containing abstractions over many structures.
23:23:09 <zzo38> The Data/Control module names are not really always sensible
23:23:14 <zzo38> Since in Haskell they are the same thing
23:23:25 <elliott> kallisti: So is a total trie in Data or Control?
23:23:28 <zzo38> (I mean, data structures and control structures are the same thing)
23:23:30 <elliott> After all, it represents a function.
23:23:42 <elliott> But it's pure data, no function arrows or control structures in there.
23:24:02 <kallisti> elliott: I don't know enough about what that is to conclude anything about it.
23:24:55 <kallisti> I mean
23:24:57 <kallisti> I know what a trie is
23:24:59 <kallisti> but not a total trie
23:25:20 <elliott> kallisti: http://conal.net/blog/posts/elegant-memoization-with-functional-memo-tries might help.
23:25:28 <elliott> I simply mean a trie that has all its elements defined.
23:25:37 <elliott> i.e. representing (a -> b) rather than (a -> Maybe b) or similar.
23:25:55 <kallisti> ah
23:26:13 <kallisti> well, can such a trie be used as a control structure?
23:26:41 <kallisti> (I'm not entirely sure what that means)
23:26:49 <elliott> kallisti: Presumably functions call under control in your categorisation scheme, since they're not "actual concrete data structures"(tm).
23:26:51 <elliott> *fall
23:27:01 <elliott> Also lambda is the ultimate control flow and all that.
23:27:29 <elliott> So, since you have ((a -> b) -> Trie a b) and (Trie a b -> (a -> b))...
23:27:32 <kallisti> hmmm, I'm not really sure honestly. Sure I understand the distinction is arbitrary, but also believe it can be made, though it may be an ill-defined distinction.
23:27:40 <elliott> Yet they're pure data trees.
23:27:44 <kallisti> I would say "control structures" in a functional language would include higher-order functions.
23:27:44 <elliott> Concrete and all that.
23:27:54 <zzo38> Is any of the changes made to Haskell to provide built-in natural number types having inhabited natural number types?
23:28:04 * Phantom_Hoover → sleep
23:28:04 -!- Phantom_Hoover has quit (Quit: Leaving).
23:28:23 <elliott> kallisti: It really isn't a meaningful distinction.
23:28:51 * elliott would merge Data and Control and call the result Structure or something like that.
23:28:55 <elliott> Oh, "Form", that's nicest.
23:29:02 <kallisti> I would just remove that level.
23:29:03 <zzo38> There is no difference between data structures and control structures in Haskell (unless they are made strict)
23:29:03 <kallisti> >_>
23:29:11 <elliott> Then move Control.Exception into System.Exception.
23:29:18 <elliott> As well as Control.Concurrent to System.Concurrent.
23:29:32 <elliott> kallisti: That would cause massive top-level pollution.
23:29:45 <kallisti> what nasty things does that entail?
23:30:03 <kallisti> Data and Control are already pretty hugely populated.
23:30:43 <elliott> kallisti: For a start, there's a Data.Data :P
23:30:48 <zzo38> I would put Functor and then Functor.Applicative, Functor.Monad, and Functor.Comonad. That might do.
23:31:00 <elliott> Also Data.Dynamic would become Dynamic, and that's a very overloaded word to occupy.
23:31:06 <zzo38> But put list stuff in Data.List
23:31:15 <elliott> And that's just in base.
23:31:42 <kallisti> s/^(Data|Control)/Stuff/g
23:31:55 <kallisti> s/^(Data|Control)/Computers/g
23:32:06 <kallisti> s/^(Data|Control)/Power!/g
23:32:12 <kallisti> Power.Monad
23:32:16 <kallisti> sounds more exciting doesn't it?
23:32:18 * elliott sincerely likes Form the best.
23:32:35 <kallisti> sounds like something from martial arts...
23:32:41 -!- Phantom_Hoover has joined.
23:32:42 <elliott> Data structures are about form, control structures are about form, abstractions like Functors and Monads are about form.
23:32:46 * kallisti utilizes the monad form to deliver a crushing blow to elliott.
23:32:50 <zzo38> What are they called in mathematics?
23:32:54 <elliott> Something like concurrency or exceptions or IO or whatever isn't really about form.
23:33:03 <kallisti> elliott: help what is "form"
23:33:18 <elliott> kallisti: Buy a dictionary.
23:34:25 * Phantom_Hoover → sleep again
23:34:25 -!- Phantom_Hoover has quit (Client Quit).
23:34:43 <elliott> http://www.reddit.com/r/haskell/comments/og3lr/don_stewart_spokesman_for_senate_minority_leader/
23:34:46 <elliott> GREAT HASKELL CONTENT
23:35:10 <kmc> sigh
23:35:30 <kmc> great comment too
23:36:09 <elliott> : - )
23:36:10 <zzo38> Do you think the try/evaluate stuff is not really ideal? I could try to make a library that makes macros using Template Haskell for catching these kind of pattern errors, which seem more ideal way to me since it does not require any values (including functions) to be not mathematically correct; macros are not values so it works OK
23:36:15 -!- MDude has joined.
23:36:30 -!- MDude has quit (Client Quit).
23:38:29 -!- cswords_ has joined.
23:38:32 <zzo38> :: -- ))
23:38:33 <elliott> mathematically correct, n. something done the way zzo likes it
23:38:42 <zzo38> Ssoorrrryy,, dduupplleexx sswwiittcchh oonn..
23:38:53 <elliott> oops
23:38:57 <zzo38> elliott: That isn't the correct definition.
23:39:02 <oerjan> yyoouu aarree ffoorrggiivveenn
23:40:51 -!- augur_ has joined.
23:41:00 -!- sebbu2 has joined.
23:41:00 -!- sebbu2 has quit (Changing host).
23:41:00 -!- sebbu2 has joined.
23:41:36 <monqy> correct definition would make it an adjective?
23:41:52 <zzo38> monqy: That would be part of it.
23:47:51 -!- tswett_ has changed nick to tswett.
23:48:29 -!- sebbu has quit (*.net *.split).
23:48:30 -!- augur has quit (*.net *.split).
23:48:30 -!- cswords has quit (*.net *.split).
23:49:53 <oerjan> i disagree with monqy's correct
23:50:46 <elliott> kmc: oh god
23:50:58 <elliott> kmc: i just answered two SO questions by the poster of that functional dreamers thing
23:51:04 <elliott> fml
23:51:31 <monqy> functional dreamers thing?
23:53:07 <elliott> monqy: http://www.jadbox.com/2012/01/functional-dreamers/
23:53:25 <monqy> oh that
23:53:29 <monqy> heheheh
23:53:51 * elliott enjoys the use of "conceptualised" re: Conal since it's the closest verb he can think of to "nothingised"
23:54:26 <oerjan> proactivized
23:55:01 <kmc> link elliott?
23:55:46 <zzo38> How often do you find (zip [0..]) a useful function?
23:56:35 <kmc> very
23:57:10 <elliott> kmc: to the questions?
23:57:22 <kmc> yeah
23:57:28 <zzo38> Is there a single name for (zip [0..]) function?
23:57:38 <elliott> http://stackoverflow.com/questions/8858422/does-tryhaskell-org-support-definitions http://stackoverflow.com/questions/8858739/the-difference-between-and-expressions
23:57:39 <elliott> zzo38: zip [0..]
23:58:04 <oerjan> zzo38: there are single-name functions with more characters than that :P
23:58:16 <zzo38> elliott: That is not what I meant, though.
23:58:28 <kmc> i'm fine with calling it «zip [0..]»
23:58:29 <zzo38> oerjan: I just wanted to know if there is any; it is not required
23:58:34 <kmc> one less arbitrary name to memorize
23:58:36 <kmc> but no, I don't know of one
23:58:39 <kmc> python calls that "enumerate"
23:58:43 <kmc> haha"closed as exact duplicate by duri, ehird, Martin Geisler, Tikhon Jelvis, Daniel Pratt 4 secs ago"
23:59:19 <elliott> hilarious
23:59:22 <elliott> (?)
23:59:32 <kmc> :t (?)
23:59:33 <lambdabot> Not in scope: `?'
23:59:56 <elliott> the ideal language is one where you don't need name bindings at all
23:59:59 <elliott> because they'd all be longer than the definition
←2012-01-12 2012-01-13 2012-01-14→ ↑2012 ↑all