←2011-08-13 2011-08-14 2011-08-15→ ↑2011 ↑all
00:01:48 -!- pikhq has joined.
00:02:27 -!- pikhq_ has quit (Ping timeout: 276 seconds).
00:03:12 <oerjan> @undo [x | Just x <- hm]
00:03:12 <lambdabot> concatMap (\ a -> case a of { Just x -> [x]; _ -> []}) hm
00:03:22 <elliott> Lymee: Hey where are our barracks.
00:03:32 <Lymee> nya?
00:04:22 <elliott> Lymee: YOU ARE THE ONLY DF PERSON ONLINE OK
00:04:35 <Lymee> CHECK "R"
00:05:28 <elliott> Lymee: I did
00:05:33 <elliott> I found no barracks :P
00:05:37 <Lymee> Make one.
00:06:05 <elliott> Lymee: We have one.
00:06:08 <elliott> I just can't find it :P
00:06:21 <oerjan> make a barrack, call it obama
00:06:27 <Lymee> Check armor stands and weapon racks.
00:06:33 -!- zzo38 has left.
00:06:51 <elliott> Hmm
00:07:18 <elliott> Why does this guy have a weapon rack in his bedroom
00:07:41 <Lymee> Requirements probs.
00:08:43 <oerjan> elliott: you've found a budding terrorist!
00:10:46 <elliott> Oh fuck you Lymee, you're at happiness 0 nad have mandated the cosntruction of ````certain goods''''
00:10:50 <elliott> You know what it's time for you to do Lymee????
00:10:52 <elliott> It's time for you to DIE.
00:10:55 <Lymee> ;-;
00:10:55 <CakeProphet> what? the download link for Firefox 3.6 gives me version 5...
00:11:12 <elliott> Why'd you want 3.6
00:11:12 <monqy> how's monqy going
00:11:22 <elliott> monqy: Still our good ol' miner
00:11:25 <elliott> \
00:11:29 <monqy> do i have any miner friends
00:11:31 <CakeProphet> elliott: the plugin I need only works with 3.6
00:11:33 <elliott> monqy: A few
00:12:27 <elliott> Dammit PH, where is the execution chamber
00:12:57 <CakeProphet> what? no really this 3.6 download is 5.
00:12:58 <CakeProphet> WHY
00:12:59 <elliott> Lymee: Dear god, your bedroom is insane.
00:13:12 <Lymee> Lymee is insane.
00:13:31 <elliott> Lymee: http://ompldr.org/vOXcwdg
00:13:49 <monqy> what does that mean
00:13:56 <elliott> monqy: what mean
00:14:00 <elliott> monqy: All the floor tiles are engraved
00:14:06 <monqy> oh
00:14:11 <elliott> Basically Lymia is living in a queen's bedroom.
00:14:12 <monqy> what are the what are those taus
00:14:15 <elliott> She's only a fucking county.
00:14:21 <elliott> monqy: Uh, plants or something I think
00:14:31 <elliott> They're not taus
00:14:33 <elliott> I don't think
00:14:34 <Lymee> Plants.
00:14:42 <monqy> well they're somethings and I don't know what they are
00:14:47 <monqy> and they look kind of like taus
00:16:08 <elliott> Did PH build a ton of levers just so that I wouldn't use the execution chamber
00:16:10 <elliott> Sigh
00:18:14 <elliott> monqy: btw you are a girl and also, fifty-seven years old
00:18:49 <monqy> ok
00:19:17 <elliott> Lymee: Do countesses get elected, I suppose not
00:19:20 <elliott> And also I can't replace you
00:19:26 <elliott> So I guess I have to arrange a nice accident
00:19:37 <elliott> You're demanding an adamantine throne
00:19:41 <elliott> I don't like you, Lymee
00:20:43 <monqy> what would happen if execution
00:20:56 <CakeProphet> what... I need 3.6
00:20:59 <CakeProphet> WHAT IS THIS.
00:21:04 <monqy> what is that
00:21:06 <elliott> CakeProphet: just get it from the ftp dude
00:21:09 <elliott> <monqy> what would happen if execution
00:21:12 <elliott> she'd die
00:21:16 <elliott> and maybe tantrum spiral but probably not
00:21:20 <CakeProphet> oh nevermind I figured out the problem.
00:21:21 <monqy> do it do it do it
00:21:27 <CakeProphet> I was running firefox instead of ./firefox. :3
00:22:12 <elliott> smart
00:22:19 <elliott> monqy: i dont know how to work the execution chamber :(
00:22:29 <monqy> :(
00:22:35 <CakeProphet> yep I'm pro like that.
00:23:28 <elliott> Lymee: I want to remove all but my best engraver if I'm trying to give my bedroom a wonderful total engraving, right?
00:28:19 <elliott> thx Lymee
00:40:35 <elliott> Lymee: :(
00:40:52 <Lymee> I guess.
00:41:04 <elliott> I guess I'll let them all do it, since I have an awful lot of wall and floor to do
00:41:52 <elliott> Wait, you can't engrave floor?
00:42:40 <Sgeo_> A place of nostalgia for me is free again
00:42:42 <Sgeo_> <3
00:42:43 <elliott> Hmm, you're meant to be able to...
00:43:01 <elliott> Sgeo_: oh my god stop embarrassing yourself.
00:43:27 <elliott> Lymee: So, um... what does it mean if I try and engrave a floor and the designation just doesn't stick.
00:43:34 -!- Gregor has set topic: FALCON PAUNCH | iridium is too mainstream | http://codu.org/logs/_esoteric/.
00:43:40 <monqy> elliott: jokes on you; sgeo has no shame
00:44:54 <Lymee> elliott, I... don't think that's happened before.
00:44:57 <Lymee> Is it constructed?
00:49:20 <elliott> Yes.
00:57:56 <Lymee> You can't engrave constructed flooring or walls.
01:00:44 <elliott> Lymee: But why/
01:01:00 <elliott> And... can I somehow get natural floor to... grow?
01:01:25 <Lymee> Nope~
01:01:32 -!- Sgeo has joined.
01:01:32 <Lymee> Not unless you want to cast obsidian
01:01:44 -!- Sgeo has quit (Client Quit).
01:02:02 <elliott> Lymee: How
01:02:26 <Lymee> Mix water and lava.
01:03:38 <elliott> Sounds easy :-P
01:04:08 <oerjan> this will clearly end well.
01:07:08 -!- cheater_ has joined.
01:09:11 <elliott> Lymee: Why did nobody tell me :P
01:09:26 <Lymee> Tell you what?
01:09:37 <elliott> That you can't egnave constructed floor
01:09:46 <Lymee> :kyubey: You never asked.
01:10:08 -!- cheater__ has quit (Ping timeout: 250 seconds).
01:10:29 <Gregor> Argh networking argh.
01:10:43 <elliott> Gregor: UMLBox again?
01:10:48 <Gregor> elliott: Naturalismo.
01:11:10 -!- elliott_ has joined.
01:11:15 <elliott_> <elliott> Gregor: UMLBox again?
01:11:19 -!- elliott has quit (Read error: Connection reset by peer).
01:11:20 <Gregor> <Gregor> elliott: Naturalismo.
01:11:26 <oerjan> i'm sure elves should be able to engrave wood *cackles evilly*
01:11:41 <elliott_> oerjan: Too busy killing 'em
01:11:59 <Lymee> Why does DF have no support for cross-species migration?
01:12:00 <elliott_> Gregor: Dude, you really want a generic host<->guest communication mechanism :P
01:12:05 <elliott_> Gregor: It would make your life _so much easier_.
01:12:24 <Gregor> elliott_: DO NOT WANT TO HACK KERNEL :(
01:12:42 <elliott_> Gregor: Wait
01:12:44 <elliott_> Gregor: Why not just use a FIFO
01:12:50 <elliott_> Or unix socket
01:12:50 <elliott_> On the host filesystem
01:12:54 <Gregor> elliott_: FIFOs aren't communicated host->guest
01:12:54 <elliott_> And expose that to the guest
01:12:58 <elliott_> Unix socket?
01:13:04 <Gregor> Nope
01:13:09 <elliott_> That's stupid
01:13:12 <elliott_> What are you meant to do
01:13:17 <Gregor> Cry
01:13:20 <elliott_> No but really
01:13:23 <elliott_> s/ / /
01:15:08 <elliott_> Gregor: Wait
01:15:15 <elliott_> Gregor: You communicate through stdout and stdin, right?
01:15:22 <elliott_> Why not just make another tty for doing communication on
01:16:21 <Gregor> elliott_: Um ... OK, I can do that ...
01:16:51 <elliott_> Gregor: Well, it'd work, wouldn't it?
01:16:55 <Gregor> Yup
01:16:56 <elliott_> And it's a simple bytestream
01:17:03 <elliott_> And you can just tunnel all sockets and the like over that with a simple binary format
01:17:08 <elliott_> Or make one tty per socket, if that's feasible?
01:17:18 <elliott_> That would be simpler, no protocol involved apart from a "lol gimme socket" tty
01:18:57 <Gregor> I think the max # sockets is 20? (10 tty's, 10 ttyS's)
01:19:03 <Gregor> That might be feasible ...
01:19:05 <Gregor> Lesse ...
01:19:13 <elliott_> Gregor: Ehh, just do it over one tty
01:19:17 <elliott_> That's probably less work
01:19:35 <elliott_> I mean, yeah, you need to define a protocol, but it can be a super-trivial one
01:19:47 <pikhq> Only need to mux, really.
01:20:04 <elliott_> Gregor: Note that your "sockets" still involve using a totally different API for any socket-using program :P
01:20:13 <elliott_> So you still need a custom-written HTTP proxy, but that's like fifty lines of Python
01:20:28 <Gregor> Or ... socat :P
01:20:38 <elliott_> Gregor: socat understands your special protocol?
01:20:50 <Gregor> It does if I expose it as a UNIX domain socket on both ends *shrugs*
01:20:53 <elliott_> (i.e. "prefix every packet with the socket ID" :P)
01:21:04 <pikhq> elliott_: Why HTTP?
01:21:06 <elliott_> Gregor: Oh, you mean just have a general socketotrond?
01:21:11 <pikhq> Tunnel OpenVPN over this.
01:21:13 <elliott_> pikhq: That's all HackEgo allows
01:21:17 <Gregor> elliott_: That's what I was thinking.
01:21:21 <pikhq> Laaaame!
01:21:35 <elliott_> Gregor: Still makes opening a socket have a special protocol, unless you override libc :P
01:21:38 <elliott_> But yeah
01:21:44 <elliott_> That's basically what I meant
01:22:32 <elliott_> Gregor: But yeah, you definitely want to do it with one tty, because making ttys on-the-fly and the like sounds even more painful than a little protocol :P
01:22:41 <elliott_> TCP over pty: the best?
01:22:48 <elliott_> Wait
01:22:48 <Gregor> elliott_: Actually that doesn't sound particularly difficult *shrugs*
01:22:49 <elliott_> <Gregor> I think the max # sockets is 20? (10 tty's, 10 ttyS's)
01:22:52 <elliott_> Gregor: You can have arbitrary ptys...
01:22:55 <elliott_> Can't you?
01:22:57 <elliott_> More or less?
01:23:05 <Gregor> elliott_: Those that are communicated host-to-guest; they're not pty's as far as the guest is concerned.
01:23:09 <elliott_> I thought that limitation was Old-Style.
01:23:11 <elliott_> Gregor: Ugh >_>
01:23:37 <elliott_> Gregor: A one-tty solution is more elegant, then, my critical IRC bot application requires twenty-one socket ;-)
01:23:38 <elliott_> s
01:23:44 <elliott_> Also it'd be eighteen
01:23:47 <elliott_> One is stdio
01:23:54 <elliott_> One is the socket-creation-and-closing service
01:24:52 <Gregor> Surely somebody's already solved this problem.
01:24:55 <Gregor> Modulo the UML part.
01:25:06 <Gregor> The "mux a bunch of sockets over a single I/O device" problem.
01:25:06 <elliott_> Gregor: The UML part is what makes it a problem, man :P
01:25:16 <Gregor> I'm not willing to write code :P
01:25:29 <elliott_> Gregor: Dude, you can write a trivial program for this in like ten minutes :P
01:25:35 <elliott_> Oh god, you're going to rope me into this aren't you >_<
01:25:43 <elliott_> REMIND ME NEVER TO GIVE IDEAS
01:25:44 <Gregor> Maaaaaaaaybe.
01:26:38 <elliott_> It's literally just (:open,server,host) --> id|:fail; (:send,id,text) --> bytes|:fail; (:recv,id,bytes) --> buf|:fail
01:26:39 <elliott_> Or whatever :P
01:26:46 <elliott_> Oh, and (:close,id) I guess
01:26:58 <elliott_> Obviously that doesn't cover all of networking ever, but all you need is basic TCP/IP
01:27:49 <Gregor> Yeahyeahyeah, I'mma start working on it now >_<
01:27:56 <elliott_> Gregor: Too late, I opened up a file :P
01:28:02 <Gregor> Yessss, now I don't have to.
01:28:16 <elliott_> Gregor: So I was thinking I'd write it in Haskell instead of Python................
01:28:28 <Gregor> I was thinking I'd write it in C ...
01:28:32 * elliott_ sits in his Passive-Aggressive Programming Warchair.
01:28:47 <elliott_> Gregor: Hmm, what is the actual tty interface you get?
01:28:55 <elliott_> Like, can both the host and client literally just read from stdin/write to stdout?
01:29:24 <Gregor> Well, the guest would be communicating to /dev/ttyS<whatever>, and the host would be using FIFOs.
01:29:47 <elliott_> Yah, but I just mean, how easy is it to plug a simple stdin/stdout program into the host/client end of the deal
01:29:53 <elliott_> Mostly the host I guess, since the client part is easy
01:30:34 <Gregor> On the host you'd have to use FIFO's, stdin/stdout are already taken.
01:30:42 <Gregor> So, y'know, simple :P
01:30:46 <elliott_> Right :P
01:30:50 <elliott_> I've just avoided FIFOs religiously.
01:31:31 <Gregor> You realize that anything you write in Haskell I'll just have to rewrite in C, right? :P
01:31:39 <elliott_> I'm writing it in Python :P
01:32:18 <elliott_> Unless that doesn't meet your LANGUAGE REQUIREMENTS
01:32:28 <elliott_> Depending on Python in the host and guest is not the most strenuous thing :P
01:32:31 <Gregor> The reason I wanted to write it in C is so that it could run on the guest with no requirements whatsoever (even no FS if necessary)
01:32:45 <elliott_> Well, you can statically link the Python interpreter with a script.
01:32:46 <Gregor> Errm, not "no FS", but "host FS not loaded yet"
01:32:52 <elliott_> But I don't know why you'd want to do THAT :P
01:33:05 <elliott_> Gregor: BTW, you know Haskell can be statically linked too? :P
01:33:15 <Gregor> Producing a, what, 15MB binary?
01:33:19 <Gregor> For Hello, world?
01:33:23 <elliott_> Gregor: Nah
01:33:34 * elliott_ measures out of curiosity
01:34:38 <elliott_> -rwxr-xr-x 1 elliott elliott 2.1M 2011-08-14 02:35 hello
01:34:41 <elliott_> Less if it wasn't glibc
01:34:45 <elliott_> Probably less with the LLVM code generator
01:34:51 <elliott_> Oh, that's not stripped
01:34:58 <elliott_> -rwxr-xr-x 1 elliott elliott 1.6M 2011-08-14 02:36 hello
01:35:11 <elliott_> Gregor: It's whole kilobytes bigger than the equivalent C program statically linked with glibc :P
01:35:12 <pikhq> And getting rid of glibc would remove at least a meg of that.
01:35:39 <CakeProphet> elliott_: that's THOUSANDS of bytes!
01:36:07 <elliott_> Gregor: But sure, I am able to write C programs, the question is whether you want it with lots of bugs or not ;D ;D ;D ;DD:D:D:D:D:D:D:D:
01:36:10 <elliott_> Yeah OK fine /me opens host.c.
01:36:19 <Gregor> Python is probably fine :P
01:36:32 <Gregor> (The more I think about "standard use", the more C is fine ... )
01:36:42 <elliott_> Gregor: "Standard use"?
01:36:45 <elliott_> I don't actually know what you mean :P
01:36:52 <Gregor> Common use of umlbox.
01:36:59 <CakeProphet> Emoticon most commonly used by programmers: :P
01:37:03 <elliott_> Gregor: Do you mean to s/C/Python/?
01:37:05 <Gregor> Which would generally include Python on the guest; and if it didn't, you probably don't care about X11 or networking.
01:37:36 <elliott_> Gregor: X11? Whoo boy :P
01:37:48 <Gregor> X11 isn't difficult if you have UNIX sockets *shrugs*
01:38:04 <Gregor> My mind keeps wandering back to X11 even though I care about it roughly none at all :P
01:38:16 <Sgeo_> IRC quirk most common to mostly programmers: !=
01:38:41 <elliott_> def read_string(tty):
01:38:41 <elliott_> bytes = tty.read(1)
01:38:41 <elliott_> return tty.read(bytes)
01:38:44 <elliott_> Gregor: Look at mah ad-hoc format
01:39:00 <Gregor> Really? 255 bytes per packet max?
01:39:05 <elliott_> Gregor: Oh, point >_>
01:39:06 <Gregor> Can't we make it ... 65536?
01:39:10 <elliott_> Yeah aight :P
01:39:16 <elliott_> I was writing cmd_connect
01:39:19 <elliott_> So that hadn't crossed my mind
01:39:50 <CakeProphet> elliott_: the unecessary use of variables is apalling.
01:39:59 <elliott_> ord(bytes[0]) + (ord(bytes[1]) << 8)
01:40:03 <elliott_> LOOK AT MAH LITTLE-ENDIAN NETWORK PROTOCOL
01:40:05 <elliott_> <-- DOESN'T GIVE A FUCK
01:41:06 <Gregor> elliott_: You should also have a socket ID in that ad-hoc format :P
01:41:18 <elliott_> Gregor: Umm, that's just to read a string internally
01:41:21 <elliott_> e.g.
01:41:23 <elliott_> def cmd_connect(tty):
01:41:24 <elliott_> host = read_string(tty)
01:41:24 <elliott_> port = read_string(tty)
01:41:53 <elliott_> c[9][0]abcdefghi[9][0]999999999 would be the thing to send to connect to abcdefghi:999999999
01:42:17 <CakeProphet> sum(map(ord,bytes[:2])) << 8
01:42:25 <elliott_> CakeProphet: That... no.
01:42:44 <CakeProphet> what?
01:42:47 <Gregor> elliott_: ... wha? I get the feeling that we're writing very different things :P
01:42:55 <Gregor> (Or rather, I'm imagining vs you're writing)
01:43:05 <elliott_> Gregor: There needs to be a protocol for the guest to tell the host it wants to make a new socket.
01:43:20 <elliott_> Basically, I'm doing everything over one tty because it's simpler, and you there's four commands: connect, disconnect, send, recv.
01:43:32 <elliott_> Obviously connect has to take two strings, host and port, so I'm just using a simple length-prefixed thing
01:43:35 <Gregor> elliott_: No, that's bad and nasty, it'd require a bunch of security shit to make sure you only did "OK" connections.
01:43:37 <elliott_> Connect will yield a socket ID that the guest can then use.
01:43:52 <elliott_> Gregor: Well, how do you avoid that? You need some sort of explicit checks
01:44:07 <Gregor> elliott_: All I wanted was a UNIX-domain socket multiplexor.
01:44:17 <elliott_> Gregor: That breaks most of HackEgo
01:44:24 <elliott_> Because sockets would have to be known beforehand
01:44:27 <Gregor> elliott_: Not if one of those UNIX domain sockets is an HTTP proxy.
01:44:35 <elliott_> Well, okay
01:44:43 <elliott_> I guess that works :P
01:44:46 <CakeProphet> elliott_: it's more pythonic, bro. :3
01:44:49 <Gregor> I'm trying to punch the smallest possible hole :P
01:44:52 <elliott_> CakeProphet: It _doesn't do the right thing_.
01:45:04 <elliott_> Gregor: Fairy nuff then
01:45:08 <Gregor> elliott_: And if they could be either UNIX domain or TCP, even better >_>
01:45:24 <elliott_> Gregor: Surely there's some program to do UNIX domain → TCP
01:45:25 <elliott_> Erm
01:45:27 <elliott_> And vice-versa
01:45:32 <Gregor> elliott_: Anyway, it'd require both socket IDs and connection IDs, plus length, plus ... now you see why I didn't want to do this :P
01:45:38 <Gregor> elliott_: Yeah, it's called socat :)
01:45:46 <elliott_> Connection IDs? Can't you just enforce that at the guest layer
01:45:55 <pikhq> CakeProphet: Uh, that's (ord(bytes[0]) + ord(bytes[1]) << 8.
01:45:58 <pikhq> CakeProphet: n00b.
01:46:00 <Gregor> elliott_: You can have multiple separate connections to a single UNIX domain socket.
01:46:01 <CakeProphet> yes I see that now.
01:46:09 <elliott_> Gregor: Yeah, but is there any reason to support that?
01:46:27 <Gregor> elliott_: ... yeah, so you can have multiple connections to the HTTP proxy ... for, like, making two requests ...
01:46:32 <elliott_> Well, OK :P
01:46:50 <elliott_> Oh, sweet, Python's API for this seems easy enough
01:46:55 <elliott_> Gregor: OK, well the changes are minor then
01:47:03 <elliott_> Gregor: The "c" command just connects to a Unix domain socket
01:47:06 <elliott_> It should just take the filepath of the socket
01:47:11 <elliott_> And check that it's in its "allowed sockets" list
01:47:14 <elliott_> (host filepath)
01:47:39 <Gregor> elliott_: It would be easier I think for both of us if it just took an index into that list.
01:47:48 <elliott_> That would work too
01:48:19 <Gregor> That way, you just connect to one of them on the guest, the proxy sends a connection for that same ID, and it connects on the host; the guest doesn't even need to know what it was called on the host.
01:48:27 <monqy> elliott_: so i made a guessing game but half of it doesn't work in the general case help
01:48:35 <elliott_> monqy: lol
01:48:49 <monqy> elliott_: it's the tamplete haskell half
01:49:06 -!- zzo38 has joined.
01:49:36 <elliott_> Gregor: Should I bother with buffering or should I just assume that every packet is small enough >_>
01:49:45 <elliott_> Or do Unix sockets not even act the same here
01:49:48 <elliott_> Help I am a citizen of TCP
01:49:55 <elliott_> monqy: Why do you need TH for a guessing game
01:50:05 <Gregor> Donno
01:50:35 <monqy> elliott_: i tried making case-lambda but i don't know how to get the bindings from the pattern to transfer to the expression. luckily, the guessing game doesn' tneed that to work
01:50:40 <pikhq> elliott_: So the guessing game occurs at compile-time, of course.
01:51:27 <monqy> it's an ugly case lambda too because I didn't want to bother with parsing stuff in quasiquoters
01:54:00 <elliott_> Hmm, Python's standard libraries must come with an allocator of some kind
01:54:07 <elliott_> At this point Gregor whacks me for trying to conserve space in the list of connections
01:54:20 <monqy> why are you using python
01:54:29 <elliott_> monqy: Least common denominator
01:54:43 <monqy> hm?
01:54:49 <elliott_> It runs on everything
01:54:52 <elliott_> And isn't C
01:55:06 <monqy> oh
01:56:01 <monqy> what doesn't (implementation of a better language) run on
01:56:15 <monqy> or is python well-suited to your task
01:56:16 <monqy> whatever it is
01:56:30 <CakeProphet> elliott_: an allocator? lol
01:56:32 <PatashuWarg> does java run on everything yet
01:57:11 <elliott_> Gregor: Hmm, so wait, a UNIX domain socket is what it actually operates on too?
01:57:17 <elliott_> As in, the host talks to the guest through a UNIX domain socket
01:57:22 <elliott_> I was assuming a file-like device, which is stupid of me
01:57:42 <elliott_> I have a basic host.py written though
01:58:39 <Gregor> No, the host talks to the guest through a FIFO, and the guest talks to the host through a character device.
01:58:45 <Gregor> Both more file-like than socket-like.
01:59:08 <CakeProphet> elliott_: the only allocators I know of exist in the C API.
02:01:01 <elliott_> Gregor: Right.
02:02:30 <elliott_> Gregor: It's OK if reading or writing to one socket blocks everything until it goes thorugh... right? :P
02:02:53 <CakeProphet> select?
02:02:58 <Gregor> elliott_: I suppose.
02:03:04 <elliott_> CakeProphet: Complicates the internal protocol
02:03:08 <elliott_> Alright, how should I get this WIP .py to you so that you can see the protocol etc.; just sprunge it?
02:03:49 <elliott_> Gregor: http://sprunge.us/QGIP
02:03:59 <CakeProphet> elliott_: international mail.
02:04:13 <CakeProphet> you'll need to print it out and go buy a stamp.
02:04:20 <monqy> # lol I have no idea how to open a FIFO?? is this right?? help
02:04:24 <monqy> best comment best line
02:06:45 <Gregor> elliott_: Dood, just do the protocol on stdin/stdout.
02:06:56 <Gregor> I can open the FIFO with < lol.in > lol.out
02:07:06 <elliott_> Wait why did I even do
02:07:08 <elliott_> def recv_all(n):
02:07:08 <elliott_> bytes = ''
02:07:08 <elliott_> while len(bytes) < n:
02:07:08 <elliott_> bytes += tty.recv(n - len(bytes))
02:07:08 <elliott_> return bytes
02:07:10 <elliott_> the tty is reliable
02:07:11 <elliott_> lol
02:07:14 <elliott_> Gregor: Yeah OK will fix
02:07:22 <CakeProphet> elliott_: now obviously you should make a class on top of having functions. Like all of the standard Python modules.
02:07:40 <CakeProphet> and everyone will just use the functions anyways because they secretly hate OO
02:08:01 <Gregor> BBIAB
02:08:17 <elliott_> Gregor: client.py has to deal with a Unix domain socket which is rather less predictable, right?
02:08:24 <elliott_> BTW, I could extend this to TCP very, very easily, like a few lines
02:12:05 <elliott_> And, heh, my "TCP support" doesn't really maintain one socket it just lets people connect any time they want to it???? yeah
02:12:08 <elliott_> I guess that is okay maybe
02:12:52 <CakeProphet> def recv_all(n): return "".join(tty.recv(n-x) for x in xrange(n))
02:13:06 <elliott_> CakeProphet: How about ... no, it doesn't work that way.
02:13:18 <elliott_> But feel free to continue making incorrect simplifications of my code
02:21:19 <CakeProphet> nah I'm good. However: connections[conn_id] = None
02:21:20 <CakeProphet> why?
02:21:49 <elliott_> so you can't continue to use it
02:21:55 <elliott_> oh wait i should probably close the socket there lol
02:21:59 <elliott_> CakeProphet: also so it can be gc'd
02:22:19 <CakeProphet> to preserve the length of connections so that future conn_ids continue to increment?
02:22:26 <CakeProphet> no I was just wondering why you didn't delete the index instead.
02:22:35 <elliott_> because that would ruin every conn_id greater than that one??
02:22:47 <CakeProphet> right, okay.
02:27:13 <CakeProphet> for some reason having Nones in the list is terrible.
02:27:29 <CakeProphet> but oh well.
02:27:53 <elliott_> that's why I wanted an allocator
02:28:00 <elliott_> except it's just a one-byte allocator so it's really just a freelist
02:28:38 <CakeProphet> a dictionary and a max_conn_id would work, but... too much work really when the current approach works fine.
02:28:54 <elliott_> doesn't need a list
02:28:57 <elliott_> and that wouldn't work either
02:29:01 <elliott_> well
02:29:05 <elliott_> a list would have better memory characteristics
02:29:09 <CakeProphet> right.
02:29:32 <CakeProphet> except it's full of hideous Nones.
02:29:35 <CakeProphet> s/Nones/nuns/
02:30:19 <elliott_> not if you used a freelist.
02:30:26 <elliott_> well, it'd have nones, but they'd get filled instantly
02:30:52 <CakeProphet> ah, recycle the old ids?
02:32:20 <elliott_> yes, that is what a freelist is :P
02:33:40 <CakeProphet> a functional protocol would be interesting..
02:33:44 <CakeProphet> higher-order...commands?
02:38:24 -!- GreaseMonkey has joined.
02:46:45 <elliott_> Someone upgrade GHC for me so I can test this
02:46:48 <elliott_> TIA
02:49:27 <monqy> Transient ischemic attack.
02:50:05 <CakeProphet> terror induced ascension
02:52:26 <CakeProphet> Taxidermic Investigation Agency
02:53:13 <elliott_> thanks in advance
02:53:38 <CakeProphet> that one's too boring..
02:54:25 <CakeProphet> Tubular intermittent acceleration
02:59:17 -!- evincar has joined.
03:02:31 <elliott_> :t break
03:02:32 <lambdabot> forall a. (a -> Bool) -> [a] -> ([a], [a])
03:02:34 <elliott_> :t split
03:02:35 <lambdabot> forall g. (RandomGen g) => g -> (g, g)
03:02:38 <elliott_> please tell me you have data.list.split
03:02:40 <elliott_> eurgh
03:02:53 <elliott_> :t splitOn
03:02:55 <lambdabot> Not in scope: `splitOn'
03:15:30 <elliott_> CakeProphet: btw, it's not actually true that you need unsafeCoerce to do Data.Dynamic
03:15:34 <elliott_> because
03:15:34 <elliott_> cast :: (Typeable a, Typeable b) => a -> Maybe b
03:15:35 <elliott_> exists
03:16:09 <elliott_> data Dynamic = forall a. (Typeable a) => Dynamic a
03:17:44 <oerjan> three guesses what already mentioned function is used to implement cast...
03:19:13 <elliott_> oerjan: Shhhhhhhhhhhhh, obviously it's a primitive.
03:19:20 <elliott_> And all the values are type-tagged at runtime so it's OK.
03:37:35 -!- pikhq has quit (Ping timeout: 252 seconds).
03:37:37 <Sgeo_> http://twitter.com/#!/catnutritionist
03:38:43 -!- pikhq has joined.
03:38:58 <pikhq> Observation: a power supply should not be accessible by foot.
03:39:04 <pikhq> Erm, bleh.
03:39:11 <pikhq> s/supply/strip/
03:43:50 <elliott_> im a power suply
03:49:43 <elliott_> pikhq does not understand suply society
03:55:25 -!- NihilistDandy has joined.
03:59:44 <evincar> I have just come to the conclusion that the IT industry is largely responsible for compensating for the failings of bad developers and user experience designers.
03:59:50 <elliott_> k
04:00:04 <NihilistDandy> evincar: Welcome to reality
04:00:24 <pikhq> I suppose next you'll be saying that the Emperor has no clothes.
04:01:03 <evincar> Naturally. Au naturel-ly. Naturellement.
04:01:33 <evincar> It's just depressingly amusing that such an industry can exist.
04:01:52 <elliott_> Hmm... @'s serialisation really needs work.
04:02:04 <Sgeo_> @ has serialisation?
04:02:07 <Sgeo_> @ has?
04:02:12 <elliott_> Sgeo_: What?
04:02:25 <evincar> Yeah, I thought @ was sort of a hipster thing.
04:02:31 <elliott_> evincar: What?
04:02:32 <Sgeo_> You're making it sound to me like @ exists in some form
04:02:32 <evincar> It doesn't "have" features.
04:02:35 <evincar> Not in the usual sense.
04:02:40 <elliott_> Sgeo_: No I'm not.
04:02:40 <evincar> They're different.
04:02:56 <Sgeo_> elliott_, or that there's a partial spec of serialisation
04:03:00 <elliott_> Sgeo_: I'm just doing this weird thing called "designing something before building it".
04:03:07 <elliott_> The spec exists in my head; it is deficient and vague.
04:03:09 <pikhq> @ has "serialisation" meaningfully distinct from "in memory representation"?
04:03:31 <evincar> pikhq: Well, you've got to make concessions to get the thing to run on existing hardware.
04:03:32 <elliott_> pikhq: Of course it does. You think that in-memory representation will work on an architecture with a different endianness?
04:03:35 <elliott_> Pointer size?
04:03:42 <pikhq> elliott_: Fuck reality.
04:04:05 <elliott_> It is not more pure to tie the system design to various variables of a specific machine when that is unnecessar.
04:04:07 <elliott_> unnecessary.
04:04:22 <pikhq> I still vote to copulate with reality.
04:05:53 <elliott_> pikhq: Anyway, in-memory representation has pointers.
04:06:00 <elliott_> Pointers are machine- and time-specific.
04:06:26 <elliott_> Unless you want it to do a massive lookup EVERY TIME IT WANTS TO DEREFERENCE A POINTER in which case, lol @ you.
04:07:20 <elliott_> pikhq: Come to think of it, in-memory representation includes machine code.
04:07:25 <elliott_> Also not viable.
04:07:59 <evincar> pikhq: Theory copulating with reality is known to produce useful, if imperfect, hybrids.
04:08:04 <NihilistDandy> elliott_: Did you finally get number keys, or are you copy-pasting @?
04:08:20 <elliott_> NihilistDandy: alt-q
04:08:26 <elliott_> q is also my favourite letter, so this makes me happy
04:08:26 <pikhq> I get the strong feeling that either @ is never happening or you're going to sit down to write it one day and the singularity happens the next day because of it. :P
04:08:29 <NihilistDandy> O.o
04:08:30 <elliott_> to clarrify, alt gr + q
04:08:34 <NihilistDandy> Ah
04:08:57 <evincar> pikhq: I'd bet my bottom dollar said day is fueled by meth.
04:08:57 <elliott_> pikhq: the design has been getting more concrete, so...
04:09:33 <pikhq> evincar: Given elliott's sleep habits, I don't think the meth will do anything notable.
04:09:43 <zzo38> I would like to see the design of @
04:09:50 <elliott_> zzo38: now, you mean?
04:09:56 <zzo38> No! I mean later.
04:09:59 <elliott_> oh good :D
04:10:33 <elliott_> the process of viewing the design of @ involves me remembering it and rewriting a quarter of it in the process while typing it out into irc
04:10:49 <elliott_> design documents are for squares and other rectangular shapes
04:11:02 <zzo38> You should make a proper design document.
04:11:30 <elliott_> but it keeps changing :(
04:12:25 <zzo38> What programming language would you use? LLVM?
04:12:52 <elliott_> you mean the top level that day-to-day things are actually written in? or something lower
04:13:04 <zzo38> I mean the system itself.
04:13:31 <elliott_> "the system" encompasses every single piece of code running on it :)
04:13:44 <elliott_> there's not really any one part you could call the kernel; it'd either be too small, or too big and fluid
04:13:57 <elliott_> unless you consider a scheduler and maybe an allocator of some sort a kernel
04:14:08 <evincar> I imagine there would be some funny business with assembly and C to get things up and running, at which point you can use whatever you like.
04:14:16 <zzo38> What would those parts be written in though?
04:14:17 <evincar> That is, whatever you're prepared to provide runtime support for.
04:14:31 <elliott_> evincar: No C. Ever.
04:14:52 <evincar> elliott_: Anything I don't have to write by hand is time saved. *shrug*
04:14:54 <elliott_> zzo38: To start with? Assembly. There's no other choice, really; it is the absolute lowest layer of the system.
04:15:04 <pikhq> evincar: C running on bare hardware *seems* like it'd be pretty much incompatible with everything else @ is.
04:15:09 <elliott_> zzo38: Once @ is fully bootstrapped, it'll just be rewritten in an @ assembler.
04:15:27 <elliott_> evincar: C has the wrong model. It cannot save me time because all its assumptions are wrong in the face of @.
04:15:45 <zzo38> Is it intended to run on many computers?
04:15:59 <zzo38> Or just one?
04:16:19 <pikhq> elliott_: I'm pretty sure there's a name for "a scheduler and maybe an allocator of some sort".
04:16:22 <pikhq> Exokernel.
04:16:39 <elliott_> zzo38: The basic model is such that @ would be more portable than typical operating systems; for instance, transferring binaries would be a rare operation, because of the security requirements (you'd basically either have to say "yes, I really want to do this risky thing" or provide a proof of the binary's safety, which would be quite thoroughly difficult).
04:17:11 <elliott_> zzo38: I am only planning to implement it for x86-64 computers to start with, but hopefully the non-portable parts could be kept to a minimum.
04:17:28 <zzo38> OK, that makes sense. But if you write the system in assembly language then you need to write it in the assembly languages for many computers!
04:17:28 <elliott_> For instance, like NetBSD, there is no reason that any driver would have to be CPU or bus-specific.
04:17:43 <evincar> elliott_: Are there applications in a traditional sense? Barring any details of persistent state, namelessness and the other peculiarities of @.
04:17:52 <elliott_> zzo38: Well, it's impossible to avoid writing any assembly at all without relying on someone else's assembly (e.g. GRUB).
04:18:08 <elliott_> But the scheduler code should be rather small, and the remaining assembly should merely involve boot-up and some other miscellaneous tasks.
04:18:41 <zzo38> Well, yes. You would still need to write things such as the MBR code in assembly. The other stuff could be written in LLVM so that much of it can easily be ported to other computers.
04:18:58 <elliott_> evincar: No. The definition of application is basically "the smallest non-composable unit of software"; information can't pass application walls without specific code to make it happen. That's pretty much antithetical to what @ is.
04:19:40 <zzo38> Do all programs need to be compiled and put everything together to make up the entire operating system?
04:20:36 <evincar> elliott_: How do I run existing software on it?
04:21:08 <elliott_> zzo38: Because of the safety, portability and openness reasons I mentioned, everything is stored as source code (well, ASTs; there's no real reason to have a textual form of source code when it's not explicitly requested). A major goal for the compiler is to be fast enough that code can be compiled "on-the-fly" without noticeable delays. (The Oberon system achieves this.)
04:21:22 <elliott_> So basically, things will be compiled as they're loaded, or speculatively, if the system thinks some code is about to be used.
04:21:29 <elliott_> evincar: Like, Windows or Unix software?
04:21:38 <Gregor> elliott_: http://web.purplefrog.com/~thoth/netpipes/encapsulate.html (I have no idea wtf this does, but it has pretty keywords)
04:21:38 <zzo38> OK.
04:21:55 <elliott_> Gregor: Did you see what I said? It does TCP now.
04:21:58 * Sgeo_ still wants to try Oberon
04:21:59 <evincar> Sure. Say I want to run Blender, make a 3D model, and if not actually save it, at least make sure that it continues to exist.
04:22:04 <elliott_> Sgeo_: Download the floppy, have fun
04:22:14 <elliott_> evincar: "Say I want to run Blender" <-- this is the first hurdle.
04:22:24 <zzo38> If you want to run existing software, could you use a C compiler or Pascal compiler or LLVM compiler or Haskell compiler or so on that is meant for this system?
04:22:44 <elliott_> evincar: You'll run it under a compatibility layer, which could be as coarsely-grained as a full qemu with an Ubuntu installation, to something that is just an implementation of C and the like, plus a shell, and the various POSIX functions.
04:23:01 <elliott_> evincar: The finer-grained the layer, the more pleasant an experience you're likely to have, but the more work someone else has had to do to make it happen.
04:23:05 <elliott_> zzo38: Yes.
04:23:10 <zzo38> In the case of Haskell, would you use a different type of main than other computers, but have a separate function to convert in case you need to run Haskell program meant for other systems?
04:23:31 <elliott_> Yes, that would be a reasonable approach. I'm not even sure you'd need a main value at all.
04:23:51 <zzo38> OK.
04:24:05 <Gregor> elliott_: Unlike you, I don't read backlog :P
04:24:15 <elliott_> Gregor: I pinged you
04:24:34 <elliott_> Gregor: tl;dr I asked a question about client.py, and then said that I generalised server.py to do TCP, but it might not behave correctly
04:24:45 <Gregor> Ah.
04:24:47 <elliott_> 02:08:17: <elliott_> Gregor: client.py has to deal with a Unix domain socket which is rather less predictable, right?
04:24:47 <elliott_> 02:12:05: <elliott_> And, heh, my "TCP support" doesn't really maintain one socket it just lets people connect any time they want to it???? yeah
04:24:48 <elliott_> 02:12:08: <elliott_> I guess that is okay maybe
04:24:49 <elliott_> Gregor: Thar you go
04:25:15 <elliott_> It basically treats (host,port) ~ path to domain socket.
04:26:09 <Gregor> Hm hm hm.
04:26:18 <Gregor> Yeah, that seems about right.
04:26:23 <Gregor> In fact, yeah, that's exactly right.
04:26:26 <elliott_> I mean, otherwise you'd have to enforce a one-person-per-TCP-socket thing.
04:26:28 <elliott_> Which is just stupid, so yeah.
04:27:24 <Gregor> Upon further investigation, I believe that encapsulate does in fact do everything I want, /except/ for actually creating/opening the sockets, which is kind of obnoxious :P
04:27:34 <Gregor> So, I continue to eagerly await your solution.
04:27:48 <elliott_> Gregor: Well, I just need refreshing on how client.py talks :P
04:27:51 <elliott_> server.py is through stdio
04:28:04 <elliott_> If client.py could be the same that would be nice
04:28:05 <Gregor> Also stdio.
04:28:08 <elliott_> e.g. via socat/nc
04:28:20 <elliott_> Aight then
04:28:21 <Gregor> It's via a tty device, but that's ultimately just stdio.
04:28:29 <elliott_> The tty device is owned by root, right?
04:28:34 <elliott_> So that nobody else can fuck with it :P
04:28:36 <Gregor> Naturalismo.
04:29:04 <elliott_> Gregor: How should it serve the creation of new sockets? Local TCP server?
04:29:46 <Gregor> Hmmmmm
04:29:56 <elliott_> It could use a FIFO too, I guess
04:30:00 <elliott_> Except that has awkwardness about it
04:30:02 <Gregor> Actually, that makes me think ... why do the server and client even need to be different?
04:30:19 <elliott_> Because... the server is on one end of the protocol and the client another? :P
04:30:31 <elliott_> Why does my toaster and my bread have to be different?
04:30:34 <elliott_> [asterisk]do
04:31:08 <Gregor> The server is accepting connections and the client is making connections, but ultimately those are just requests made through the multiplexing connection ...
04:31:23 <elliott_> Yes, but it's implemented with a custom protocol on top of Unix
04:31:51 <Gregor> Hm ... I feel like it would simplify things if they were the same, but ANYWAY, yeah, a local TCP server should be fine.
04:32:13 <elliott_> But the actual things it offers are solely Unix domain sockets, not TCP, yes?
04:32:18 <elliott_> Hmm, TCP might actually be more convenient
04:32:21 <elliott_> I mean, it's one less layer
04:32:59 <elliott_> I guess that makes X a pain, though
04:33:05 <elliott_> Whereas it's easy to turn a domain socket into TCP
04:33:08 <elliott_> Even though that's yet another program
04:33:17 <Gregor> Well, so long as you're implementing both on the host, wouldn't it make sense to implement both on the guest? So TCP can connect to TCP and UNIX to UNIX?
04:33:19 <elliott_> I don't really want to write code that serves domain sockets and TCP generically as either a domain socket or TCP
04:33:36 <elliott_> Gregor: The host doesn't distinguish, so you could even convert >_>
04:33:43 <elliott_> I guess I can do it, it's just that servers are always more of a pain than clients
04:33:48 <elliott_> The guest is a server, the host is a client :P
04:33:49 <elliott_> Sort of :P
04:34:07 <Gregor> But aren't servers for TCP and Unix painful in identical ways after the initial socket() call?
04:34:27 <elliott_> Well, yes :P
04:34:33 <elliott_> It's just STRICTLY MORE lines of server code :P
04:34:37 <elliott_> OK here goes.
04:35:12 <elliott_> Gregor: Hmm, do Unix sockets have a specific way of indicating "disconnection"?
04:35:14 <elliott_> I guess they just act like EOF
04:35:26 <Gregor> Yeah, which is the same as TCP.
04:35:41 <Gregor> Unless you're talking about the protocol, not the API?
04:35:47 <elliott_> API, yeah.
04:36:21 <Gregor> After socket() and bind(), the API is supposed to be the same ... that's, like, the whole point of all the complicated mess that is BSD sockets :P
04:36:31 <Gregor> Though Idonno if that translates into Python (I'd hope so)
04:36:39 <elliott_> Python's socket API is completely low-level.
04:36:47 <elliott_> It hurts only slightly less than BSD sockets because there's no fucking casting and htons and shit.
04:36:52 <elliott_> GOD I hate BSD sockets.
04:38:33 <Gregor> BSD sockets are yummy
04:39:11 <elliott_> I'm trying to figure out what you'd call the order-and-then-later-on-receive-vaguely-edible-junk place in a fast food store, because it's the perfect name for the TCP server socket this thing creates :P
04:39:19 <elliott_> I hope in the future people curse me for creating such a shitty protocol.
04:39:39 <elliott_> Of course, it's called the "wtf".
04:39:52 <pikhq> `addquote <elliott_> I hope in the future people curse me for creating such a shitty protocol.
04:39:56 <HackEgo> 592) <elliott_> I hope in the future people curse me for creating such a shitty protocol.
04:39:59 <elliott_> Gregor: What's a TCP port
04:40:02 <elliott_> A nice low one
04:40:20 <Gregor> elliott_: How about ... whichever port I ask for at runtime? :P
04:40:25 <pikhq> elliott_: Y'know, anyone can register a TCP port with IANA.
04:40:34 <elliott_> Gregor: Butbutbut... # 4/tcp Unassigned
04:40:45 <elliott_> tcpmux 1/tcp TCP Port Service Multiplexer
04:40:47 <elliott_> P E R F E C T
04:40:52 <Gregor> wtf
04:40:55 <elliott_> OK yeah fine :P
04:41:01 <elliott_> Gregor: what
04:41:16 <Gregor> elliott_: I don't understand why you would want a pre-specified TCP port .... this is the listening port that corresponds to one outgoing connection on the server, right?
04:41:36 <elliott_> This is the port that everything on the guest connects to when it wants to create a scoket.
04:41:38 <elliott_> socket.
04:41:45 <oerjan> !sanetemp 104
04:41:46 <EgoBot> 313.1
04:41:58 <Gregor> elliott_: ... huh?
04:42:11 <Gregor> elliott_: Why is there such a port? The available sockets should be predetermined.
04:42:21 <elliott_> Gregor: Ohhh, right
04:42:29 <elliott_> Gregor: I forgot that you're a crazy static guy :P
04:42:38 <Gregor> Security, dood :P
04:42:51 <Gregor> Make a very airtight box, then poke the smallest possible holes in it.
04:43:06 <elliott_> This is sooooooooo inelegant :P
04:43:13 <Gregor> That's why I wanted the connection requests to be by index instead of name too ...
04:43:21 <oerjan> *sigh*
04:43:25 <elliott_> oerjan: ?
04:43:26 <Gregor> Lemme fully articulate my thoughts:
04:43:33 <elliott_> Gregor: I do get it :P
04:43:35 <elliott_> I just lapsed thought
04:43:41 <Gregor> Okidoke
04:43:53 <oerjan> elliott_: someone's being funny with !sanetemp
04:43:58 <oerjan> !show sanetemp
04:43:58 <EgoBot> sh dc -e "1k?459.67+5*9/p"
04:44:01 <elliott_> oerjan: wat?
04:44:17 <elliott_> if ':' in arg:
04:44:18 <elliott_> start('tcp', n)
04:44:18 <elliott_> else:
04:44:18 <elliott_> start('unix', n)
04:44:24 <elliott_> I Can't Believe They're Not Interned Symbols
04:44:43 <oerjan> !sanetemp 104
04:44:43 <EgoBot> 313.1
04:44:52 <oerjan> ^ not particularly sane
04:44:54 <elliott_> Gregor: Hmm, I should probably specify the target paths and ports, huh >_>
04:45:15 <oerjan> > 313.1 - 273.15
04:45:16 <lambdabot> 39.950000000000045
04:45:18 <elliott_> Gregor: So the specification should look like "host:port" or "/foo/bar" for host.py, and "host:port:guestport" or "/foo/bar:/guestpath" for guest.py
04:45:53 <Gregor> elliott_: I don't see why the guest even needs to know what the host's ports are. If they're just by-index, then they just need to be in the same order.
04:46:00 <Gregor> So it'd be guest.py :guestport /guestpath
04:46:16 <elliott_> Gregor: Needs to know whether it's TCP or Unix, but yeah, I was just using the same format before I realised that I need to specify guest port or path :P
04:46:16 <elliott_> So yeah.
04:48:32 * elliott_ looks at Python's select binding
04:48:38 <elliott_> Oh thank god, it's non-terrifying enough to use.
04:49:03 <elliott_> Hmm
04:49:08 <elliott_> How do you accept() from multiple sockets at a time?
04:49:30 <Gregor> ... you accept from one at a time ...
04:49:45 <elliott_> Gregor: But what if someone connects to B while you're sitting around waiting for A?
04:50:07 <elliott_> I'm trying to avoid threads :P
04:50:20 <Gregor> What IF? The connection to B in no way hinders your A ... accept() returns a socket, you keep right on select()ing over it.
04:50:31 <elliott_> Yeeeeeees
04:50:33 <elliott_> But accept() blocks
04:50:41 <elliott_> You have two server sockets A and B with no connections.
04:50:46 <elliott_> You accept() on A.
04:50:46 <elliott_> Oh wait
04:50:50 <elliott_> listen() is the one that blocks lol
04:50:52 <Gregor> Your listen()ing socket will only barf at select() if there's a connection waiting.
04:50:55 <elliott_> s/accept/listen/ in everything I said above
04:51:03 <Gregor> (accept() does block if you didn't wait for listen() :P )
04:51:22 <elliott_> Gregor: Oh, hmm
04:51:28 <elliott_> I've only used select on already-connected sockets before >_>
04:51:34 <elliott_> So what, I just .listen() it and then select() on it in the ... rlist?
04:51:39 <Gregor> Yup
04:51:47 <Gregor> If you get a poing from it, accept()
04:51:50 <elliott_> Why read and not write, sooo arbitrary :-P
04:52:11 * elliott_ gets the genius idea of having a hash table of "what to do when select poings" indexed by socket.
04:52:14 <elliott_> SUCH A GENIUS
04:52:34 <elliott_> (Because I have both server sockets and connection sockets >_>)
04:55:05 <zzo38> Is an IO monad inside of Template Haskell allowed to have its own command-line parameters?
04:56:03 <elliott_> zzo38: I don't think you're guaranteed as to the behaviour of that at all; as in, the arguments could be anything
04:56:10 <elliott_> Gregor: OK, this is going fairly non-terribly :P
04:56:33 <zzo38> OK.
04:57:00 <elliott_> Gregor: Hmm, er
04:57:14 <elliott_> Gregor: When I'm select()ing, if the clients on the guest start recv()ing from one of my shim sockets,
04:57:25 <elliott_> That'll be reflected only if they're in the "ready to write" fds list of the select() call, right?
04:57:28 <elliott_> So
04:57:29 <elliott_> ready, _, _ = select.select(sockets.keys(), [], [])
04:57:30 <elliott_> is wrong
04:57:45 <elliott_> Yeah, it is
04:57:46 <elliott_> OK
04:58:49 <Gregor> Why even ask me if you're just going to answer your own questions :P
04:59:05 <elliott_> Gregor: Rubber duck :P
05:03:05 <elliott_> Hmm, wait
05:03:11 <elliott_> Never mind
05:06:54 <elliott_> Gregor: OK, I've written client.py. It might even have no parse errors.
05:07:05 <Gregor> No parse errors = works
05:07:10 * elliott_ renames it to guest.py for goodness.
05:07:13 <elliott_> Gregor: Welp, it runs and blocks correctly
05:07:18 <elliott_> Gregor: You wanna try and test this? :-P
05:07:30 <Gregor> Sure.
05:07:43 <Gregor> shar *.py | sprunge
05:07:44 <Gregor> :P
05:07:56 <elliott_> host.py: http://sprunge.us/QeMO; usage: python host.py host:port /path ...
05:08:08 <elliott_> guest.py: http://sprunge.us/TfUj; usage: python guest.py :guestport /guestpath ...
05:08:39 <elliott_> Gregor: Note that any errors during read or write result in guest.py basically just disconnecting the client socket :P
05:08:58 <elliott_> Gregor: Because there's no way to make the client get "the same error" without, like, trying to do the same thing that the socket on the other end did.
05:09:07 <elliott_> Which is left as an exercise to the reader.
05:09:24 <Gregor> That's fine *shrugs*
05:09:40 <elliott_> If these work I will be incredibly surprised :P
05:09:41 -!- olsner has quit (Ping timeout: 260 seconds).
05:10:22 <Gregor> TypeError: getsockaddrarg: AF_INET address must be tuple, not int
05:10:38 <elliott_> Oh
05:10:39 <elliott_> Duh
05:10:59 <elliott_> Gregor: Can I have one two seven point oh point oh point one
05:10:59 <elliott_> thx
05:11:18 <elliott_> I should never get my keyboard fixed, I am so hardcore like this
05:11:38 <Gregor> 127.0.0.1
05:12:01 <elliott_> Gregor: guest.py: http://sprunge.us/EPGQ
05:12:13 <NihilistDandy> eight six seven five three oh nine
05:12:39 <NihilistDandy> "There is only one thing which is more unreasonable than the unreasonable effectiveness of mathematics in physics, and this is the unreasonable ineffectiveness of mathematics in biology."
05:14:13 <Gregor> What da heww?
05:14:34 <elliott_> Gregor: What
05:14:36 <Gregor> elliott_: This is perhaps the craziest behavior I've ever seen, anywhere.
05:14:44 <elliott_> Gregor: Oooh
05:14:45 <elliott_> Tell me :D
05:14:50 <NihilistDandy> Is it drawing penises all over the screen?
05:15:00 <elliott_> NihilistDandy: That's a design feature
05:15:22 <Gregor> elliott_: It's ... like it's periodically running xwininfo ...
05:15:23 <elliott_> Gregor: Stop trying to debug my code it's impossible.
05:15:38 <elliott_> Gregor: Um
05:15:40 <elliott_> Gregor: What
05:15:43 <pikhq> NihilistDandy: Praise be to our improbably logical universe!
05:15:46 <elliott_> Gregor: Like what sockets are you using to test
05:15:56 <elliott_> Gregor: Please tell me they're X-related
05:15:58 <Gregor> elliott_: And then it's writing two postscript files, "socket" and "sys" to pwd.
05:16:05 <Gregor> elliott_: Nope, localhost:80 and :8080
05:16:11 <elliott_> ... X-D
05:16:16 <elliott_> Gregor: Which postscript files?
05:16:19 <NihilistDandy> pikhq: Al-jebr be praised!
05:16:28 <Gregor> WTF, they're screenshots
05:16:31 <elliott_> X-DDD
05:16:38 <elliott_> Gregor: I think it's developed sapience and it's attempting to communicate by gluing random services together
05:16:39 <Gregor> This is like fifty levels of not possible.
05:16:55 <Gregor> OHWAIT
05:16:58 <elliott_> When it seems to run xwininfo, try ps
05:16:58 <elliott_> :P
05:17:01 <NihilistDandy> I have to try this shit out
05:17:13 <pikhq> NihilistDandy: In the name of Al-jeber, CALCVLVS, and the scientific method, amen.
05:17:18 <NihilistDandy> Sounds like acid for computers
05:17:25 <Gregor> elliott_: Hyuk, I had put a #! line on my version, then overwrote it with your #!less one.
05:17:27 <elliott_> Gregor: What is it doing because I don't WANT to fix it
05:17:34 <elliott_> Gregor: How... how does that explain anything
05:17:42 <elliott_> Oh
05:17:44 <elliott_> import is a shell command
05:17:45 <Gregor> Apparently "import" is a program that takes a screenshot ... for some reason.
05:17:47 <NihilistDandy> pikhq: Also, fuck biologists. Amen.
05:17:51 <elliott_> Gregor: ImageMagick
05:18:05 <pikhq> NihilistDandy: With pleasure.
05:18:08 <elliott_> Gregor: I just want you to know that this is the best bug EVER :P
05:18:08 <pikhq> :P
05:18:13 <Gregor> elliott_: http://sprunge.us/KRCC
05:18:34 <elliott_> def read_short():
05:18:35 <elliott_> bytes = sys.stdin.read(2)
05:18:35 <elliott_> return ord(bytes[0]) + (ord(bytes[1]) << 8)
05:18:39 <elliott_> Gregor: Did you EOF it or something
05:18:59 <elliott_> socket_index = read_string()
05:18:59 <elliott_> Herp derp
05:19:03 <elliott_> Gregor: Change string to short on that line
05:19:40 <Gregor> http://sprunge.us/ObCG
05:19:59 <elliott_> Hmm
05:20:20 <Gregor> *confused*
05:20:21 <elliott_> >>> (65535 & 256)
05:20:21 <elliott_> 256
05:20:22 <elliott_> Oh durr
05:20:29 <elliott_> Gregor: s/256/255/
05:20:32 <elliott_> As for the other bug... hmm
05:20:38 <elliott_> Ohh hmm
05:20:40 <elliott_> Hmm
05:20:45 <elliott_> Gregor: Can you print sockets.keys() just above that?
05:21:33 <Gregor> Sure
05:21:52 -!- copumpkin has quit (Quit: Computer has gone to sleep.).
05:22:11 <Gregor> Incidentally, I find the fact that there's no select anywhere in host.py highly disturbing.
05:22:31 <elliott_> Gregor: Why would there be
05:22:35 <elliott_> It only recvs or sends when asked to
05:22:41 -!- olsner has joined.
05:23:12 <Gregor> elliott_: [<socket._socketobject object at 0x7ff8e1efaad0>]
05:23:28 <Gregor> elliott_: Yeah, but it needs to receive and send simultaneously ...
05:23:39 <elliott_> Gregor: Uhh, it does?
05:23:48 <elliott_> <Gregor> elliott_: [<socket._socketobject object at 0x7ff8e1efaad0>]
05:23:48 <Gregor> OHHHH, I didn't understand how it worked at all :P
05:23:50 <elliott_> OK, wtf
05:23:56 <elliott_> print sockets.keys()[0].fileno()?
05:24:05 <elliott_> Gregor: Yeah it's literally a syscall servicer :P
05:24:08 <Gregor> The guest actually proxies the REQUESTS, not just the DATA. Now I gets it.
05:24:15 <elliott_> Hmm, how else would it work
05:24:38 <Gregor> With buffering, which would be terrible :P
05:24:38 <elliott_> Just out of curiosity
05:25:09 <Gregor> (You could just pull in anything ready to read, buffer it up for writing, and write whenever possible)
05:25:19 <elliott_> Right
05:25:23 <elliott_> Moar code :P
05:25:27 <elliott_> But yeah
05:25:27 <elliott_> <elliott_> print sockets.keys()[0].fileno()?
05:25:32 <oerjan> http://www.smbc-comics.com/index.php?db=comics&id=2325#comic somehow resonates with me
05:25:43 * oerjan whistles innocently
05:25:48 <Gregor> elliott_: 3 :P
05:25:52 <elliott_> Gregor: wtf.
05:25:58 <elliott_> oerjan: ps mouse over the red circle
05:26:12 <Gregor> elliott_: Why wtf? That's a fileno
05:26:15 <elliott_> oerjan: also oblig.: http://esolangs.org/wiki/User:Chris_Pressey#Laws_of_Form
05:26:15 <elliott_> Gregor: Yep
05:26:19 <elliott_> Gregor: read_ready, write_ready, _ = select.select(sockets.keys(), sockets.keys(), [])
05:26:19 <elliott_> TypeError: argument must be an int, or have a fileno() method.
05:26:26 <elliott_> This is a straightforward interface to the Unix select() system call. The first three arguments are sequences of ‘waitable objects’: either integers representing file descriptors or objects with a parameterless method named fileno() returning such an integer:
05:26:29 <Gregor> Oh
05:26:32 <elliott_> So what on earth is wrong :P
05:26:45 <elliott_> It's a sequence, the sequence contains one object, said object has a fileno method returning an integer
05:27:28 <elliott_> Hmmmmmmmm
05:27:33 <Gregor> Ohohoh
05:27:34 <Gregor> [<socket._socketobject object at 0x7f4546883ad0>, (<socket._socketobject object at 0x7f4546883b40>, ('127.0.0.1', 36796))]
05:27:36 <Gregor> It grew :P
05:27:53 <Gregor> accept(), presumably, gave a tuple
05:28:15 <elliott_> Gregor: Oh
05:28:18 <elliott_> Um
05:28:32 <elliott_> sockets[client] = (lambda: got_data(conn_id, client), lambda: want_data(conn_id, client))
05:28:36 <elliott_> client is definitely a socket object...
05:28:38 <Gregor> client, _ = sock.accept()
05:28:40 <elliott_> sockets[sock] = (lambda: handle_connection(proto, n, sock), lambda: None)
05:28:40 <elliott_> sock too
05:28:46 <elliott_> Gregor: Yeah...
05:28:50 <elliott_> Is that the wrong way around?
05:28:56 <Gregor> You didn't have that before.
05:29:08 <elliott_> Oh
05:29:08 <Gregor> It was just client = sock.accept()
05:29:09 <elliott_> Duh :P
05:29:16 <elliott_> Does it work NOW? :P
05:29:33 <oerjan> elliott_: damn you now i have to check all the other red circles
05:29:35 <Gregor> sys.stdout.write(chr(n & 256) + chr(n >> 8)) # really? n & 256? You suck at bits
05:29:47 <Gregor> ValueError: chr() arg not in range(256)
05:29:58 <zzo38> I think a problem of the Constantinople esolang is the "replace" and "nand" taking two arguments. You could fix it by requiring the word "with" between the arguments, which also means you don't need the parentheses anymore.
05:30:02 <elliott_> Gregor: Dude
05:30:04 <elliott_> I told you to fix that
05:30:06 <elliott_> Earlier above
05:30:12 <elliott_> Gregor: It's just in two files because lazy >_>
05:30:42 <elliott_> If it works, you can send me the modified version and I'll factor them out into common.py
05:30:46 <Gregor> Whah? I don't see that fix request ...
05:30:54 <elliott_> <Gregor> http://sprunge.us/ObCG
05:30:54 <elliott_> <elliott_> Hmm
05:30:54 <elliott_> <Gregor> *confused*
05:30:54 <elliott_> <elliott_> >>> (65535 & 256)
05:30:54 <elliott_> <elliott_> 256
05:30:56 <elliott_> <elliott_> Oh durr
05:30:58 <elliott_> <elliott_> Gregor: s/256/255/
05:31:33 <Gregor> OK, now rather than crashing, it just doesn't work.
05:31:40 <elliott_> Yay
05:31:57 <elliott_> So it just...
05:32:04 <elliott_> Does nothing?
05:32:05 <Gregor> Connection just hangs.
05:32:10 <elliott_> Geh >_<
05:32:15 <elliott_> It could be like one of a million things :P
05:32:30 <elliott_> Hmm
05:32:32 <elliott_> Gregor: Ctrl+C
05:32:36 <elliott_> It'll tell me what it's hanged on ;-)
05:34:59 -!- Nisstyre has joined.
05:35:21 <Gregor> elliott_: http://sprunge.us/CNOC
05:35:52 <elliott_> Hmm, oh dear
05:36:14 <elliott_> Either the guest and the host have a different idea of the protocol, or (I think this) the host was blocked reading from its connection?
05:36:29 <elliott_> Try it so that the socket the host is given gets written to
05:36:29 <elliott_> As in
05:36:30 <elliott_> Umm
05:36:32 <elliott_> This is so ambiguous
05:36:34 <Gregor> elliott_: Thought: If the guest select()s over its sockets, it will never recv.
05:36:36 <elliott_> Gregor: Make the host's recv call return
05:36:40 <elliott_> Ugh
05:36:43 <elliott_> You're right
05:36:50 <Gregor> I think the buffering strategy is strictly necessary >_>
05:36:55 <elliott_> Gregor: Well, there is one other strategy
05:37:01 <elliott_> Gregor: Threads in guest.py
05:37:19 <Gregor> That too.
05:37:25 <elliott_> Gregor: That's probably worse though
05:37:32 <Gregor> s/too/alternatively/
05:37:38 <Gregor> Idonno, they're both pretty awful.
05:37:50 <elliott_> Anyway, I'm not sure what this implies. The host would send the data to the guest as soon as it gets read?
05:38:01 <elliott_> Right now, the server only ever responds to queries, which makes things so much simpler.
05:38:31 <elliott_> The thread solution would just involve: one, threads; and two, a mutex of some kind so that writes don't overlap.
05:38:32 <Gregor> This is sort of why I thought they should be the same; they both need to transfer data across the muxing connection as soon as possible for the other end to react properly.
05:39:00 <Gregor> "They" = host and guest
05:39:09 <elliott_> 9-D
05:39:14 <elliott_> So what was that thing that does everything but opening the sockets
05:39:27 -!- evincar has quit (Quit: leaving).
05:39:27 <zzo38> Can we have: program is nothing or "replace" argument "with" argument program or "repeat" argument program "end" program or "in" argument program or "out" argument program; and argument is nothing or "head" argument or "tail" argument or "nand" argument "with" argument. It seems this fixed the problem of Constantinople. Is it?
05:39:46 <Gregor> elliott_: http://web.purplefrog.com/~thoth/netpipes/encapsulate.html
05:39:55 <Gregor> elliott_: But I'm still a bit confused by it, I'm not 100% sure that it's useful at all :P
05:40:41 <elliott_> http://www.google.co.uk/search?sourceid=chrome&ie=UTF-8&q=Session+Control+Protocol
05:40:45 <elliott_> This does not seem to be a widely-implemented thing
05:41:00 <elliott_> Also it came out of an HTTP working group, so it's going to be terrible and awful
05:41:15 <Gregor> elliott_: Indeed, encapsulate seems to be the only program that ever implemented it.
05:41:26 <elliott_> Maybe that's a different SCP
05:41:30 <pikhq> Right bastards, convinced that HTTP is the end-all be-all of protocols.
05:41:31 <elliott_> Than the working group one, I mean
05:41:42 <elliott_> Gregor: Didn't HackEgo just allow "full networking" but then firewall it all off?
05:41:45 <elliott_> Wouldn't that work?
05:41:54 <Gregor> elliott_: Nope, same one.
05:42:00 <elliott_> Gregor: Eh?
05:42:06 <Gregor> elliott_: Same SCP
05:42:32 <Gregor> elliott_: Yes, HackEgo just firewalled everything. That won't work because UML's "full networking" options all suck ass.
05:42:42 <elliott_> Gregor: They do? :-P
05:43:21 <elliott_> Hmmmmmm
05:43:38 <Gregor> There's slirp, which is previously-discussed terrible, various things that only communicate between multiple UMLs, and a TUN/TAP-based protocol, which isn't going to work since that's a new host-kernel net device per guest.
05:43:43 <elliott_> Gregor: I'm slightly worried that I'm tempted to say this solution is the wrong way seemingly just because it's become actual work for me
05:43:52 <elliott_> Which is not really good thinking
05:43:56 <elliott_> "various things that only communicate between multiple UMLs"
05:44:01 <elliott_> What if you used another UML with full network access
05:44:27 <Gregor> ... hmmmmm ... I hadn't investigated those options at all because they're so failury ...
05:44:35 <elliott_> It's horrible, but it might be easier.
05:44:39 <Gregor> (The just-multiple-UML-options that is)
05:44:43 <elliott_> Although I fear you'd have to end up doing the multiplexing yourself
05:44:46 <elliott_> Also: "which isn't going to work since that's a new host-kernel net device per guest."
05:44:51 <elliott_> TUN/TAP xreation is hardly expensive is it
05:44:58 <elliott_> creation
05:45:23 <pikhq> Why can't UML do qemu's (horrible) userspace networking emulation?
05:45:55 <Gregor> pikhq: Because it's not UML's, it's qemu's :P
05:46:08 <pikhq> Gregor: The scheme should be general.
05:46:17 <pikhq> If also a royal pain to implement.
05:46:26 <elliott_> The easiest way to get started with UML networking involves nothing special besides adding a switch to the UML command line.
05:46:27 <elliott_> The uml_net helper
05:46:27 <elliott_> First, you need to make sure that the uml_utilities are installed on the host. You'll be needing the uml_net helper from that package.
05:46:27 <elliott_> Configuring an eth0 device
05:46:27 <elliott_> You can either
05:46:29 <elliott_> specify eth0 on the command line:
05:46:31 <elliott_> eth0=tuntap,,,192.168.0.254
05:46:33 <elliott_> Enabling the device is exactly the same as any other Linux machine, except you'll likely do by hand at first for UML:
05:46:37 <elliott_> UML# ifconfig eth0 192.168.0.253 up
05:46:39 <elliott_> * modprobe tun
05:46:40 <elliott_> * ifconfig tap0 192.168.0.252 netmask 255.255.255.255 up
05:46:42 <elliott_> * bash -c echo 1 > /proc/sys/net/ipv4/ip_forward
05:46:44 <elliott_> * route add -host 192.168.0.253 dev tap0
05:46:46 <elliott_> * bash -c echo 1 > /proc/sys/net/ipv4/conf/tap0/proxy_arp
05:46:48 <elliott_> * arp -Ds 192.168.0.253 eth0 pub
05:46:50 <elliott_> Gregor: this does not sound all that difficult
05:46:55 <Gregor> pikhq: Especially so since it's based on slirp. And yet, fail.
05:47:37 <elliott_> Gregor: BTW: I feel like this might be easier with Xen, in the long-run, minus the pain that is Xen
05:47:41 <Gregor> elliott_: It's easy enough to get running, but A) it requires a setuid-root binary, which I find terrible in general even if it works for me now and B) it's one host-kernel tap device per guest, which is just lame.
05:48:18 <elliott_> Gregor: It's also about three hundred lines less work :P
05:48:36 <elliott_> But OK, do you want me to make host.py do the select and buffer thing?
05:48:55 <Gregor> elliott_: Sowait ... doesn't encapsulate do everything we need? :P
05:49:20 <Gregor> (Other than the initial socket()s and bind()s)
05:49:28 <elliott_> Gregor: You implied it didn't
05:49:34 <elliott_> Gregor: It requires a client that supports SCP doesn't it
05:49:45 <Gregor> Yes, namely encapsulate.
05:49:45 <itidus20> australian music is proving to be very introspective
05:49:53 <itidus20> thats our kick over here
05:50:20 <elliott_> Gregor: I don't really understand how it works if it does not create the sockets
05:50:28 <elliott_> It can't just read other processes' fds
05:50:42 <Gregor> elliott_: It gets passed in the FDs from the caller.
05:51:25 <elliott_> server$ faucet 3001 --once --fd3 \
05:51:25 <elliott_> sh -c 'while ~/src/netpipes4.0/encapsulate --fd 3 -so5i4 \
05:51:26 <elliott_> sh -c "fname=`cat 0<&4`; echo \$fname; cat < \$fname 1>&5"; \
05:51:26 <elliott_> do true; done'
05:51:26 <elliott_> client$ hose server 3001 --retry 10 --delay 1 --fd3 \
05:51:27 <elliott_> sh -c 'while read fname; do \
05:51:29 <elliott_> ~/src/netpipes4.0/encapsulate --fd 3 -si4o5 \
05:51:31 <elliott_> sh -c "echo $fname 1>&5; exec 5>&-; cat 0<&4" \
05:51:33 <elliott_> || break; done'
05:51:35 <elliott_> This guy really likes his programs
05:51:39 <elliott_> (faucet and hose are also fom that :P)
05:52:02 <elliott_> Gregor: Weellllllllllll. Don't we already have 90 percent of what we need already
05:52:17 <elliott_> I mean, effort of figuring out encapsulate + the wrapper required vs. effort of a select() and some buffering
05:52:52 <Gregor> Idonno, you tell me, you're the one writing it right now X-D
05:53:09 <elliott_> Gregor: I was asking how much effort the former would take, 'cuz I'm not doing it
05:53:29 <elliott_> Also netpipes looks very bitrotten:
05:53:29 <elliott_> encapsulate.html 28-Oct-1998 15:39 13K
05:53:35 <elliott_> netpipes-4.2-export...> 30-Jan-1999 12:09 74K
05:53:39 <Gregor> Yowza
05:53:43 <Gregor> That I didn't notice ...
05:53:52 <Gregor> Yeah, should probably continue without it :P
05:53:55 <elliott_> netpipes (As of November 1998, version 4.2 is available)
05:54:03 <elliott_> COPYRIGHT
05:54:03 <elliott_> Copyright (C) 1997-98 Robert Forsman
05:54:03 <elliott_> :P
05:54:25 <elliott_> Gregor: (Says the guy who's favoured networking tool was last updated two to three years before that)
05:54:44 <elliott_> Gregor: OK, can I have guest.py and host.py? :-P
05:55:16 <pikhq> elliott_: What, nc?
05:55:29 <elliott_> pikhq: Yes.
05:55:34 <pikhq> :)
05:55:45 <Gregor> elliott_: curl http://sprunge.us/PWAL | sh
05:56:06 <elliott_> X_X
05:56:10 <Gregor> :P
05:56:45 <elliott_> OK, here goes shit >_<
05:57:09 <elliott_> sys.stderr.write(str(sockets.keys()) + "\n")
05:57:11 <elliott_> Gregor: Y'can remove that now :P
05:57:18 <elliott_> Wait, how did we fix that
05:57:20 <elliott_> Oh right
05:57:21 <elliott_> I remember now
05:57:26 <elliott_> BTW, that flush is redundant
05:57:29 <elliott_> And the whole thing could be a print :P
05:58:09 <elliott_> !python filter(None, [9,None,0])
05:58:13 <elliott_> !python print filter(None, [9,None,0])
05:58:14 <EgoBot> ​[9]
05:58:18 <elliott_> Oh god dammit
05:58:18 <Gregor> I don't know how to print() to stderr
05:58:22 <elliott_> Good enough
05:58:26 <elliott_> Gregor: print >>sys.stderr, ...
05:58:32 <Gregor> And now I doooooo!
05:58:42 <Sgeo_> Python 2.x?
05:58:50 <elliott_> Sgeo_: Yes, aka the version everyone uses.
05:59:21 <monqy> is it better
05:59:23 <elliott_> Gregor: You're right in that the guest and host will look very similar after this...
06:00:01 <Gregor> Sooo ... mux.py :)
06:00:11 <elliott_> Gregor: Well, I'll do host.py first, and then see :P
06:00:23 <Gregor> Or mudem.py!
06:01:58 <elliott_> Cows go mudem
06:04:48 <elliott_> Gregor: OK, this is sort of working out >_>
06:06:22 <augur> elliott_: so
06:06:28 <augur> hows life with the riots ey
06:06:42 <elliott_> augur: i live in a small rural town
06:06:58 <augur> oh?
06:07:06 <elliott_> so, the answer is exactly as normal :P
06:07:51 <elliott_> Gregor: Hmm, how do disconnections show in select()?
06:07:55 <elliott_> As a read or as an ~exceptional condition~
06:08:03 <Gregor> I don't recall
06:08:15 <elliott_> Ugh >_>
06:08:37 <Gregor> I seem to recall, however, never ever using the exceptional conditions buffer ...
06:09:03 <elliott_> Fair enough, then
06:09:26 <elliott_> Actually it shouldn't matter (much)
06:09:39 <elliott_> I love how my Python style involves NO OBJECTS EVER
06:09:44 <elliott_> Time to add another global hashtable
06:09:57 <elliott_> This can be cleaned up when it works >_>
06:10:11 <elliott_> Gregor: Happily, the same protocol can be maintained
06:10:16 <elliott_> The host just does weird shit to maintain it
06:16:10 <elliott_> Gregor: OK.
06:16:13 <elliott_> I _think_ it might work.
06:16:18 <elliott_> I've tested it none, but hey.
06:16:38 <elliott_> Gregor: http://sprunge.us/CUiE
06:16:46 <elliott_> Dammit it's revealed my secret codename.
06:18:44 <Gregor> I would recommend actually importing sys if you intend to use it.
06:18:59 <elliott_> Gregor: Erm
06:19:04 <elliott_> Gregor: It gets imported from host and guest, luckily
06:19:09 <elliott_> But yes good idea
06:20:01 <Gregor> elliott_: It needs to be imported in common to run at all.
06:20:07 <Gregor> Python doesn't muddy namespaces like that.
06:20:22 <Gregor> Anyway, I'm back to the eternal nonfunctional wait.
06:20:28 <elliott_> Yer kidding me
06:20:36 <elliott_> It uses select, that shouldn't happen :(
06:20:42 <Gregor> http://sprunge.us/IagV
06:20:45 <elliott_> If I wasn't too scared of how horrific the Python debugger was...
06:20:50 <elliott_> Is, presumably is, whatever.
06:20:52 <Sgeo_> Wait, is elliott_ facing the same problem I was once?
06:21:00 <elliott_> Gregor: What did you actually change
06:21:02 <elliott_> Sgeo_: What problem
06:21:15 <Sgeo_> Globally accessible variable from multiple modules
06:21:19 <elliott_> No
06:21:20 <Gregor> elliott_: import sys, global next_id in host.py:cmd_connect
06:21:25 <elliott_> Gregor: Also, mux <<<<<<<<<<<<<<<<<<<<<<<< proxy-motown
06:21:36 <elliott_> Gregor: Latter is unneeded
06:21:40 <elliott_> Because += is not the same as = +
06:21:41 <elliott_> As in
06:21:44 <elliott_> next_id += 9
06:21:46 <elliott_> works
06:21:46 <elliott_> but
06:21:48 <elliott_> next_id = next_id + 9
06:21:50 <elliott_> wouldn't
06:21:57 <elliott_> This is because Python
06:22:16 <Gregor> elliott_: This was not a "I'mma just write some shit" change, this was a "does not run" change.
06:22:24 <elliott_> Hmm
06:22:25 <Gregor> elliott_: next_id += 1 forced next_id to be a local.
06:22:27 <elliott_> Then Python changed :P
06:22:33 <Gregor> Python's scoping rules are as bad as you can possibly imagine.
06:22:35 <elliott_> God I hate Python, but yeah OK.
06:22:41 <elliott_> Gregor: Yes but I thought += operated on the object
06:22:44 <elliott_> Which made it work
06:22:46 <Gregor> They make PHP's scoping rules look brilliant.
06:24:06 <elliott_> Gregor: So, OK, um.
06:24:12 <elliott_> Gregor: You need to pause the program and print out some variables for me :-P
06:24:14 <elliott_> Actually hmm
06:24:16 <elliott_> If you pass -i to python
06:24:21 <elliott_> Then Ctrl+C drops you at a REPL with all the variables
06:24:22 <Gregor> elliott_: Why don't you run it :P
06:24:23 <elliott_> So you actually can do that
06:24:29 <elliott_> Gregor: Because I have no socket servers to do it on >_>
06:24:43 <Gregor> I'm just using dpipe and TCP.
06:24:56 <elliott_> Never heard of dpipe
06:24:59 <elliott_> Oh, something from that vde thing
06:25:05 <elliott_> I guess netcat would work
06:25:07 <Gregor> elliott_: It's totally non-vde-related.
06:25:17 <Gregor> elliott_: It's just a bidirectional pipe.
06:25:25 <elliott_> Right.
06:25:30 <Gregor> elliott_: Also, going interactive when your stdin and stdout are crazy protocol isn't useful :P
06:25:42 <elliott_> Yes it is, because Ctrl+C stops the program
06:25:45 <elliott_> Oh, I see
06:25:47 <elliott_> Right :P
06:25:48 <elliott_> Sucks
06:25:49 <Gregor> But now, I must go to sleep.
06:26:21 <elliott_> Gregor: Um wait
06:26:25 <elliott_> Gregor: You did tie the ends together, right?
06:26:32 <elliott_> Like, you did pipe guest.py and host.py properly :P
06:26:38 -!- GreaseMonkey has quit (Ping timeout: 258 seconds).
06:36:03 -!- pikhq_ has joined.
06:36:10 -!- pikhq has quit (Ping timeout: 252 seconds).
06:44:01 -!- derrik has joined.
06:53:34 -!- NihilistDandy has quit (Remote host closed the connection).
06:53:53 -!- NihilistDandy has joined.
06:56:35 -!- derrik has left.
06:57:39 <elliott_> pikhq_: NihilistDandy: HAHAHAHAHA I AM TAKING YOUR BELOVED HASKELL HOSTAGE
06:57:46 <elliott_> WHEN I AM THROUGH WITH IT YOU WON'T HAVE ANY IDEA WHAT IT USED TO BE
06:58:02 <elliott_> I SHALL STRIKE INTROSPECTION THROUGH THE HEART OF THE THING!!!!!!!!!!!!!!!!!!!!!!!
06:58:14 <pikhq_> elliott_: ÞOU SHALT DIE I SHALL MAKE SURE OF ÞY DEAÞ.
06:58:26 <pikhq_> FOR ÞE ÞORN DEMANDEÞ IT
06:59:37 <elliott_> HAHAHAHAHAHAHA YOU WON'T BE SAYING THAT WHEN YOU CAN BRING UP ANY OBJECT IN THE SYSTEM AND VIEW ALL ITS FIELDS AND MODIFY THEM FROM WITHIN ELLIOTTCRAFT
07:00:04 <elliott_> (YES THIS IS ACTUALLY USEFUL IT'S BASICALLY AN OBVIOUS EXTENSION OF THE GENERIC SERIALISATION MECHANISM + THE FACT THAT I NEED TO PRESENT MODIFIABLE DATA STRUCTURES AS FORMS, ANYWAY)
07:00:04 <pikhq_> ...
07:00:16 <pikhq_> You frighten me sometimes.
07:00:20 <elliott_> (BASICALLY IT'S AS EASY AS WRITING A GENERIC FORM TO DISPLAY "A RECORD, ANY RECORD")
07:01:11 <elliott_> pikhq_: OK but seriously it will be SO GOOD you have no idea.
07:01:21 <elliott_> I don't even need another typeclass to do the basic thing.
07:01:33 <elliott_> I can get a lens out of anything with a Data instance given a constructor and an index.
07:01:48 <elliott_> I can convert the field name "playerName" into "Player name" trivially.
07:01:58 <elliott_> From that it's a simple matter of presenting it.
07:02:18 <elliott_> I do need one extra type class, so that you can specify overridden names, like "worldDir" should be "World directory", not "World dir".
07:02:31 <elliott_> And also so that you can specify how fields should be displayed -- i.e. what form component should be used to display them.
07:02:46 <elliott_> For instance, the most appropriate control for the volume field is a slider.
07:02:51 <pikhq_> That doesn't mean you've stopped frightening me.
07:02:51 <elliott_> But for another it might be a text field.
07:03:06 <pikhq_> It just means you don't also make me murderous.
07:03:49 <elliott_> pikhq_: Let's put it this way: If I don't write this code, I write an entirely new heap of GUI controls for every single form in the game.
07:04:12 <elliott_> And if I do write it, I also get debugging inspection of any object at all automatically.
07:04:15 <elliott_> Which will be useful.
07:05:01 <pikhq_> elliott_: I should note that Oleg also frightens me.
07:05:49 <pikhq_> This does not mean I *dislike* the things he has made.
07:07:24 <elliott_> pikhq_: Anyway, my pain is already going to be quite fun, because I want GUI-ish widgets, obviously, for things like the chat box, configuration pages, blah blah blah. Now, I can't use GTK, one because of portability (it sucks on Windows and OS X) and two because... well, look, popping up normal-looking GUI widgets all over your game window looks horrible, no matter how "right" it may be. The same applies to any other generic UI toolkit, apart from may
07:07:24 <elliott_> be Qt. Now, I know Qt can be "skinned" in a way that makes it integrate perfectly with a game's look because Hedgewars does it. Unfortunately, one: Qt sucks; two: I don't like Qt; three: I don't think there's any decent Haskell binding to Qt. Besides, a lot of GUI toolkits are ruled out anyway because they won't interact properly with OpenGL.
07:07:38 <elliott_> pikhq_: So, basically... I get to code my own GUI widgets. From scratch. Using OpenGL.
07:08:28 <pikhq_> Would it make you feel better to know that the Qt scheming mechanism is CSS?
07:08:50 <elliott_> I think I knew that, but yeah. Not sure I did.
07:08:54 <pikhq_> (probably not, because you're not going to want to use Qt, anyways)
07:08:59 <elliott_> pikhq_: Still, there doesn't even appear to be a Qt binding on Hackage.
07:09:07 <elliott_> The wiki just points to http://qthaskell.berlios.de/ which doesn't inspire confidence.
07:09:16 <elliott_> pikhq_: Qt is obviously not so much fun to bind because Haskell can't bind directly to C++.
07:09:17 <pikhq_> Understandable. The impedence mismatch is huge.
07:09:25 <elliott_> qtHaskell User Guide
07:09:25 <elliott_> David Harley
07:09:25 <elliott_> Copyright © 2010 David Harley
07:09:25 <elliott_> Well, OK, it could be worse.
07:09:37 <pikhq_> Could be Qt 2.
07:09:45 <pikhq_> Or 1. Mmmm, nonfree.
07:09:46 <elliott_> In two thousand and ten?
07:09:58 <pikhq_> No, I'm saying that in response to "could be worse".
07:10:01 <elliott_> Ah :P
07:10:04 <elliott_> http://qthaskell.berlios.de/doc/apiGuide/index.html ;; Meeeeeeeeh
07:10:12 <elliott_> I'm quite happy writing my own widgets really
07:10:15 <pikhq_> Only a complete, insane *moron* would deal with Qt 1 or 2 in 2010.
07:10:23 <elliott_> Why should you have to deal with Qt suckage when playing the perfect game ;-)
07:10:35 <pikhq_> ... That API.
07:10:38 <pikhq_> *hurl*
07:10:43 <elliott_> It's a fair low-level binding
07:10:49 <pikhq_> No kidding.
07:10:51 <elliott_> But, well, it's a low level binding.
07:10:57 <elliott_> Wait, waht the fuck, why is it using typeclasses everywhere
07:11:01 <elliott_> Eh, I don't even want to know
07:11:03 <elliott_> Oh, for C++ overloading
07:11:14 <elliott_> pikhq_: It amused me that right-clicking a text input field in Hedgewars popped up a "regular" menu, but styled with its vaguely cartoony look.
07:11:34 <elliott_> pikhq_: So it was offering me input methods and Unicode control character insertion inside a cartoony game interface.
07:11:59 <pikhq_> bsnes did an April Fool's release doing something similar. To imitate zsnes's UI
07:12:12 <pikhq_> (y'know, the UI designed for direct VGA access from DOS?)
07:12:14 <elliott_> I remember that
07:12:35 <pikhq_> Shame it didn't get the pointless snow covered.
07:12:47 <elliott_> ZSNES has snow?
07:12:50 <elliott_> Best emulator.
07:13:03 <itidus20> i have zsnes
07:13:09 <elliott_> itidus20: You don't want it.
07:13:15 -!- pikhq has joined.
07:13:17 <elliott_> Get Snes9x :-P
07:13:25 <itidus20> hmm
07:13:28 <elliott_> (Or bsnes, but I doubt you have the computer for that)
07:13:36 <itidus20> lol
07:14:05 <elliott_> pikhq_: Hmm, there's a slight problem with designing my own controls, in one area: I can't support X compose and the like.
07:14:15 <itidus20> i have always stuck with zsnes
07:14:28 <elliott_> As in, the input method will just be... whatever I code, which is unlikely to make you happy if you type in anything that isn't English, because I'm not gonna bundle my own alt gr table or whatever.
07:14:30 <itidus20> so, snes9x is the way to go?
07:14:44 <elliott_> itidus20: ZSNES is a very inaccurate emulator, and basically piles upon dozens of hacks to make any game work
07:14:50 <elliott_> It emulates even many popular games incorrectly
07:14:59 <itidus20> but that gives it speed?
07:15:10 <elliott_> Snes9x is much better, it's not written in unportable assembly for one :P, and it's fast enough to run on anything ZSNES will nowadays.
07:15:10 <pikhq> Yes, in the same way that Windows 3.1 is fast.
07:15:33 <zzo38> Then I would suppose homebrew games are going to work even more incorrectly
07:15:34 <elliott_> Snes9x still has a bunch of hacks, but the only thing that doesn't is bsnes, which has basically completely accurate SNES emulation; you need a beefier CPU though
07:15:38 <pikhq> In pretty much *exactly* the same way, in fact: ZSNES is a DOS-era program that got ported.
07:15:44 <elliott_> zzo38: Sadly, many homebrew games _only_ work on ZSNES.
07:15:52 <elliott_> zzo38: Because people test them on ZSNES rather than the real console, because it's much more convenient.
07:15:58 <itidus20> i don't have philosophical dilemmas about whether the opcodes of a rom are being emulated in a uniform way
07:15:59 <elliott_> So they end up relying on ZSNES' many emulation bugs.
07:16:09 <elliott_> itidus20: You don't care if your game runs wrongly?
07:16:18 <pikhq> elliott_: bsnes works just fine on my not-that-beefy system, though.
07:16:22 <itidus20> if it has hacks in placeto make it work
07:16:26 <itidus20> then i don't mind
07:16:27 <elliott_> itidus20: It isn't perfect.
07:16:30 <elliott_> Not by any means.
07:16:34 <elliott_> ZSNES has noticeable emulation bugs in many popular games.
07:16:42 <elliott_> Anyway, Snes9x has a much nicer interface too, so you'll be doing yourself a favour.
07:16:50 -!- pikhq_ has quit (Ping timeout: 240 seconds).
07:16:56 <elliott_> (BTW, ZSNES isn't actively developed any more.)
07:17:07 <pikhq> Last commit was, what, 2003?
07:17:10 <elliott_> (Well, OK, they say it is, but it hasn't released for four years and development is private.)
07:17:18 <elliott_> pikhq: Release in 2007 apparently, says Wikipedia
07:17:19 <pikhq> s/Last/Last public/
07:17:21 <itidus20> which noticeable emulation bugs? i won't argue their signifigance.. but i am curious
07:17:29 <elliott_> itidus20: Too numerous to list, unfortunately
07:17:47 <pikhq> itidus20: http://byuu.org/bsnes/images/accuracy/harukanaru-incorrect.png
07:17:50 <elliott_> itidus20: You can see some of the ntoiceable effects in this article:
07:17:52 <elliott_> http://arstechnica.com/gaming/news/2011/08/accuracy-takes-power-one-mans-3ghz-quest-to-build-a-perfect-snes-emulator.ars
07:18:01 <elliott_> (written by the bsnes author, with a bunch of screenshots)
07:18:19 -!- Taneb has joined.
07:18:26 <itidus20> pikhq: that is a pretty awful emulation in that screenshot
07:18:32 <Taneb> Morning!
07:18:40 <itidus20> it did get the word Player right though
07:19:11 <oerjan> Taneb: you might want to check the logs for zzo38's Constantinople comments
07:19:17 <elliott_> oerjan: he put them on the wiki
07:19:19 <itidus20> what exactly makes snes so hard to emulate?
07:19:21 <elliott_> pikhq: But yeah, any ideas what to do with Unicode in my text input?
07:19:21 <oerjan> oh
07:19:22 <oerjan> ok
07:19:34 <elliott_> itidus20: Basically, the hardware has very precise timing.
07:19:38 <itidus20> ahhhh
07:19:41 <elliott_> itidus20: You can't even synchronise everything at the instruction level.
07:19:49 <elliott_> You have to synchronise all the many different parts of it at the cycle level.
07:19:58 <pikhq> itidus20: Additionally, the SNES has tons of processors to emulate.
07:20:05 <elliott_> itidus20: Oh, and cartridges can literally include their own CPUs.
07:20:21 <elliott_> Yes, many, many popular games had their _own specialised processors_ on the cart.
07:20:23 <itidus20> when i was growing up... i wanted a snes more than i wanted a girlfriend
07:20:30 <coppro> itidus20: this is normal
07:20:40 <pikhq> Some of them had a *better* processor than the SNES.
07:20:45 <itidus20> i mean.. i wanted it _BAD_
07:20:54 <pikhq> (SuperFX)
07:20:57 <elliott_> <elliott_> pikhq: But yeah, any ideas what to do with Unicode in my text input?
07:21:03 <itidus20> i knew that this fucking device was going to be the best thing to ever happen
07:21:10 <itidus20> and as time has told us.. it pretty much was
07:21:13 <coppro> hell, even now, I consider a companion to be "something nice that I'd wouldn't mind having"
07:21:48 <pikhq> elliott_: Uh, convert (lossily) to CP437?
07:21:55 <pikhq> elliott_: :P
07:22:05 <elliott_> pikhq: I can handle Unicode just fine, I'm just saying that all keypresses come in raw
07:22:13 <elliott_> Only processed to make the scancodes portable :P
07:22:13 <zzo38> I still prefer NES anyways, rather than SNES; not only the games (which include both homebrew games and offical games) but also the way the system works
07:22:14 <itidus20> i can't describe the sheer desire i had for a SNES
07:22:16 <pikhq> Yeah, I dunno.
07:22:28 <elliott_> pikhq: So alt gr won't work, compose won't work... I dunno how to let people input Unicode without making it a huge pain for me or bad for them
07:22:34 <itidus20> like that nintendo 64 kid
07:22:40 <itidus20> except i was older and i had no excuses
07:22:51 <pikhq> elliott_: Sounds utterly non-trivial with the current stack.
07:23:29 <pikhq> elliott_: Would be easy in not-too-long. All the keyboard handling is getting factored out into a library in the name of Wayland.
07:23:34 <elliott_> pikhq: I suppose I could parse XCompose files... but then most people don't use compose either, they use their locale-specific keyboard layout... which I suppose _will_ work here, because I think the keyboard layout is taken into account
07:23:37 <elliott_> It should be because I get a Char
07:23:46 <elliott_> But anything that involves pressing multiple keys together... nope
07:25:19 <elliott_> pikhq: Oh well, I can't possibly do worse than Minecraft does Unicode
07:25:32 <pikhq> "Doesn't"?
07:26:04 <elliott_> pikhq: Well, it supports SEVERAL characters that also feature in Unicode!
07:26:17 <itidus20> so is there a dynamic recompiling snes emulator?
07:26:22 <elliott_> Swedes, Finns and Norwegians may even find that their ENTIRE ALPHABET is available!
07:26:37 <elliott_> itidus20: The overhead required to synchronise everything would make that slower than the emulation approach
07:26:43 <pikhq> elliott_: Actually, only an approximation.
07:27:45 <itidus20> how complex could it be though... does the SNES have anything that could resemble an abstract machine?
07:27:46 <pikhq> elliott_: CP437 lacks Ø and ø.
07:28:07 <elliott_> pikhq: Woot :P
07:28:22 <elliott_> itidus20: It could be very complex, since there are multiple processors doing their job at once, with different clock rates, that are all communicating.
07:28:27 <elliott_> And one of them is analogue.
07:28:30 <itidus20> its basically about character blocks, sprites, rotations, controller input, calculations, and sound
07:28:33 <elliott_> No, no it isn't.
07:28:43 <elliott_> pikhq: How long has bsnes been in development?
07:28:48 <elliott_> Ah, seven years.
07:29:14 <elliott_> itidus20: If you want to learn what the SNES is "basically about", i.e. the abstract machine behind it, here's the product of seven years of research: http://bsnes.googlecode.com/files/bsnes_v081-source.tar.bz2
07:29:34 <elliott_> itidus20: It's written for humans rather than for speed, so you should be able to discern all details of the abstract machine underlying the SNES from it.
07:29:37 <pikhq> It'd probably take much less time to implement from scratch, though: much of that time was *obscene* amounts of research into the behavior of the system.
07:29:44 <elliott_> itidus20: Note: This may be a much more difficult task than you anticipate.
07:29:55 <elliott_> bsnes/snes/ is the directory you want.
07:30:07 <pikhq> You'll note that it contains a Gameboy emulator by necessity.
07:30:29 <itidus20> i .. find the term i used abstract machine to be quite ugly now seeing it turned back on me
07:30:30 <coppro> wha
07:31:03 <pikhq> coppro: One of the CPUs placed on a cartridge was a Gameboy.
07:31:17 <itidus20> i had a super gameboy
07:31:28 <itidus20> i was dissapointed when i discovered it wasn't portable though
07:31:28 <elliott_> pikhq: OK, now I really want to fashion some kind of cartridge output onto the playstation two.
07:31:51 <elliott_> Maybe it'll crush your SNES if you plug it in vertically, but bsnes would be FORCED to include a full cycle-accurate emulator!!!!!!
07:31:56 <zzo38> I wrote a Constantinople compiler completely except for the parser. Once the parser is written then it will be complete.
07:32:04 <itidus20> it seemed obvious to me that the super gameboy would be handheld and also plug into the snes for a tv play.. but twas not to be the case
07:32:11 <Taneb> Yay!
07:32:28 <Taneb> I've made the change to the spec yoou suggested
07:32:32 <Taneb> i.e. the withs
07:32:42 <zzo38> Yes I saw that. Thank you
07:33:23 <Taneb> I think constantinople manages to be human readable while still being really hard to work out what's going on
07:33:27 <elliott_> pikhq: I somehow feel that Elliottcraft is going to take an awful lot of infrastructure.
07:37:15 <coppro> pikhq: brilliant
07:37:26 <coppro> also holy crap I might still win this BN dynasty
07:39:09 <elliott_> is blognomic any less boring than the last time
07:39:39 <coppro> when is "last time"?
07:39:51 <elliott_> any other time in history
07:41:11 <elliott_> pikhq: The main problem with this generic introspection infrastructure is that I'm not sure how to structure the additional class I need without it being redundant with things already offered by Data. :/
07:41:48 <elliott_> ...and that also isn't really brittle when you change the record but forget to change the instance.
07:42:14 <oerjan> elliott_: subclass actual Data?
07:43:01 <elliott_> oerjan: well yes, but the point is that I can't find a way to structure the needed typeclass _member_ in such a way that you can't accidentally fill it in and give inconsistent information to Data
07:43:11 <coppro> elliott_: then no
07:43:11 <elliott_> as in, I can't find out a way to guarantee that Data and this class don't contradict each other
07:43:42 <oerjan> hm
07:43:53 <coppro> elliott_: although this time it has relatively good gameplay, a defined victory condition, and several people all within reasonable distance of the end
07:44:37 <elliott_> coppro: but does it still have that essential boringness
07:45:06 <elliott_> oerjan: hmm, I suppose I could just have "fieldInfo :: String -> Maybe (String,FormComponentLol)"
07:45:09 <elliott_> where the string is the human name
07:45:17 <elliott_> that's kind of gross though since what it really is meant to be is
07:45:29 <elliott_> fieldInfo :: FieldName a -> (String,FormComponentLol)
07:45:31 <elliott_> with the clause
07:45:40 <elliott_> fieldInfo a = (humanify a, defaultformcomponentforitstype)
07:45:41 <elliott_> at the end
07:45:46 <elliott_> but you can't....
07:45:47 <elliott_> do that
07:46:36 <coppro> elliott_: you'd have to decide that yourself
07:46:48 <elliott_> coppro: so yes then :P
07:47:04 <coppro> elliott_: If I'd said no, would you have believed me?
07:47:15 <elliott_> coppro: maybe enough to load blognomic.com
07:50:49 <zzo38> If it has a well-defined win condition, but does it have a well-defined end condition? Go has a well-defined win condition but not a well-defined end condition.
07:51:51 <oerjan> nomics frequently end when there is a win
07:52:27 <oerjan> either that, or they never end
07:52:45 <oerjan> unless there's a total collapse
07:53:22 <zzo38> This is what I have of the Constantinople compiler so far, it consists of two files: Constantinople.lhs = http://sprunge.us/NQQV Main.hs = http://sprunge.us/FKYe
07:54:00 <oerjan> i have this vague recall that agora shifted at one time from saying that a new game started when someone won, to saying that the game just goes on indefinitely
07:54:47 <elliott_> oerjan: Yes.
07:55:31 <elliott_> oerjan:
07:55:31 <elliott_> Rule 104/0 (Power=3)
07:55:31 <elliott_> First Speaker
07:55:31 <elliott_> The Speaker for the first game shall be Michael Norrish.
07:55:31 <elliott_> [CFJ 1534 (called 8 March 2005): This does not mean that Michael
07:55:31 <elliott_> Norrish necessarily fills the position of Speaker at the present
07:55:33 <elliott_> time.]
07:55:35 <elliott_> [CFJ 2154: (called 8 September 2008) The Speaker for the first game
07:55:36 <zzo38> (This program does work I have tested it.)
07:55:37 <elliott_> shall be Michael Norrish.]
07:55:39 <elliott_> History:
07:55:41 <elliott_> Initial Immutable Rule 104, Jun. 30 1993
07:55:43 <elliott_> Mutated from MI=Unanimity to MI=3 by Proposal 1482, Mar. 15 1995
07:55:49 <elliott_> oerjan: The only unchanged rule in Agora, 104/0, from the current ruleset.
07:56:09 <oerjan> heh
07:56:33 <zzo38> Taneb: Can you look at my program tell me if it follows what you are thinking of?
07:56:40 <elliott_> That rule's last change is of adult age in many parts of the world.
07:57:11 <pikhq> Let's declare it a player.
07:57:34 <elliott_> pikhq: Agora's an autonomous person as of shortly after its eighteenth birthday
07:57:42 <elliott_> It is ostensibly going to try and play BlogNomic at some point
07:59:05 <elliott_> Sooo... Elliottcraft main non-game todo list: Implement generic introspection and modification system for objects. Implement generic serialisation mechanism on top. Implement FRP-based GUI toolkit using OpenGL through GPipe.
07:59:54 <pikhq> elliott_: No, just that rule.
08:00:10 <elliott_> pikhq: Well... there's precedent...
08:02:09 <zzo38> Tell me if I did anything messy because I am not very good at Haskell and maybe some things I could have done in better way. I know the patterns of w_tail is not exhaustive but the specification of Constantinople doesn't say anything about that.
08:02:55 <itidus20> elliott_: is the main problem with emulation really sound? i imagine that being that graphics are fixed at a framerate it's much easier to handle them
08:02:57 <elliott_> zzo38: you don't need the ; at the end of every line
08:03:01 <elliott_> it's unidiomatic
08:03:22 <pikhq> itidus20: The main problem is everything.
08:03:42 <pikhq> Though, amusingly, the sound is one of the *easier* bits to emulate.
08:03:44 <elliott_> itidus20: Sound is a major problem because of the latency guarantees and the fact that it's partly analogue on the SNES. But... the main problem is synchronisation, and emulation at the cycle level.
08:03:53 <PatashuWarg> Wait, you make compilers for people if they just ask you?
08:04:04 <elliott_> Doesn't look like a compiler to me.
08:04:09 <zzo38> elliott_: It is not at the end of every line. Although the reason is I use nonlayout style so I put ; at the end of every line.
08:04:10 <PatashuWarg> Oh sorry, interpreter
08:04:18 <elliott_> zzo38: Why non-layout
08:04:33 <itidus20> in other words.. i simply cannot imagine that you need a 3ghz pc to produce a 640x480 frame in 2d at 60fps
08:04:36 <elliott_> Everything you have there would work identically if you removed the two {}s and the semicolons
08:04:52 <elliott_> itidus20: It isn't just displaying frames
08:04:53 <itidus20> i know its not 640x480.. i don't know what it is though
08:04:54 <zzo38> elliott_: It is a compiler. It is just incomplete because the parser is not written yet. And then you can ghc Main.hs < ConstantinopleProgramCode and it compile into the executable file.
08:05:03 <elliott_> itidus20: It's emulating many, many systems
08:05:09 <zzo38> I just prefer nonlayout.
08:05:10 <elliott_> zzo38: Oh, okay.
08:05:28 <elliott_> zzo38: Well, you don't have to use layout just because it's enabled.
08:05:38 <elliott_> The only affect it'd have would be to let you elide the semicolons.
08:05:38 <itidus20> hummmmmmmmmmmmm............. ok
08:06:06 <zzo38> I find nonlayout clearer actually...
08:06:20 <elliott_> Well, OK. It's not very idiomatic, though.
08:07:18 <zzo38> Is there anything else wrong other than the semicolons?
08:07:31 <elliott_> Not that I can see.
08:07:38 <coppro> elliott_: you also forgot that Agora is actively playing itself
08:07:47 <elliott_> coppro: It is?
08:07:54 <zzo38> I know I don't need "deriving Show" for Memory but I put it there for debugging purpose. I can remove it when it is finished.
08:07:58 <elliott_> zzo38: Although another unidiomatic thing is using _s as a suffix
08:07:58 <coppro> elliott_: yes
08:08:21 <itidus20> elliott_: well, it's amazing how difficult emulation proves to be... it's counter-intuitive
08:08:26 <elliott_> (Generally camelCase is preferred to separate words, but under_scores aren't unheard of; but as a suffix it's very unidiomatic, especially as it can be confusing (f'_ looks like the function f' with the pattern _ to me))
08:08:46 <coppro> elliott_: someone made a rule saying that agreements intending to be persons are persons. Then someone made a rule saying that Agora intends to be a person. Then someone proposed that Agora register IIRC
08:08:57 <zzo38> O, OK, I didn't know that. I put the _ suffix to prefer conflict with reserved words and imported words.
08:09:00 <elliott_> coppro: Fair enough
08:09:07 <zzo38> s/prefer/avoid/
08:09:16 <coppro> (on the basis that Agora is effectively an agreement to play by its rules)
08:09:31 <zzo38> What can you suggest I change it to?
08:10:06 <elliott_> zzo38: Well, "out" isn't in any of those packages AFAIK and it isn't a keyword... but I'd just try to rename them, mostly. I'm not sure what repeat_/repeat'_ do, so I can't really offer advice
08:10:20 <elliott_> You should probably use where clauses for your foo' functions, though
08:10:38 <zzo38> The repeat_ does the "repeat" command of Constantinople.
08:11:07 <elliott_> Ah
08:11:11 <zzo38> OK how should I use where clauses? I don't know much about where clauses
08:11:14 <elliott_> I'd prefix every command, say cmd_repeat
08:11:22 <zzo38> OK. Thanks
08:11:39 <elliott_> zzo38: where clauses look like this:
08:11:41 <coppro> grr stupid metroid prime game
08:11:41 <elliott_> foo :: a -> b -> c
08:11:41 <elliott_> foo = foo' 0
08:11:41 <elliott_> where foo' 0 a b c = ...
08:11:41 <elliott_> foo' n a b c = ...
08:11:45 <coppro> and stupid achievements
08:11:48 <elliott_> Presumably add a bunch of {}s and ;s for ugly non-layout :P
08:11:48 <coppro> achievements suck
08:11:51 <coppro> why am I a perfectionist
08:12:32 <elliott_> zzo38: Basically, foo' there is restricted to the scope of foo's body
08:12:44 <itidus20> elliott_: this reminds me of what carmack was saying about optimization. that optimized code becomes brittle and fragile. and as we can see snes software is so tightly bound to the snes hardware configuration that it can even strain a 3ghz cpu to replicate it. amazing
08:12:44 <elliott_> It helps you show that certain definitions are only used in the body of foo
08:13:09 <zzo38> Yes I can see it is not used anywhere else, things like "foo'" used only in the definition of "foo"
08:13:18 <elliott_> itidus20: Yes; later hardware like the Nintendo 64 had a much more well-defined and concrete API, so it is simpler to emulate; one can simply emulate the API, rather than every single piece of hardware at the lowest level.
08:13:32 <itidus20> ironic :D
08:13:35 -!- Taneb has quit (Remote host closed the connection).
08:13:52 <itidus20> ironic in that their own API left them vulnerable to emulation
08:14:24 <elliott_> "Vulnerable" seems the wrong word
08:14:57 <zzo38> OK, I can try to use where clauses
08:15:57 <itidus20> perhaps the trick to avoiding piracy is making something impossible to emulate
08:16:19 <coppro> no, there is no way
08:16:33 <PatashuWarg> you can't avoid piracy
08:16:50 <PatashuWarg> except by having a peripheral that' svery expensive, so you have to buy that or not enjoy the game
08:17:05 <PatashuWarg> think that mech game with the console of 30 different buttons (steel battalion?)
08:17:10 <zzo38> Making it impossible to emulate probably won't help a lot, it just makes it more difficult to write software for instead
08:17:32 <itidus20> suppose that you made a powerful hardware configration even more convoluted than the SNES... and wrote games for it in a way that it depended heavily on the hardware
08:18:00 <PatashuWarg> Sega Saturn
08:18:03 <itidus20> well i suppose piracy would still happen
08:18:04 <PatashuWarg> Actually has anyone bothered to emulate that yet
08:18:07 <zzo38> OK, I made it use where clauses now.
08:18:09 <PatashuWarg> (no because it was a failure)
08:18:15 <zzo38> And I renamed them to use cmd_ prefix instead of _ suffix
08:18:40 <itidus20> piracy would still happen because then the console itself becomes the weak point
08:18:53 <itidus20> once you have the console you can copy all of the softwares
08:19:10 <coppro> PatashuWarg: yes
08:19:21 <coppro> PatashuWarg: things much more esoteric have been emulated
08:19:26 <coppro> ever heard of a WonderSwan/
08:19:32 <coppro> No? Good. Neither have I.
08:19:35 <PatashuWarg> is that like a neogeo?
08:19:46 <itidus20> wonderswan was a competitor to the gameboy
08:19:48 <PatashuWarg> where's my n-gage emulator
08:20:05 <itidus20> it was made by the same guy who designed the gameboy
08:20:29 <elliott_> :t gmapQi
08:20:30 <lambdabot> forall u a. (Data a) => Int -> (forall d. (Data d) => d -> u) -> a -> u
08:20:50 <zzo38> What you have to do to avoid piracy is to make one arcade where you can play the game only there, you cannot get a copy of the software or go elsewhere to play game. However it makes it you will not get paid as much. With more piracy possible it actually means you can potentially get paid more, regardless of the actual amount of piracy.
08:21:39 <coppro> your site's navigation fails when: I can find the page I want faster with Google
08:21:46 <itidus20> and another problem with rigid privacy prevention systems is that it prevents people who really can't afford it from playing your works
08:22:10 <zzo38> Yes; which also means they cannot recommend it to someone who is able to pay for it.
08:22:40 <elliott_> coppro: that's probably true of almost every site design
08:23:04 <PatashuWarg> where's my n-gage emulatort
08:23:07 <PatashuWarg> whoops
08:23:11 <PatashuWarg> no but seriously. where is it
08:23:19 <zzo38> I don't know
08:23:37 <PatashuWarg> the n-gage threads on gamefaqs were hilarious
08:23:38 <PatashuWarg> good times
08:23:41 <itidus20> zzo38: but it makes a good excuse for sueing people and raising prices
08:24:00 <elliott_> pikhq: So, your package manager.
08:24:29 <coppro> elliott_: that it is faster to navigate by google?
08:24:34 <elliott_> coppro: Yes.
08:24:55 <coppro> elliott_: I suppose, but some try harder than others
08:25:26 <elliott_> coppro: Perhaps site headers should just include a big fat "search with google" box and then a link to a sitemap. :p
08:25:40 -!- Taneb has joined.
08:26:50 <coppro> k, I'm pause-scumming this
08:32:19 <zzo38> I will sleep today and will try to figure out how to write the parser tomorrow.
08:32:36 <Taneb> Okay
08:33:03 -!- zzo38 has quit (Quit: (In addition, remember Dangelo project if anyone has more ideas about it or responses to what I have added to its wiki)).
08:58:19 -!- CakeProphet has quit (Read error: Connection reset by peer).
08:59:33 -!- CakeProphet has joined.
09:04:01 -!- sebbu2 has joined.
09:04:01 -!- sebbu2 has quit (Changing host).
09:04:01 -!- sebbu2 has joined.
09:05:26 -!- sebbu has quit (Ping timeout: 264 seconds).
09:05:26 -!- sebbu2 has changed nick to sebbu.
09:05:38 -!- BeholdMyGlory has joined.
09:07:26 -!- Sgeo_ has quit (Read error: Connection reset by peer).
09:08:08 -!- Sgeo_ has joined.
09:09:39 <elliott_> instance Fields Config where
09:09:39 <elliott_> data Field Config t where
09:09:39 <elliott_> F_Config_Volume :: Field Config Int
09:09:39 <elliott_> F_Config_PlayerName :: Field Config String
09:09:39 <elliott_> F_Config_WorldDir :: Field Config FilePath
09:09:40 <elliott_> fields Config{} = [F_Config_Volume, F_Config_PlayerName, F_Config_WorldDir]
09:09:42 <elliott_> fieldInfo F_Config_Volume = FieldInfo "Volume" volume
09:09:44 <elliott_> fieldInfo F_Config_PlayerName = FieldInfo "Player name" playerName
09:09:46 <elliott_> fieldInfo F_Config_WorldDir = FieldInfo "World directory" worldDir
09:09:48 <elliott_> pikhq: BEHOLD MY UGLY.
09:15:44 <coppro> ewwwwwwwwwwwwwwwww
09:17:07 -!- augur_ has joined.
09:17:18 -!- Phantom_Hoover has joined.
09:17:23 <elliott_> coppro: To be fair, the underscores were only because I expect this to be generated, so I'm basically mimicking a computer by being as mechanical as possible.
09:17:31 <elliott_> The actual API is fairly elegant.
09:18:05 <coppro> elliott_: you expect me to treat you seriously after you whipped your ugly out in public like that?
09:18:15 -!- augur has quit (Read error: Connection reset by peer).
09:18:33 <elliott_> coppro: It's a free country.
09:19:28 <coppro> elliott_: that's what they want you to think
09:41:29 <elliott_> :t find
09:41:30 <lambdabot> forall a. (a -> Bool) -> [a] -> Maybe a
09:41:38 -!- augur_ has changed nick to augur.
09:41:45 -!- FireFly has joined.
09:41:49 <elliott_> :t findBy
09:41:50 <lambdabot> Not in scope: `findBy'
09:41:52 <elliott_> grr
09:41:54 <elliott_> ?hoogle findBy
09:41:55 <lambdabot> No results found
09:42:10 <Deewiant> findBy?
09:42:11 <oerjan> erm find is already "By"
09:42:17 <elliott_> oh right
09:42:18 <elliott_> im dumb
09:44:08 <coppro> woot finally
10:05:56 <elliott_> pikhq: Out of interest, have you ever used SIGPOLL?
10:06:25 <elliott_> Oh, hmm, it seems like aio.h is the new thing.
10:06:27 <elliott_> (Does musl have that?)
10:08:32 -!- nooga has joined.
10:09:44 <elliott_> Seems not.
10:10:01 <elliott_> Oh, hmm, it's in -lrt.
10:14:32 <elliott_> pikhq: Ello.
10:15:58 <fizzie> I vaguely recall that glibc's librt aio_blah implementations do a (mostly) POSIX implementation of aio in userspace (presumably with threads), instead of using the kernel's "native" asynchronous IO interfaces. But maybe that's been improved.
10:17:36 <fizzie> http://www.kernel.org/doc/man-pages/online/pages/man7/aio.7.html "The current Linux POSIX AIO implementation is provided in userspace by glibc.This has a number of limitations, most notably that maintaining multiple threads to perform I/O operations is expensive and scales poorly. Work has been in progress for some time on a kernel state-machine-based implementation -- but this implementation hasn't yet matured --"
10:17:44 <fizzie> I don't even have such a manpage, but anyhows.
10:18:14 <elliott_> I have an aio_read manpage.
10:18:20 <elliott_> But that sounds crappy.
10:18:28 <elliott_> The SIGIO type approach seems to be the best.
10:18:33 <fizzie> I have one for the functions too, but not for "aio" in section 7.
10:18:50 <elliott_> With fcntl(fd, F_SETSIG, signum) apparently you can even set it to a realtime signal, which I suppose creates MAGIC.
10:20:38 <fizzie> Not terribly portable, is it?
10:21:56 <elliott_> fizzie: Well... not as such, no...
10:22:18 <elliott_> fizzie: But as long as it works on Linux and is the fastest possible way to do IO without writing it in the kernel, I'm agme.
10:22:31 <PatashuWarg> Let's code BEER that emulates Linux syscalls on Windows
10:22:47 <elliott_> WINE emulates the API, not syscalls.
10:22:56 <elliott_> Cygwin is pretty much the exact same thing as WINE, but without the ABI translation.
10:23:04 <PatashuWarg> Oh yeah, cygwin
10:23:08 <elliott_> gelfload handled the rest I think -- ask Gregor
10:23:10 <PatashuWarg> Thanks for reminding me it exists
10:23:18 <elliott_> PatashuWarg: Don't thank me, Cygwin is terrible
10:23:20 <fizzie> elliott_: You could consider the Linux-native syscalls, which do have library wrappers: see "man io_setup" + io_submit + io_getevents + io_cancel + io_destroy.
10:23:23 <PatashuWarg> Pfflol
10:23:49 <fizzie> (That's what the future aio_blah functions are going to be implemented in, if it ever happens.)
10:24:04 <fizzie> Oh, "glibc does *not* provide a wrapper function for this system call".
10:24:16 <elliott_> fizzie: Weeell, the advantage of the signal approach is that you can avoid pretty much all the kernel<->userspace and polling/blocking overhead, right?
10:24:20 <elliott_> Because it's "hey, you call me".
10:24:23 <fizzie> There's a libaio and <libaio.h> somewhere.
10:24:33 <elliott_> Not that I've even man'd those named ones, but they look suspiciously like the other, slower kind.
10:25:15 <Taneb> ...How about MEAD that does... um...
10:25:24 <PatashuWarg> Mac OS?
10:25:27 <Taneb> BSD?
10:25:35 <elliott_> Taneb: Emulates the QNX API on Movitz?
10:25:51 -!- oerjan has quit (Quit: Good night).
10:30:20 <fizzie> Well, it's... asynchronous. It's not really relevant how it reports completion. There's still exactly the same amount of kernel-to-userspace copying going on. I mean, for POSIX aio, you can just set your struct aiocb's aio_sigevent to SIGEV_SIGNAL to get vaguely SIGIO-stylish "notice by signal when finished" behaviour; it's just non-natively implemented at the moment.
10:30:36 <fizzie> I don't know how the kernel's AIO interfaces do it, they seem a bit too work-in-progressy too.
10:31:18 <fizzie> But SIGIO doesn't really get you any sort of asynchronous IO, you just get signals when you can read/write, right?
10:31:39 <elliott_> back
10:31:58 <elliott_> fizzie: Well, hmm
10:32:07 <elliott_> I'm getting all these methods mixed up
10:32:19 -!- itidus20 has quit (Ping timeout: 240 seconds).
10:33:15 -!- Taneb has quit (Ping timeout: 260 seconds).
10:33:21 <elliott_> fizzie: Yeah, that does indeed seem to be true. I was hoping that you could tell the kernel "here's a buffer; here's the number of bytes I want; send me a signal when you've filled it".
10:34:11 <elliott_> fizzie: Probably the Linux syscalls are the best way, then.
10:35:01 <elliott_> It looks like they're edge triggered, which propaganda tells me is good.
10:35:42 <elliott_> fizzie: I'll probably avoid libaio because of all that, you know, overhea.d
10:35:44 <elliott_> overhead.
10:36:29 <elliott_> I must say that I find these syscalls' documentation of their input formats to be lacking.
10:37:22 -!- Taneb has joined.
10:37:55 <fizzie> Yes, it seems to be quite sukcy.
10:38:12 <fizzie> Also http://lse.sourceforge.net/io/aio.html says it doesn't really work in most cases.
10:38:43 <elliott_> "AIO read and write on sockets (doesn't return an explicit error, but quietly defaults to synchronous or rather non-AIO behavior)"
10:38:47 <elliott_> OK, well that's fucking useless then.
10:39:06 <elliott_> I can't quite believe that there's no kernel asynchronous IO for sockets.
10:39:35 <fizzie> Only for raw devices and O_DIRECT files on some filesystems; it seems that it's been implemented according to database folks' requirements.
10:40:21 <fizzie> "Asynchronous I/O on linux or: Welcome to hell." Well, that's a nice-sounding title.
10:40:31 <elliott_> Nice
10:40:38 <elliott_> Oh, that's the page I was reading
10:40:55 <elliott_> Unfortunately POSIX AIO on linux is implemented at user level, using threads! (Actually, there is an AIO implementation in the kernel. I believe it's been in there since sometime in the 2.5 series. But it may have certain limitations - see here - I've yet to ascertain current status, but I believe it's not complete, and I don't believe Glibc uses it).
10:41:07 <elliott_> Also apparently the POSIX API is crazy.
10:43:10 <fizzie> Yes, that's not too surprising.
10:43:31 <elliott_> So, um, there is _no_ actual asynchronous IO on sockets for Linux??
10:43:32 <elliott_> This is insane.
10:52:15 <elliott_> fizzie: Is... that right? I mean, I could be misreading...
10:53:02 <fizzie> It seems to be mostly right. I don't think very much work is going on with the kernel-side aio mechanism; there's a lot of stuff from ~2007 or so, but haven't seen any real news.
10:53:10 <elliott_> Well that's crap.
10:53:14 <elliott_> What do the BSDs have to offer, I wonder ;-)
10:54:33 <fizzie> They have the POSIX AIO api in their libc, I believe. No guess on lower-level implementation details.
10:55:02 <elliott_> So I suppose the Most Asynchronous you can get is either epoll or SIGIO plus blocking reads.
10:55:06 <elliott_> That's... super lame.
10:57:40 -!- nooga has quit (Ping timeout: 258 seconds).
10:59:01 <fizzie> My guess is that they've just given up implementing it in the kernel, since everyone seems to be doing networking just fine without it (with worker-thread pools and so on); and it works for direct-file IO because database people have been more interested.
10:59:01 <elliott_> It may even be the: super-lamest.
10:59:15 <elliott_> fizzie: Well yeeeeeees, but where's the fun in threads?
10:59:56 <elliott_> I wonder whether the SIGIO-type dealie set to a realtime signal or epoll is more OPTOMIZED. I suspect the answer is "the former, but signal handlers are so restricted that the infrastructure you need makes it as slow as the latter".
11:00:41 <fizzie> epoll's supposed to scale well for a large number of watched descriptors, at least.
11:05:48 <elliott_> fizzie: Still, it's distinctly unsatisfying... you have to fork off or spawn a thread or _something_ if you want to be reading and writing to it. Or, hmm, I wonder if I could make it O_NONBLOCK?
11:06:33 <fizzie> I'm not sure how that'd help; I mean, epoll already tells you when it's safe to read/write some without blocking.
11:07:00 <elliott_> Oh, well, dur.
11:07:25 <elliott_> Maybe I'll just run Synthesis in a Motorola CPU emulator. That's practical, right?
11:09:08 <fizzie> Incidentally, I'm not even sure what you're doing.
11:09:37 <olsner> elliott_: bonus points if the motorola cpu emulator needs to be run in a PowerPC emulation
11:09:55 -!- nooga has joined.
11:10:37 <elliott_> fizzie: Well, that's because I didn't tell you. Basically I'm hoping that minimalism will help me overcome the unrealisticness of hubris.
11:10:46 <elliott_> What I'm saying is I'm trying to write the fastest server possible but it doesn't have to do much.
11:12:07 <fizzie> There's the Linux-only trick for playing around with splice/vmsplice to do no-userspace-copy socket-to-socket or file-to-socket (though for the latter there's the far easier-to-use sendfile, of course) stuff you can do if you pretend to be interested in performance, but that's not appilcable if what you're feeding is locally programmatically computated stuff.
11:12:27 <fizzie> APPIL CABBEL.
11:12:53 <elliott_> fizzie: It's read from socket -> process -> send directly back from filesystem.
11:13:37 <elliott_> So ostensibly, epoll, process as efficiently as possible, sendfile, repeat.
11:24:02 -!- monqy has quit (Quit: hello).
11:24:26 <elliott_> Gregor: BTW, what's with the srand random in umlbox?
11:29:54 <fizzie> Based on a glance, it looks like it wants to give a different seed for each handleRun-forked process.
11:30:53 <elliott_> Heh :P
11:35:11 <fizzie> Funnily, if it were a "use given seed directly as if it was the last output, no state larger than the returned value" RNG, srandom(random()) would be just as useful as a single random() and would just start each process one value later in the sequence. But random() has a large table of state and presumably does something else.
11:35:29 -!- elliott_ has quit (Read error: Connection reset by peer).
11:35:32 -!- elliott has joined.
11:41:10 <fizzie> `run echo -e '#include <stdlib.h>\n#include <stdio.h>\n int main(void) { int i,j; char states[4][128]; for(i=0; i<4; i++) initstate(random(), states[i], 128); for(i=0; i<4; i++) { setstate(states[i]); for(j=0; j<6; j++) printf(" %ld",random()%100); printf(" -"); } return 0; }' | gcc -xc -o ./tmp.tmp - ; ./tmp.tmp
11:41:12 <HackEgo> 98 75 6 22 99 12 - 24 54 86 60 0 74 - 36 83 15 19 16 6 - 50 3 47 38 76 55 -
11:41:21 <fizzie> Seems to create quite independent-looking sequences.
11:49:51 <elliott> fizzie: So have I mentioned that @ has no kernel<->userspace overhead at all and so its IO model is simple and fast because, and I don't think everyone quite knows this yet,
11:49:55 <elliott> @ IS THE BEST FUCKING THING EVER
11:51:19 <fizzie> `run echo -e '#include <stdlib.h>\n#include <stdio.h>\n#include <math.h>\n int main(void) { int i,j; unsigned short states[4][3]; for(i=0; i<4; i++) { unsigned long long u=drand48()*pow(2,48); states[i][0] = u; states[i][1] = u>>16; states[i][2] = u >> 32; } for(i=0; i<4; i++) { seed48(states[i]); for(j=0; j<6; j++) printf(" %ld",lrand48()%100); printf(" -"); }}' | gcc -xc -o ./tmp.tmp - ; ./tmp.tmp
11:51:22 <HackEgo> 18 95 86 66 96 89 - 95 86 66 96 89 21 - 86 66 96 89 21 12 - 66 96 89 21 12 46 -
11:51:31 <fizzie> That one's not so clever.
11:51:51 <fizzie> (If you go to the trouble of actually extracting the internal 48-bit state, anyway.)
11:52:22 <elliott> Enjoying yourself, are we
11:52:28 <fizzie> But of course!
11:52:36 <fizzie> Butt, of course.
11:53:01 <elliott> You should ask me to explain how @ avoids ALL kernel<->userspace overhead and therefore can do IO perfectly in every direction and whichway because yes??????
11:53:05 <elliott> EVERYONE SHOULD ASK ME THAT
11:54:14 <Deewiant> I'll ask you when you've implemented it
11:54:45 <fizzie> I've seen you blab something about not having any kernel/userspace split at all because everything is oh-so-safe whee, I just, you know, assumed. Also what he said.
11:55:11 <elliott> Deewiant: I'm working on that, dude :P
11:55:30 <elliott> It's not like there's any amazingly hard problem I have to solve to implement it
11:55:45 <elliott> It's just that there's a bunch of things I haven't fully specified yet that affect the design of other components in a major way
11:56:56 <elliott> Deewiant: But you're free to help, if you're so eager to see it implemented :-)
11:57:52 <Deewiant> Other than getting yourself motivated
11:58:46 <elliott> I'm perfectly motivated to write @, but I don't see the point in starting on an implementation that I know will fail (in a much stronger sense than "build one to throw away")
11:58:49 <cheater_> Deewiant is lazy functional.
12:11:21 -!- PatashuWarg has quit (Ping timeout: 240 seconds).
12:14:58 <elliott> `addquote <Taneb> Maybe if you try diplomacy. <Taneb> Pointy steel diplomacy
12:15:00 <HackEgo> 593) <Taneb> Maybe if you try diplomacy. <Taneb> Pointy steel diplomacy
12:37:17 <CakeProphet> is it possible to run Firefox with a different layout engine?
12:50:02 <Deewiant> Why do I always end up with a bunch of functions with 8 or more parameters
12:50:05 <fizzie> It used to be possible to run some version of Netscape (8?) with IE's "Trident" engine on Windows.
12:50:58 <elliott> Deewiant: In which language
12:51:05 <Deewiant> In all languages
12:51:08 <Deewiant> In this case, C
12:51:25 <elliott> Deewiant: If C: Because you don't have enough structs, or aren't separating things out into separate initialisation procedures
12:51:37 <elliott> Deewiant: If Haskell: Because you fail at building combinator libraries
12:51:50 <Deewiant> What do you mean by initialisation procedures
12:53:46 <elliott> Yeah, that wasn't very explicit, I just mean that instead of doing an entire operation as one atomic procedure, you can factor it out into initialising a state, repeatedly applying some action to it, and then destructing it
12:53:59 <elliott> If that doesn't make any sense, then it's not the right advice for the situation :-P
12:55:14 <elliott> Deewiant: What procedure is it, anyway
12:55:33 <Deewiant> It's not a "procedure", it's "a bunch of functions"
12:55:44 <elliott> Well, what's the one with the most parameters :-P
12:56:26 <Deewiant> Let's see, it's probably the one that wishes it were a nested function
12:56:40 <elliott> Questioning your API design at this point
12:57:05 <Deewiant> Hey, my public API is minimal
12:57:48 <elliott> What is it :-P
12:57:57 <Deewiant> What it
12:58:04 <Taneb> A third-person neuter pronoun
12:58:05 <elliott> Your public API, I'm being a horrible sceptic
12:58:14 <Taneb> But that's not important
12:59:09 <elliott> Taneb: Why'd you give a peasant a fancy bed anyway
12:59:22 <Deewiant> allocate(void*, stats*) free(space*) get(space*, coords) put(space*, coords, cell) load_string(space*, char*, size_t, coords, coords*, bool) modulo names/const/etc
12:59:26 <Taneb> I did? What?
12:59:35 <Deewiant> + the cursor stuff I haven't done yet
12:59:47 <elliott> Deewiant: load_string is strictly superfluous ;-)
13:00:13 <Deewiant> Well, depends on how you define "minimal"
13:00:40 <Deewiant> free is also strictly superfluous :-P
13:01:02 <elliott> Deewiant: If you're going to be all performance-minded like that, you should at least offer a way to get/set in bulk :P
13:01:13 <elliott> Like "copy this two-dimensional array in/out"
13:01:21 <Deewiant> Oh yeah, I do
13:01:33 <Deewiant> I forgot about those, they're not in the .h yet
13:01:39 <elliott> I'm a genius
13:01:59 <Taneb> I'm a genus
13:02:06 <Deewiant> Or, even better, the required wrappers aren't in the .c either
13:02:11 <elliott> Deewiant: Show some fun internal function signatures then :P
13:03:08 <Deewiant> But, uh, those would look like map(coords, coords, void(*)(cell*, size_t, stats*)) and map_no_alloc(coords, coords, void(*)(cell*, size_t, stats*), void(*)(size_t)) I think
13:03:29 <elliott> Deewiant: That's... not the most efficient API I can think of :P
13:03:42 <Deewiant> Do tell
13:03:51 <elliott> Deewiant: Weeeeeell, I have a natural aversion to function pointers
13:04:00 <elliott> I'd just make it take a pointer and have it basically be a blit
13:04:10 <Deewiant> I have a natural aversion to copying when it's not necessary
13:04:13 <elliott> Sure, you end up "iterating twice" if you're going to for over it afterwards, but the constants are low
13:04:25 <Deewiant> You might be doing a search or whatever
13:04:26 <elliott> Deewiant: You don't need to copy if it's contained within a region boundary
13:04:51 <Deewiant> You'd have it return the pointer?
13:05:03 <Deewiant> In any case, that requires copying in the general case :-P
13:05:21 <elliott> Deewiant: Yeah; and so what, just say "This will be slow unless [conditions]" ;-)
13:05:31 <Gregor> <elliott_> Gregor: BTW, what's with the srand random in umlbox? // I only use the randomness within a fork(), so if I don't reseed it before every fork, I'll get the same random numbers every time.
13:05:42 <Deewiant> I'd rather say "this will be fast always"
13:06:01 <elliott> Gregor: Right.
13:07:02 <elliott> Deewiant: You still haven't supplied any internal signatures ;-)
13:07:09 <elliott> WE WILL FIND OUT
13:07:10 <elliott> ONE WAY
13:07:10 <elliott> OR
13:07:11 <elliott> ANOTHER
13:07:39 <Deewiant> static bool mushspace_newline(bool*, mushcoords*, mushcoords, mush_aabb*, size_t, size_t*, size_t*, mushcoords, size_t*, uint8_t*);
13:07:47 <Deewiant> As I thought
13:07:53 <Deewiant> The one that wants to be nested
13:09:09 <elliott> Gross, remind me to put shiro-lahey on Hackage before you get that out
13:09:27 <elliott> "Generalised N-dimensional Lahey spaces with an efficient unboxed representation"
13:09:33 <elliott> People might even mistake it for something useful
13:09:50 <Deewiant> I have a macro for calling that
13:09:56 -!- derrik has joined.
13:10:05 <Taneb> Why are there four size_ts?
13:10:18 <Deewiant> static bool mushspace_newline(
13:10:18 <Deewiant> bool* got_cr, mushcoords* pos, mushcoords target,
13:10:18 <Deewiant> mush_aabb* aabbs, size_t aabbs_len, size_t* a, size_t* max_a,
13:10:18 <Deewiant> mushcoords last_nonspace, size_t* found_nonspace_for, uint8_t* get_beg)
13:11:13 <Deewiant> 10 parameters and 13 non-blank lines of code
13:12:43 <elliott> Deewiant: You should really have a (T *, size_t) pair
13:12:55 <Deewiant> Yeah I probably should
13:13:07 <Deewiant> It'd take this from 10 to 9!
13:13:19 <elliott> #define DECL_BUFFER(T) typedef {size_t size; T *data;} T##_buffer
13:13:20 <elliott> :P
13:13:41 <elliott> Deewiant: "size_t* a, size_t* max_a" also makes me suspicious
13:13:52 <Deewiant> Howso
13:13:57 <elliott> Could be a struct :-P
13:13:58 <elliott> Deewiant: Also "mushcoords" vs. "mush_aabb" vs. "mushspace_" -- get some consistency
13:14:21 <Deewiant> mushspace_ is the module, mush_ is internal, mush is external
13:14:44 <elliott> Deewiant: The distinction between the latter two is confusing :P
13:14:45 <Deewiant> elliott: I don't want to make a struct to be used by exactly one function
13:14:57 <Deewiant> You don't need to care, you're a user, you'll only see mush
13:15:04 <Taneb> http://en.wikipedia.org/wiki/Nazi_talking_dogs
13:15:04 <elliott> Sorry for commenting on your code :P
13:15:18 <Deewiant> No worries dude :-P
13:15:44 <elliott> Deewiant: Also, I'm offended that the implication that I'd use code with so many parameters
13:15:45 <Deewiant> It's just: mushcell, mushcoords, mushspace, and mushcursor
13:15:58 <Deewiant> Oh, and mushstats
13:16:06 <elliott> Deewiant: So is it N-dimensional
13:16:10 <Deewiant> No
13:16:22 <Deewiant> It's [1-3] selectable at compile time
13:17:04 <elliott> Deewiant: Well then, is it ... uhh, what was that structure I was going to use... R-tree?
13:17:10 <Deewiant> Nope
13:17:14 <Deewiant> No trees here
13:17:17 <elliott> Deewiant: Is it purely-functional?
13:17:32 <elliott> Deewiant: And does it have the words LAHEY SPACE anywhere????
13:17:48 <Deewiant> Does it look purely functional? :-P
13:17:54 <elliott> Deewiant: ALL I AM SEEING ARE FLAWS HERE
13:17:55 <Deewiant> And no, I don't think it does
13:18:05 <Deewiant> Hey, it has 10-parameter functions
13:18:08 <Deewiant> THAT'S A GOOD THING RIGHT
13:18:10 <elliott> Precisely :-P
13:18:24 <elliott> Deewiant: Well if those are a good thing
13:18:38 <elliott> Deewiant: Where's your mergeByteString
13:18:46 <Deewiant> load_string?
13:18:48 <elliott> A function unparalleled in API and implementation consistency
13:18:53 <elliott> Deewiant: No, that's just a function that does the same thing
13:19:03 <elliott> I'm asking, where's your equivalent jewel
13:19:18 <elliott> Deewiant: http://sprunge.us/SATe
13:19:26 <elliott> Deewiant: Where is your FUNCTION OF EQUIVALENT OR GREATER ELEGANCE??????
13:20:21 <Deewiant> I think I'll go with mushspace_newline
13:20:52 <Deewiant> Can't argue with binary arithmetic: *max_a = mush_size_t_max(*max_a, *a |= 0x02);
13:20:57 <elliott> Heh
13:21:08 <elliott> My fungespace representation is really bad :/
13:21:16 <elliott> But I'm trying to clean up the rest of the code first
13:21:25 <elliott> Or any effort will collapse in on itself
13:23:37 <elliott> Also I use String all over the place, I should fix that
13:23:53 <Deewiant> String is good, list-tries supports it
13:24:15 <elliott> Deewiant: Tries are like the only time String has a nice structure :P
13:24:25 <Deewiant> Yup :-P
13:24:37 <elliott> I decided not to like list-tries when I noticed you had completely unnecessarily abstracted the map out ;-)
13:24:52 <Deewiant> It's pretty gross, I know
13:24:54 <elliott> (OK, so for really small alphabets you can avoid map overhead but come oooon.)
13:25:00 <Deewiant> But what's the better alternative
13:25:08 <elliott> Deewiant: Pick one map, force it on everyone
13:25:09 <Deewiant> It was more about being able to use Eq/Ord/whatever keys
13:25:12 <Deewiant> I don't want that
13:25:17 <elliott> I want that
13:25:23 <Deewiant> "force X on everyone" is something I abhor :-P
13:25:38 <elliott> It's called a library, if you didn't force something on everybody it'd be empty
13:26:05 <elliott> Let's put it this way: There is no way that that Map class can lead to anything good :-P
13:26:44 <elliott> Deewiant: How about just using a type family
13:26:45 <Deewiant> It leads to being able to use keys without Ord instances while not having to use linked lists for maps in general
13:26:49 <elliott> Deewiant: How about just using a type family
13:26:56 <Deewiant> Type families were pretty experimental when I started it
13:27:00 <elliott> They're not now
13:27:00 <Deewiant> Nobody was using them
13:27:03 <Deewiant> Yeah so
13:27:07 <Deewiant> elliott: How about just rewriting it
13:27:19 <elliott> Deewiant: But someone's already roped me into one bit of work today :-(
13:27:38 <elliott> It's child labour
13:28:08 <Deewiant> In the meanwhile you can live with it
13:28:15 <elliott> Bug report
13:28:15 <elliott> -- 'Just'@ a@is returned, the old value is replaced with @a@. If the key is
13:28:26 <elliott> And yeah, I'll live with it by not using it :-P
13:29:12 <Deewiant> There's also an \ue000 between the @ and the is, somehow
13:29:25 <elliott> That's the bug report
13:29:44 -!- derrik has left.
13:29:46 <elliott> Hmm, I'm not sure type instances would actually work
13:29:47 <elliott> Or, well
13:30:04 <elliott> They might, actually
13:30:12 <elliott> (Map k) => ...
13:30:17 <elliott> class Map k where type MapFor k
13:30:19 <elliott> Hmm
13:30:32 <elliott> Dammit, now you've got me pondering :-P
13:30:38 <Deewiant> heh
13:30:44 <elliott> Deewiant: Heeeeey, technically I _am_ a user of list-tries.
13:30:50 <Deewiant> GPipe, yes
13:30:58 <elliott> CHAINSAW TIME
13:31:03 <Deewiant> :-P
13:31:37 * elliott promptly gets himself stuck on whether "class HasMap k where type Map k" or "class Map k where type MapFor K" is nicer, conveniently uses this to drop the whole thing.
13:31:53 <Deewiant> Bikeshedding is annoying like that
13:32:22 <elliott> Which is nicer, I'll just pick the opposite of whatever you say, problem solved
13:32:34 <Deewiant> HasMap
13:32:36 <elliott> Is this three space indentation good lord
13:32:45 <Deewiant> Yep
13:32:51 <elliott> I don't like you :(
13:32:53 <fizzie> Incidentally, why do we only have +cn? All the *real* channels have something like +CLPcfjnt on. (Okay, so you need freenode admins for +LP, but...)
13:32:54 <Deewiant> :-(
13:33:08 <elliott> fizzie: Both +c and +n are bad modes for bad people
13:33:10 <elliott> Can we remove them
13:33:11 <Deewiant> We don't have +t because people like to change the topic
13:33:22 <Deewiant> And I don't know what the others do
13:33:39 <Deewiant> What's wrong with three space indentation
13:33:39 <fizzie> +j is join-throttling, only N joins in M minutes.
13:33:51 <elliott> +c filters colours and also bold.
13:33:54 <fizzie> +f forwards the +j-throttled to other channels.
13:33:56 -!- sllide has joined.
13:33:58 <elliott> +n stops people sending a message when outside the channel.
13:34:01 <elliott> Oh wait
13:34:04 <elliott> You're asking about fizzie's
13:34:05 <fizzie> +C filters to-channel CTCPs.
13:34:07 <elliott> Im smart
13:34:24 <fizzie> And +LP are large-ban-lists + permanent.
13:34:49 <Deewiant> When admins start wondering why so few people have been banned, worry
13:34:52 <elliott> Deewiant: Three-space indentation is just weird because it is
13:35:01 <elliott> Powers of two are the only good indentation widths
13:35:07 <Deewiant> 2 is too narrow, 4 is too wide
13:35:17 <elliott> Two is fine for Haskell code
13:35:30 <elliott> The nesting is shallow in idiomatic code, and the left-side rule means that you get more indentation than that
13:35:32 <Deewiant> Maybe, I haven't thought about it per-language
13:35:42 <elliott> e.g. " where " is actually an eight-char indentation, really
13:36:14 <Deewiant> Yeah but I often write that as " where\n<indentation>"
13:36:24 <elliott> Well that's bad :)
13:36:28 <Deewiant> If a lot of stuff follows it
13:36:30 <Deewiant> Well why :-p
13:36:41 <elliott> Because it reads less fluidly and also makes two space worse
13:36:51 <elliott> Deewiant: Do you really use all the functions in the Map class
13:36:55 <Deewiant> I think of "where" as invisible
13:36:56 <Deewiant> Yes
13:36:58 <elliott> Wow
13:37:10 <Deewiant> It started out smaller :-P
13:37:13 <elliott> Don't you think putting some of them outside the class would have a certain... elegance
13:37:28 <Deewiant> They all have direct implementations in Map/IntMap IIRC
13:37:28 <elliott> I mean, how would you optimise mapAccum to be faster than the obvious implementation in terms of mapAccumWithKey :-P
13:37:43 <elliott> Yeah, but those implementations will probably reduce to basically the same thing as the obvious transformation...
13:38:01 <Deewiant> mapAccum on a trie doesn't need to remember the key
13:38:57 <elliott> Heh
13:39:11 <Deewiant> Most of them are probably there because my trie API was just union(Data.Map, Data.IntMap) and it turns out that you need mapAccum to implement mapAccum (or whatever)
13:39:27 <elliott> Data.Map.Map seems like a really bad default choice to use
13:39:38 <elliott> I mean, compared to something hash-based
13:39:45 <elliott> Where the hash for Char helpfully reduces to id
13:39:59 <Deewiant> There's no "default choice"?
13:40:15 <elliott> Well, OK, I just mean that you provide instances for Map :-P
13:40:17 <Deewiant> You pick by type class: Eq, Ord, Enum are provided
13:40:25 <Deewiant> Feel free to add Hashable or whatever :-P
13:40:28 <elliott> Admittedly I was thinking in terms of HasMap which I've actually just created :P
13:41:20 <elliott> Deewiant: If you're such a fan of iteration over conversion followed by traversal, shouldn't you take a traversal function rather than [k] so that you can use Text/ByteString directly :-P
13:41:31 <elliott> That started out as a joke but then it turns out I couldn't answer it oops
13:41:39 <Deewiant> heh
13:41:59 <Deewiant> [k] pretty much is a traversal function in Haskell
13:42:05 <Deewiant> Given laziness and all
13:42:07 <elliott> Yeah, 'strue :P
13:42:47 <elliott> Would Foldable work or something, I don't actually know that family of classes very well
13:42:55 <elliott> I mean, to avoid wrapping it with a bunch of conversions
13:43:37 <Deewiant> What exactly are you talking about now
13:43:45 <Deewiant> Work where, to avoid what
13:44:02 <elliott> As in, everywhere you take a [k]
13:44:14 <elliott> To avoid having to write a ByteStringTrieMap that listifies it
13:44:18 <elliott> For every function
13:45:07 <Gregor> elliott: So how's mudex?
13:45:35 <elliott> Gregor: I haven't touched it much, unfortunately
13:45:40 <elliott> It's CLOSE to working :P
13:45:52 <Deewiant> Traversable might work
13:46:29 <elliott> Deewiant: class ToList k where type Elem k; toList :: k -> [Elem k] would probably work :-P
13:46:34 <Deewiant> I guess Foldable is better because you can use foldr (:) [] to get a list
13:46:45 <elliott> You could even optomize it
13:47:42 <Deewiant> Foldable makes it be x a -> [a] though instead of your x -> [Elem x]
13:47:56 <elliott> Deewiant: Exactly, which is worse, because it doesn't support monomorphic containers
13:48:02 <Deewiant> Yep
13:48:08 <Deewiant> I guess there's no point in caring about non-GHC portability these days? :-P
13:48:13 <elliott> Like, say, ByteString and Text, the most popular third-party string types :-P
13:48:18 <elliott> Deewiant: Dude, you depend on functional dependencies
13:48:19 <Deewiant> Text didn't exist back then
13:48:25 <elliott> Deewiant: Implementing type families is both equivalent and easier :-P
13:48:27 <Deewiant> elliott: It worked in Hugs IIRC
13:48:30 <elliott> Yeah
13:48:31 <elliott> But, I mean
13:48:34 <elliott> Hugs doesn't exist any more :P
13:48:39 <Deewiant> Yeah, and that was my point
13:48:42 <elliott> Well, yeah
13:48:51 <Deewiant> Is there for any practical purpose a non-GHC Haskell implementation
13:49:00 <elliott> jhc
13:49:03 <elliott> But nobody really uses it
13:49:06 <elliott> And it doesn't support much at all
13:49:09 <elliott> I doubt it does fundeps
13:49:10 <Deewiant> Is that semi-up-to-date these days?
13:49:14 <elliott> There's LHC... but that's a backend
13:49:19 <elliott> UHC maybe? Naw
13:49:20 <Deewiant> I know of only UHC
13:49:23 <elliott> Deewiant: Basically, no, there isn't, but there should be one
13:49:33 <Deewiant> As something that is reasonably developed
13:49:35 <elliott> But if there becomes one, it'll probably support type families before fundeps
13:49:40 <Deewiant> Fair enough
13:51:03 <elliott> Deewiant: Pro AList
13:51:27 <elliott> Now I just have to think of a type for which AList is actually desirable so that it doesn't end up with no instances :-P
13:51:37 <elliott> Maybe if your keys are other ALists?
13:51:46 <elliott> Then you're already suffering with ALists
13:51:53 <elliott> So more probably won't hurt much
13:53:07 <Deewiant> AList is if you only have Eq
13:54:00 <elliott> Hmm, the question is how to provide the AList machinery without actually giving it instances
13:54:11 <elliott> That is, you want to be able to just use a line or two to say "hey, use an AList" for this.
13:54:14 <elliott> Aha, hmm
13:54:34 <elliott> Maybe if the Map class was kept as is with the m parameter, and MapFor was a /separate thing/
13:54:37 <elliott> Then the context would become
13:54:41 <elliott> (Map (MapFor k) k) => ...
13:54:42 <elliott> Which is
13:54:44 <elliott> Extremely ugly
13:54:56 <elliott> But the alternative is implementing all the HasMap methods every single time you want to make a type use that map?
13:54:59 <elliott> Which is very stupid
13:55:01 <elliott> Oh wait
13:55:09 <elliott> class Map (MapFor k) k => HasMap k where type MapFor k
13:55:12 <elliott> Deewiant: Genius
13:56:45 <elliott> At this point Deewiant has blocked me on every communication method he can and put notes all around his house to never accept a patch from me ever
13:57:00 <Deewiant> Wrong
13:57:10 <elliott> If by wrong, you mean right
13:58:04 <elliott> That combined Map/HasMap approach seems distinctly unsatisfying, but I'm not sure why...
13:58:56 <Deewiant> Woo, 7 parameters and 7 lines of code (+ 6 for the introduction and closing curly bracket)
13:59:45 <elliott> Deewiant: How many typeclasses :-P
13:59:51 <Deewiant> This is C
13:59:59 <Deewiant> Or are you asking me how many to add
14:00:02 <Deewiant> Or what
14:00:26 <elliott> Deewiant: It was a joke
14:00:33 <Deewiant> It failed
14:00:36 <Deewiant> Clearly
14:00:42 <elliott> Deewiant: No, you're just not refined enough to get it
14:04:50 <elliott> I guess what's really required is... default instances for certain values of a type family
14:04:51 <elliott> Wooooooo
14:05:09 <elliott> class Map (MapFor k) k => HasMap k where type MapFor k is certainly looking appealing
14:05:36 <Deewiant> 2011-08-14 16:33:54 ( Deewiant) HasMap
14:05:38 <Deewiant> I toldya
14:06:01 <elliott> Deewiant: Uh, I decided on HasMap back then
14:06:07 <elliott> Deewiant: It's just that what I did was wrong
14:06:20 <elliott> Deewiant: I changed class Map m k where HOLY GOD SO MUCH STUFF
14:06:20 <elliott> to
14:06:32 <elliott> class HasMap k where type Map k :: asterisk -> asterisk; HOLY GOD SO MUCH STUFF
14:06:39 <elliott> Whereas I actually want it to be
14:06:51 <elliott> class IsMap m where type Key m; HOLY GOD SO MUCH STUFF
14:06:54 <elliott> then later on
14:07:05 <elliott> class IsMap (Map k) => HasMap k where type Map k
14:07:09 <elliott> Hmm, actually
14:07:16 <elliott> class (IsMap (Map k), Key (Map k) ~ k) => HasMap k where type Map k
14:07:23 <elliott> But yeah, that avoids type families :-P
14:07:31 <elliott> And is seemingly as generic as possible
14:07:51 <elliott> And makes saying "oh, Chars should use BlahMap" as simple as "instance HasMap Char where type Map Char = BlahMap Char" if there's a proper IsMap instance
14:08:17 <Deewiant> And makes it impossible for somebody to use a FooMap instead if he wants to? :-P
14:09:44 <elliott> Deewiant: Well, firstly, that's basically the entire tradeoff being made by using a type family; in return there's not an ugly extra parameter going around everywhere. But let's put it this way, I am finding it _very_ hard to think of a situation where you'd have two people thinking a certain map type is best for (element type), and one of them not being wrong :-P
14:09:54 <elliott> Like, for Chars, there's not N usecase strategies or whatever that would suggest different maps
14:10:00 <elliott> There's going to be one map that has the best all-round performance on Chars
14:10:27 <elliott> OK, when your keys are like [[k]] then it gets more complicated, but you probably want that to become a nested TrieMap really
14:10:55 <Deewiant> What if user U has a closed source super map he wants to use but can't be provided by list-tries because it's closed source
14:12:09 <elliott> Deewiant: If the key type is not a "generic" type, then just give the instance directly; else, newtype wrapper -- remember that I'm going to introduce ToList, so actually this isn't a pain
14:12:16 <elliott> Well, it's less of a pain, anyway
14:12:35 <elliott> At the most, you'll need to wrap the functions for convenience as much as you'd have to now to use ByteString or Text
14:12:44 <elliott> And the latter two are far more common than a closed source supermap :-P
14:12:48 <Deewiant> Fair enough I guess
14:12:51 <Deewiant> super map*
14:12:58 <elliott> Duper map
14:13:03 <Deewiant> Souper map
14:13:22 <elliott> Deewiant: Is there a repository of some sort I should clone rather than patching up the latest Hackage release
14:14:31 <Deewiant> git://tar.us.to:9418 I think
14:14:39 <CakeProphet> `run where sh
14:14:41 <HackEgo> sh: where: command not found
14:14:45 <CakeProphet> er
14:14:58 <Deewiant> `run which sh
14:15:00 <HackEgo> ​/bin/sh
14:15:06 <CakeProphet> ah which
14:15:20 <elliott> Deewiant: elliott@katia:~/Code$ git clone git://tar.us.to:9418 list-tries
14:15:20 <elliott> Initialized empty Git repository in /home/elliott/Code/list-tries/.git/
14:15:20 <elliott> fatal: Unable to look up (port 9418) (Name or service not known)
14:15:38 <CakeProphet> for some reason this cmake nonsense isn't finding qmake... but, it's there in /usr/bin
14:15:42 <Deewiant> I don't know how git hosting works, dammit
14:15:45 <Deewiant> I just ran 'git daemon'
14:16:08 <elliott> Guess who else doesn't know :P
14:16:29 <Deewiant> Well your git didn't connect
14:16:32 <elliott> I thought you were an hg guy, anyway
14:16:37 <Deewiant> You thought wrong
14:16:45 <elliott> Deewiant: I think the git:// part was wrong
14:16:55 <elliott> "unable to look up 'space'" is suspicious
14:17:06 <elliott> Aha
14:17:08 <elliott> / makes it closer
14:17:12 <elliott> Deewiant: What's the directory name perchance
14:17:19 <Deewiant> list-tries
14:17:20 <Deewiant> ?
14:17:28 <Deewiant> I ran it in the list-tries directory
14:17:29 <elliott> elliott@katia:~/Code$ git clone git://tar.us.to:9418/list-tries.git list-tries
14:17:30 <elliott> Initialized empty Git repository in /home/elliott/Code/list-tries/.git/
14:17:30 <elliott> fatal: The remote end hung up unexpectedly
14:17:30 <elliott> elliott@katia:~/Code$ git clone git://tar.us.to:9418/list-tries list-tries
14:17:30 <elliott> Initialized empty Git repository in /home/elliott/Code/list-tries/.git/
14:17:30 <elliott> fatal: The remote end hung up unexpectedly
14:17:32 <elliott> Meh
14:17:34 <Deewiant> So it would make sense if it were /
14:17:38 <elliott> Deewiant: I think you need to do "git daemon list-tries" in the parent?
14:17:45 <elliott> And /.git and / both failed too
14:18:10 <elliott> Prepare the repository
14:18:10 <elliott> To allow git-daemon to read your project you have to add the file .git/git-daemon-export-ok to your project.
14:18:12 <elliott> Deewiant: lawl
14:18:23 <CakeProphet> so for some reason /usr/share/cmake-2.8/Modules/FindQt4.cmake can't find qmake...
14:18:34 <CakeProphet> which means it's stupid because it's in /usr/bin
14:20:39 <Deewiant> elliott: Okay I gave it --base-path=. and now it should maybe work
14:21:20 <elliott> /.git worked, thanks
14:21:27 <Deewiant> You didn't need that methinks
14:21:32 <Deewiant> It worked locally with just /
14:21:48 <elliott> -- Funky instances for this type are marked with **FUNKY**
14:21:48 <elliott> I don't even want to know
14:23:44 <elliott> Deewiant: I note that the Map typeclass is not sufficiently general to handle a map that has constraints on the values :-P
14:23:56 <elliott> I'm sure this issue has you quaking in your boots
14:24:28 <Deewiant> Feel free to fix it
14:25:27 <elliott> Deewiant: No thanks, that would even lose Traversable :-P
14:26:01 <Deewiant> Yeah, fix the base libraries first ;-)
14:26:45 <elliott> Deewiant: I'm not sure "fix" = "make more general"
14:27:09 <Deewiant> It always is
14:27:16 <elliott> Deewiant: Here's my new Prelude:
14:27:28 <elliott> something :: c a -> d b
14:27:39 <elliott> Specialise c=d=Identity for normal operations
14:27:49 <Deewiant> Like unsafeCoerce
14:28:04 <elliott> Deewiant: No, that's what the d on the return is there for, so it can refuse
14:28:18 <elliott> How does it know how to refuse in d? Well simple, it uses something
14:28:22 <Deewiant> :-D
14:29:53 * elliott wonders whether changing Map to have the key as a type family actually simplifies things.
14:30:07 <elliott> Hmm, it does
14:30:17 <elliott> instance (Ord k) => IsMap (Map k)
14:30:18 <elliott> Well, hmm, no
14:30:32 <elliott> Just because it's a Report-compliant instance head doesn't mean you're not going to use an extension the next line by necessity
14:30:42 <elliott> Oh, wait, it is useful
14:30:49 <elliott> instance IsMap (a,a) where
14:30:54 <elliott> type Key (a,a) = Bool
14:30:58 <elliott> Deewiant: Ain't it beautiful :-P
14:31:12 <elliott> You couldn't do that before without a newtype wrapper.
14:31:41 <Deewiant> Because a mostly-internal newtype wrapper is just so terrible :-P
14:32:29 <elliott> Deewiant: Well, if you'd like to turn FunctionalDependencies into FunctionalDependencies _and_ TypeFamilies rather than replacing it, I'm happy to oblige :-P
14:32:41 <elliott> I suppose, uh, depending on the mtl already implies FunctionalDependencies, though
14:32:52 <Deewiant> :-D
14:32:55 <Deewiant> Whoops
14:33:46 <elliott> OK, here's what shiznit be up, yo: I'm way too lazy to s/k/Key m/ and the like so I'm just going to rename Map and OrdMap to have Is in front :-P
14:33:52 <elliott> Hmm
14:33:56 <elliott> class Foldable (m k) => IsMap m k where
14:33:59 <elliott> Deewiant: What's with the missing fundep
14:34:23 <Deewiant> Maybe you dropped it somewhere
14:34:25 <elliott> Nope
14:34:33 <elliott> You just didn't have one
14:34:35 <elliott> Clever
14:34:43 <Deewiant> Why fundep when the code compiles without it eh
14:35:16 <elliott> Deewiant: I'd love to see an instance violating m -> k
14:35:19 <elliott> By love I mean auuuuuuuuugh
14:35:23 <elliott> Maybe if you use like
14:35:26 <elliott> Map Dynamic a
14:35:32 <elliott> Or, well, AList Dynamic a
14:35:37 <Deewiant> It's possible!!
14:35:47 <elliott> NOT IN A GOD-FEARING SOCIETY
14:36:04 <Deewiant> Kids these days will do anything
14:36:29 <elliott> newtype WrappedIntMap k v = IMap (IM.IntMap v) deriving (Eq,Ord)
14:36:29 <elliott> Hmm, what's with the wrapping
14:36:37 <Deewiant> Dropping k
14:36:42 <elliott> Oh
14:36:45 <elliott> That
14:36:56 <CakeProphet> okay so I figured out the qmake stuff, but now it can't find qt4-core...which is also installed.
14:36:58 <elliott> Deewiant: Is a damn good argument not to use m k all over the place :P
14:37:00 <CakeProphet> WHAT IS GOING ON AAAH
14:37:06 <elliott> Actually I can do that while keeping the fundep
14:37:07 <CakeProphet> I think I hate cmake.
14:37:11 <elliott> Just make it become
14:37:17 <elliott> instance IsMap (IntMap v) Int
14:37:18 <elliott> vs.
14:37:23 <elliott> instance IsMap (M.Map k v) k
14:37:26 <elliott> Erm
14:37:28 <elliott> instance IsMap (M.Map k) k
14:37:29 <elliott> vs
14:37:33 <elliott> instance IsMap IntMap Int
14:39:33 <elliott> Deewiant: Holy shit, right after you say that I violate the fundep
14:39:37 <elliott> instance Enum k => IsMap IM.IntMap k where
14:39:43 <elliott> Are you a wizard?????????????????????
14:40:07 <Deewiant> I'm waiting for my "auuuuuuuuugh"
14:40:22 <elliott> >_>
14:40:36 <CakeProphet> I am "auuuuuuuugh"ing as we speak
14:40:46 <Deewiant> I guess that's acceptable
14:41:26 <CakeProphet> cmake keeps telling me to check a CMakeError.log
14:41:29 <CakeProphet> that doesn't exist.
14:41:31 <CakeProphet> THANKS CMAKE
14:41:33 <CakeProphet> I HATE YOU
14:41:35 <elliott> Why are you using CMake
14:41:39 <elliott> It's almost as bad as SCons
14:41:41 <CakeProphet> because I have to.
14:41:47 <elliott> Why
14:41:48 <CakeProphet> because this isn't my software that I'm trying to install.
14:41:53 <elliott> Stop using that software
14:41:54 <Deewiant> CMake is okay
14:41:55 * CakeProphet is install Qyoto
14:41:59 <CakeProphet> +ing
14:42:01 <olsner> rewrite it and make it your software
14:42:08 <CakeProphet> .....yeah okay I'll get right on that.
14:42:09 <Deewiant> The elliott way of doing things
14:42:14 <elliott> Deewiant: So what's with the random double/triple spaces everywhere, it looks like you once aligned osmething but then there was nothing to align
14:42:16 <CakeProphet> since I have like 4 days to finish this. should be easy.
14:42:17 <olsner> at least you can rewrite the cmake part
14:42:39 <Deewiant> elliott: Is this before or after you've run a s/x/y/ expression on it
14:42:57 <elliott> Deewiant: I've run no such thing
14:42:59 <Deewiant> Or you just not seeing the genius of my indentation/alignment
14:43:02 <elliott> Consider the "alter" method in the IntMap instance
14:43:15 <elliott> Or how about this
14:43:19 <elliott> toAscList :: m k a -> [(k,a)]
14:43:19 <elliott> toDescList :: m k a -> [(k,a)]
14:43:23 <elliott> In a completely standalone block
14:43:37 <CakeProphet> basically the guy who hired me said "use qtwebkit to make a small proof of concept for Mono/C#"
14:43:45 <CakeProphet> well...qtwebkit is in FUCKING C++
14:43:47 <Deewiant> Okay that's random
14:44:05 <CakeProphet> so... I had to go find some C# bindings, which I did, and it's called Qyoto. And now I am trying to install this and it is not finding shit.
14:44:08 <Deewiant> alter is aligned with update/adjust/delete?
14:44:09 <CakeProphet> that is obviously there.
14:44:25 <elliott> Deewiant: Is it even aligned
14:44:27 <elliott> It is after my modification
14:44:32 <elliott> But I don't recall before
14:44:35 <Deewiant> I can't find an alter that isn't
14:44:40 <elliott> Fair enough
14:44:45 <elliott> Still weird :-P
14:45:01 <Deewiant> delete k (IMap m) = IMap$ IM.delete (fromEnum k) m
14:45:01 <Deewiant> alter f k (IMap m) = IMap$ IM.alter f (fromEnum k) m
14:45:06 <Deewiant> I assumed you were referring to that
14:45:09 <elliott> Yeah
14:45:12 <Deewiant> And that's aligned
14:45:12 <elliott> Now insert a blank line after delete
14:45:14 <elliott> And it stops making any sense :-P
14:45:18 <Deewiant> Yeah there's a blank line
14:45:19 <Deewiant> It's still aligned :-P
14:45:42 <Deewiant> The blank lines are based on the grouping in the definition of Map methinks
14:45:48 <elliott> :t second specialise it on (->) you ashole
14:45:49 <lambdabot> parse error on input `->'
14:45:53 <elliott> : tufuck you
14:45:57 <elliott> :t second
14:45:58 <lambdabot> forall (a :: * -> * -> *) b c d. (Arrow a) => a b c -> a (d, b) (d, c)
14:46:03 <elliott> :t i hat eyou and i hate arrows
14:46:04 <lambdabot> Not in scope: `hat'
14:46:05 <lambdabot> Not in scope: `eyou'
14:46:05 <lambdabot> Not in scope: `hate'
14:46:13 <Deewiant> second :: (a -> b) -> (c, a) -> (c, b)
14:46:26 <CakeProphet> I hate cmake
14:47:53 <CakeProphet> Warning: QT_QMAKE_EXECUTABLE reported QT_INSTALL_LIBS as /usr/lib
14:47:55 <CakeProphet> Warning: But QtCore couldn't be found. Qt must NOT be installed correctly, or it wasn't found for cross compiling.
14:48:06 <CakeProphet> must NOT be installed correctly. it has nothing to do with cmake being terrible.
14:48:09 <CakeProphet> nope.
14:48:26 <Deewiant> You're all such haters
14:48:43 <CakeProphet> all we do is hate.
14:49:07 <CakeProphet> time to go manually install libqt4-core
14:50:01 <elliott> ?unpl Just . first toEnum *** IMap
14:50:02 <lambdabot> (\ c -> (Just) (((first toEnum) *** (IMap)) c))
14:50:06 <elliott> Not fucking helpful
14:50:31 <Deewiant> Are you having trouble?
14:50:33 <olsner> so it needs Qt to NOT be installed correctly?
14:50:39 <elliott> Deewiant: Just this bit :P
14:50:39 <CakeProphet> yes.
14:50:42 <CakeProphet> or, maybe
14:50:43 <CakeProphet> I have no idea.
14:50:53 <CakeProphet> actually libqt4-core is a transitional package so it might be the wrong one.
14:51:01 <CakeProphet> so maybe I actually hate Debian's package repos.
14:51:03 <Deewiant> \(a,b) -> (Just (first toEnum a), IMap b)
14:51:20 <elliott> So (Just . first toEnum *** id), then
14:51:22 <olsner> you should just need libqt4-dev I think
14:51:34 <Deewiant> elliott: f *** id is the same thing as first f
14:51:55 <elliott> Data/ListTrie/Base/Map.hs:196:21:
14:51:55 <elliott> Ambiguous type variable `k10' in the constraint:
14:51:55 <elliott> (IsOrdMap m k10) arising from a use of `mapAccumDescWithKey'
14:51:55 <elliott> Probable fix: add a type signature that fixes these type variable(s)
14:51:55 <elliott> In the expression: mapAccumDescWithKey (const . f)
14:51:55 <elliott> In an equation for `mapAccumDesc':
14:51:57 <elliott> mapAccumDesc f = mapAccumDescWithKey (const . f)
14:51:59 <elliott> Dude what...
14:52:01 <elliott> Oh
14:52:03 <elliott> Hmm
14:52:05 <elliott> Hmmmmmmmmmmmmmmmmmmmmmmm
14:52:17 <olsner> MR? :)
14:52:23 <elliott> olsner: nope, it's a typeclass default
14:52:28 <Deewiant> elliott: You should add a type signature that fixes these type variable(s)
14:52:29 <elliott> but
14:52:32 <elliott> Deewiant: Guess what we need
14:52:38 <elliott> We need the functional dependency
14:52:39 <Deewiant> A type signature that fixes these type variable(s)
14:52:43 <elliott> Dude
14:52:44 <elliott> No
14:52:49 <CakeProphet> oh hey look libqt4-dev is uninstalled
14:52:50 <Deewiant> But that's what it says
14:52:55 <olsner> "Probable fix: add a type signature that fixes this type error"
14:52:57 <elliott> "Probable fix"
14:53:03 <elliott> It's a TYPECLASS DEFAULT
14:53:04 <Deewiant> When is GHC ever wrong?
14:53:26 <elliott> Deewiant: Hey, I've internal exception'd GHC before, whippersnapper
14:53:30 <CakeProphet> Probable fix: add an unsafeCoerce that fixes this type error.
14:53:40 <Deewiant> I think I have, as well
14:54:03 <Deewiant> elliott: That doesn't mean it wasn't the right way to handle the situation
14:54:19 <elliott> ..............There is exactly one signature and it is ALREADY THERE
14:54:25 <elliott> The problem is an ambiguity caused by the lack of the fundep
14:54:28 <Deewiant> I meant the internal exception
14:54:34 <elliott> Oh
14:54:36 <elliott> It most definitely was wrong
14:54:48 <CakeProphet> CMake Error at CMakeLists.txt:88 (macro_log_feature): Unknown CMake command "macro_log_feature".
14:54:51 <CakeProphet> awesome
14:55:00 <elliott> Deewiant: http://sprunge.us/DJca
14:55:04 <elliott> Deewiant: GHC bomb at least as of a while ago
14:55:32 <Deewiant> arst.hs:31:18:
14:55:32 <Deewiant> Cannot deal with a type function under a forall type:
14:55:32 <Deewiant> forall fp. Fingerprint fp => (fp, FPGlobalState fp)
14:55:32 <Deewiant> In the expression: return ()
14:55:32 <Deewiant> In an equation for `fpRun': fpRun NULL _ = return ()
14:55:35 <Deewiant> In the instance declaration for `Fingerprint NULL'
14:55:36 <elliott> Me too
14:55:39 <elliott> It was in ghc six days
14:56:00 <elliott> As in, months ago :-P
14:56:24 <CakeProphet> so apparently I need libsmokeweroidofihwerhsomething
14:56:36 <elliott> Deewiant: BTW, I don't think the Map classes are generic enough to handle a dependent map :-P
14:56:50 <elliott> JUST SAYING
14:56:53 <Deewiant> Again, if you can fix it, go ahead :-P
14:57:08 <elliott> I don't think I can :P
14:57:13 <elliott> Illegal instance declaration for `IsMap IM.IntMap k'
14:57:13 <elliott> (the Coverage Condition fails for one of the functional dependencies;
14:57:13 <elliott> Use -XUndecidableInstances to permit this)
14:57:16 <elliott> Deewiant: Best extension?????????????
14:57:25 <Deewiant> Yeah no
14:57:53 <elliott> How can I revert just all the lines that previously said IMap :-P
14:58:27 <Deewiant> If you have vim and haven't mapped U to something else, U undoes changes on one line
14:58:47 <elliott> Great; now assume I have emacs
14:58:53 <Deewiant> RTFM
14:58:58 <cheater_> you're pretty much fucked.
14:58:59 <elliott> I was thinking more along the lines of some fancy git reset tool :-P
14:59:06 <Deewiant> My knowledge of emacs is limited to C-x C-c and I'm not even sure that's right
14:59:29 <cheater_> Deewiant, that seems to be all the knowledge you need of it
14:59:36 <Vorpal> vim fanatics
14:59:42 <Deewiant> Another hater
14:59:51 <elliott> Vorpal: points to the sign marked "don't feed the troll"
15:00:02 <olsner> which sign? there is no such sign here
15:00:03 <Vorpal> elliott, oh, good point
15:00:09 <elliott> Holy shit, excite.com still exists
15:00:11 <elliott> And looks identical
15:00:35 <Vorpal> elliott, what is it? I just get a 500 there
15:00:44 <cheater_> at least it didn't go down with altavista
15:01:20 <elliott> Vorpal: http://www.excite.com/ should load
15:01:37 <Vorpal> elliott, tried it. 500 still
15:01:43 <elliott> Huh
15:01:47 <elliott> It's a really 90s web portal :)
15:01:47 <CakeProphet> okay so now it can't find smoke, but I've installed libsmokeqt4-dev
15:01:51 <CakeProphet> which should have installed everything I need.
15:02:11 <Vorpal> elliott, oh I see, I selected to NOT disallow the cookie, then it stopped doing 500
15:02:11 <CakeProphet> I think
15:02:42 <cheater_> CakeProphet, he's in the trapping grounds west of the village, opposite side to the temple of trials. you have to kill some geckos and watch out not to step into the pools of acid, that's a bit of HP gone every time you do that.
15:03:11 * cheater_ wonders if anyone got the reference.
15:03:32 <CakeProphet> it's lost to me
15:04:03 <elliott> minMaxView :: (Alt st a, Boolable (st a), Trie trie st map k)
15:04:03 <elliott> => (trie map k a -> Bool)
15:04:03 <elliott> -> (CMap trie map k a -> Maybe (k, trie map k a))
15:04:03 <elliott> -> trie map k a
15:04:03 <elliott> -> (Maybe ([k], a), trie map k a)
15:04:07 <elliott> Deewiant: Nice
15:04:22 <Deewiant> 2011-08-14 15:51:22 ( Deewiant) Why do I always end up with a bunch of functions with 8 or more parameters
15:04:34 <elliott> Because you suck :-P
15:04:37 <CakeProphet> cmake wants me to set a bunch of stupid configuration variables and I'd really rather not since that's probably not the problem.
15:04:39 <Deewiant> Meh :-(
15:05:07 <cheater_> http://fallout.wikia.com/wiki/Rescue_Nagor%27s_dog,_Smoke,_from_the_wilds
15:05:21 <elliott> Deewiant: I bet if I got Conal to reimplement list-tries... ;-)
15:05:36 <elliott> THREE LINES OF CODE SO PURE THEY DON'T EVEN EXECUTE AT RUNTIME
15:05:50 <Deewiant> BANANAS EVERYWHERE
15:06:13 <elliott> The three lines of code
15:06:18 <elliott> banana :: Banana -> Banana
15:06:21 <elliott> banana v
15:06:28 <elliott> | isBanana v = banana v
15:06:43 <elliott> | otherwise = ex (banana v) (re (banana v))
15:06:47 <elliott> Beautiful
15:06:52 <cheater_> > let na = "na" ++ na in "Ba" ++ na
15:06:54 <lambdabot> "Banananananananananananananananananananananananananananananananananananana...
15:07:00 -!- copumpkin has joined.
15:07:59 <Vorpal> elliott, that is 4 lines (with the type signature)
15:08:14 <elliott> Vorpal: There's another line of negative space above
15:08:19 <elliott> You just can't see it with your stateful IRC client
15:08:19 <Vorpal> elliott, oh right
15:08:35 <olsner> what's ex and re?
15:08:56 <olsner> and Banana, for that matter
15:09:27 <elliott> olsner: I'm not at liberty to discuss that with you
15:09:38 <olsner> elliott: ok
15:09:39 <Vorpal> elliott, and more to the point: why is there no mention of audio-only communication devices in there
15:09:54 <elliott> Vorpal: wat
15:09:59 <Vorpal> elliott, bananaphone
15:10:11 <elliott> Too ordered
15:10:18 <elliott> The Bananamiasma is used instead
15:10:25 <Vorpal> touche
15:10:51 <elliott> Deewiant: So, um, care to walk me through each parameter of the Trie class
15:11:11 <Deewiant> It's just so that I can do Map and Set without having to reimplement everything
15:11:12 <Vorpal> elliott, heh I read that as "Trine" since I played that yesterday
15:11:29 <elliott> Deewiant: Yes, I just want to know what each parameter is so I can make them into type families :-P
15:11:44 <Deewiant> instance Map map k => Base.Trie TrieMap Maybe map k where
15:11:46 <Deewiant> instance Map map k => Base.Trie TrieSetBase Identity map k where
15:11:52 <Deewiant> Does that answer your question
15:12:10 <elliott> I'm not sure what's up with Maybe/Identity there, but apart from that, yes
15:12:35 <Deewiant> elliott: It's for the value: for maps it's Maybe value, for sets it's Identity Bool
15:12:42 <elliott> Heh
15:12:50 <Deewiant> And hence funky instances etc
15:12:54 <elliott> What's st stand for anyway
15:13:03 <Deewiant> storage or something
15:13:39 <CakeProphet> > 'B':fix("an"++)
15:13:41 <lambdabot> "Banananananananananananananananananananananananananananananananananananana...
15:14:38 * cheater_ just tried pronouncing that, but doesn't know which syllable the stress is on.
15:14:41 <CakeProphet> truly this is a shining example of what Haskell excels at.
15:14:44 <elliott> import qualified Data.DLiStorage trie as DL
15:14:46 <elliott> Herp derp
15:15:02 <elliott> adjuStorage trie :: Trie trie map k
15:15:04 <elliott> Oh my god
15:15:13 <Deewiant> :-D
15:15:37 <elliott> toLiStorage trie = genericToLiStorage trie Map.toLiStorage trie DL.cons
15:15:56 <Deewiant> Turns out "st" is a common consonant pair huh
15:16:12 <elliott> I put a space after for a reason ;_;
15:16:45 <Deewiant> Turns out "list " turns up often in a library dealing largely with lists
15:16:58 <Deewiant> And "Just " in a Haskell program
15:17:28 <elliott> tVal = fStorage trie . tParts
15:17:31 <elliott> oh my fucking god
15:17:39 <Deewiant> Dude
15:17:47 <elliott> yes i am trying to repair it piece by piece :D
15:17:47 <Deewiant> Press the M-x undo or whatever it is
15:18:07 <Deewiant> And then look for M-x i-want-perl-regular-expressions-dammit and use <st>
15:18:40 <elliott> replace-regexp, but it's elisp regexps
15:18:51 <elliott> \bst\b -> Storage trie should work
15:19:16 <Deewiant> You can call it something else than Storage as well, if you want :-P
15:19:36 <Deewiant> It's not exactly descriptive and if it's going to get a name longer than two characters it probably should be
15:22:00 <elliott> I'm just sitting here wondering if it could all be done in a simpler manner :-P
15:22:55 <fizzie> Vorpal: Another 360 degrees: http://users.ics.tkk.fi/htkallas/20110813_005-020.jpg
15:23:20 <elliott> Like, I think people have implemented tries in languages without four-parameter type classes before :D
15:23:57 <Deewiant> Yes, and with a lot less type checking
15:24:09 <Deewiant> I can replace the "st" parameter with a void* ;-P
15:25:13 <elliott> :-P
15:25:37 <Vorpal> fizzie, *looks*
15:25:45 <Vorpal> fizzie, nice
15:25:47 <Vorpal> where is it?
15:25:58 <Vorpal> fizzie, and what is the blacked out stuff
15:26:03 <Vorpal> fizzie, defence secret?
15:26:06 <fizzie> Vorpal: It's a redacted person. :p
15:26:14 <Vorpal> fizzie, defence secret :P
15:26:15 <elliott> "Person"
15:26:19 <elliott> If that's what you're calling them these days
15:26:22 <fizzie> I'm trying to find it on the map, but Google's satellite photos are rather low-res from where it's from.
15:26:36 <Vorpal> elliott, yeah in my time we used to say as it were...
15:28:23 <Deewiant> $ tup upd |& wc -l
15:28:24 <Deewiant> 366
15:28:32 <Deewiant> I think that's a good place to leave it
15:28:36 <fizzie> Vorpal: It's approximately from http://maps.google.com/?ll=59.820035,22.955804&spn=0.020798,0.065961&t=h&z=15 I think.
15:28:48 <elliott> Deewiant: Wait, how many files is mushspace exactly
15:28:57 <elliott> Or do you have hundreds of warnings
15:29:13 <Deewiant> $ tup upd |& grep error | wc -l
15:29:13 <Deewiant> 89
15:29:15 <elliott> Also, tup monitor -a -f power :-P
15:29:21 <Deewiant> Those are all from the same file
15:29:21 <elliott> Without the power part, that's just my comment
15:29:23 <elliott> Also the smiley
15:29:58 <Deewiant> I doubt that's helpful
15:30:45 <elliott> Deewiant: It's incredibly helpful for development :-P
15:30:57 <elliott> Make change, <insert favourite editor saving motion here>, tab back to terminal, see errors immediately
15:31:01 <elliott> Or with a split-screen, etc.
15:31:20 <Deewiant> Adding the "press up, enter" after "tab back" isn't that bad :-P
15:31:43 <Deewiant> Also I don't want to see it scroll by every time I :w, I can read through the 100 errors myself
15:31:52 <Deewiant> I don't need to see the updates as it goes to 99, 98, ...
15:32:09 <elliott> Your loss :P
15:32:17 <elliott> <Deewiant> Adding the "press up, enter" after "tab back" isn't that bad :-P
15:32:19 <Deewiant> I consider it a gain :-P
15:32:21 <elliott> That's why the split-screen is nicer
15:32:24 <elliott> 0 steps versus three
15:32:33 <Deewiant> I'd find the constantly scrolling errors even more distracting
15:33:01 <Deewiant> I have zero interest in how little of $FUNCTIONALITY compiles until I'm done writing it
15:33:34 <elliott> It's mostly useful when debugging
15:33:41 <Deewiant> Oh, sure
15:33:41 <elliott> Also, why do you have hundreds of errors in one file
15:33:47 <Deewiant> But in this case, it's not very useful
15:33:52 <Deewiant> I didn't say it's never useful
15:33:58 <elliott> Fair enough
15:34:00 <Deewiant> But uh, as to how many files, that's probably going to change by a divisor of 2 soonish and then blow up again as I split functionality into files with higher granularity
15:34:25 <elliott> I am determined to make Shiro have a faster fungespace :P
15:34:37 <elliott> I'm sure I can beat you in fungicide
15:34:45 <Deewiant> elliott: I mean currently this works like http://sprunge.us/LEGH
15:34:56 <elliott> Deewiant: #pragma push_macro
15:34:59 <Deewiant> Yep
15:34:59 <elliott> Deewiant: Dude, I've taught you bad things
15:35:02 <elliott> Deewiant: Don't be me
15:35:25 <Deewiant> My coming solution to that is to list the .c.in files four times in the Tupfile, with different -DFOO
15:35:27 <elliott> Deewiant: Have I mentioned that shiro-lahey can support both compile-time optimised dimensions and also arbitrary at runtime thanks to existentials
15:35:33 <elliott> ~The~ ~Best~
15:35:41 <elliott> (And some judicious SPECIALISE pragmas)
15:35:54 <elliott> <Deewiant> My coming solution to that is to list the .c.in files four times in the Tupfile, with different -DFOO
15:36:02 <elliott> Deewiant: This is why your cc rule should include CFLAGS_[percent]f
15:36:14 <elliott> Or for instance...
15:36:15 <Deewiant> How would that help
15:37:07 <elliott> !ndcc = |> ^ CC %f^ $(CC) -c %f -o %o $(CFLAGS) -DDIMENSIONS_LOL=$(DIMENSIONS) $(CFLAGS_%f) |> %B_$(DIMENSIONS).o
15:37:09 <Deewiant> I don't need per-file flags, I need four different sets of flags which are applied to each file :-P
15:37:17 <elliott> I guess that needs DIMENSIONS to vary there, which I dunno if is possible
15:37:23 <elliott> Ask the tup list :-P
15:38:05 <Deewiant> I still don't see how CFLAGS_%f is relevant :-P
15:39:25 <elliott> It isn't
15:39:29 <elliott> Momentary lapse of thinking
15:41:26 <Deewiant> Anyway, 10 .c, 13 .h, 6 _impl.c.in, 6 _impl.h, 1 config.h.in
15:41:51 <Deewiant> + a hash table library which is one .h
15:44:03 <Deewiant> elliott: man tup sez "The !-macro is not expanded until it is used in the command string of a :-rule." so I guess it's possible to vary it by setting DIMENSIONS_LOL in the Tupfile prior to each relevant :-rule
15:44:22 <elliott> Deewiant: Right
15:48:38 -!- zzo38 has joined.
15:54:34 <elliott> shiro is finally cabalised.
15:55:07 <elliott> Now all it needs is a major cleanup, and I'll put it on GitHub
15:55:17 <elliott> Deewiant: And then you have to start including it in Mycology results ;-)
15:55:31 <Taneb> All the great Computer Scientists seem to be British, American, or German
15:55:40 <elliott> Taneb: Dijkstra
15:55:52 <elliott> Taneb: Wirth
15:55:55 <Deewiant> elliott: So does slowdown work yet
15:56:01 <Taneb> Hmm
15:56:06 <elliott> Deewiant: Excuse me, you need to work with me to disprove Taneb first
15:56:07 <elliott> :-P
15:56:27 <elliott> I guess Wirth counts as basically German [simultaneously offends every Swiss on the planet]
15:56:45 <elliott> Deewiant: But yes, I htink it does
15:56:59 <elliott> Deewiant: Does Mycology have a permanent git repository location I could submodule?
15:57:04 <Taneb> Okay, it seems all great Computer Scientists' first languages are Germanic
15:57:07 <elliott> Seems gross to add rsc/mycology to my git repository
15:57:19 <elliott> Taneb: Probably because you can't read the work of the others
15:57:22 <Deewiant> No because I haven't githubbed my stuff
15:57:31 <Deewiant> Something I plan to do at some point
15:58:03 <elliott> I guess I'll mirror all the catseye stuff in a separate repo
15:58:07 <elliott> Since those don't load in browsers, sigh
15:58:15 <Deewiant> Like what?
15:58:41 <elliott> Deewiant: http://catseye.tc/projects/funge98/library/MODU.html
15:58:55 <elliott> pikhq went all anal-XHTML-Nazi on him, now I can't access valuable resources without wgetting them
15:59:06 <Deewiant> Oh, it was pikhq's fault? heh
15:59:13 <Deewiant> Anyhoo, you can "view source"
15:59:17 <elliott> Well, pikhq whined at Gregor, Gregor had a breakdown and did it
15:59:24 <elliott> Then cpressey went "hey that looks like fun"
15:59:27 <elliott> So yeah, all pikhq's fault
15:59:43 <elliott> Deewiant: I can, but I might as well just try and archive every fingerprint spec I can into one repository and include it as a submodule
15:59:52 <elliott> Basically a "funge-standards" repository
15:59:52 <Deewiant> Taneb: Does Kolmogorov count?
15:59:59 <elliott> Include the standards we have copies of too, why not
16:00:15 <Deewiant> Yeah, sure
16:00:17 <Taneb> Christos Papadimitriou
16:00:29 <Taneb> His first language is Greek
16:01:21 <elliott> $ dist/build/shiro/shiro rsc/slowdown.b98 rsc/forks.b98
16:01:21 <elliott> [hang]
16:01:29 <elliott> Deewiant: So yes, I can run slowdown, unless I fucked up one of the instructions it uses
16:01:31 <Deewiant> What's forks.b98
16:01:34 <elliott> Which is possible, I'm lagging behind on Mycology
16:01:37 <elliott> Deewiant: Something you wrote
16:01:44 <Deewiant> I suggest something like "a,@"
16:02:03 <elliott> elliott@katia:~/Code/shiro$ cat >test
16:02:03 <elliott> a,@
16:02:03 <elliott> elliott@katia:~/Code/shiro$ dist/build/shiro/shiro rsc/slowdown.b98 test
16:02:03 <elliott> [hang]
16:02:08 <elliott> My fungespace is naive dude, this will take years
16:02:09 <Deewiant> Although I'm not sure how much the size of the program loaded affects the runtime
16:02:16 <Taneb> Blaise Pascal
16:02:16 <Deewiant> Perhaps not much at all
16:02:18 <Taneb> He was French
16:02:21 <elliott> I mean, cfunge's is naive, but it's naive microoptimised C
16:02:34 <Deewiant> And how long does cfunge take
16:02:50 <elliott> Deewiant: Dunno; you do it as part of fungicide, but your computer is a lot faster than mien
16:02:54 <elliott> mine
16:02:56 <Deewiant> No I don't
16:03:01 <Deewiant> fungicide doesn't include slowdown in any shape or form :-P
16:03:02 <elliott> Oh
16:03:03 <elliott> I thought you did
16:03:06 <elliott> Hmph
16:03:07 <elliott> Well it should
16:03:09 <elliott> Why doesn't it
16:03:10 <Vorpal> Taneb, Allan Turing Was English
16:03:12 <Deewiant> >_<
16:03:16 <elliott> Vorpal: Alan
16:03:20 <Vorpal> right
16:03:25 <elliott> Deewiant: Hey, you'd win even more ;-)
16:03:31 <Deewiant> Because fungicide is 100% synthetic benchmarks so that everybody can complain at me for not including "real programs"
16:03:33 <Vorpal> Taneb, and what about Donald Knuth?
16:03:36 <elliott> Although you would have to remove Language::Befunge
16:03:53 <elliott> Deewiant: I won't complain because my tactics involve code rather than whining :-P
16:04:00 <elliott> Well
16:04:03 <elliott> Whining, then code
16:04:06 <elliott> But that's just as good, right?
16:04:18 <Deewiant> If I'm going to do more Fungiciding I'm going to do what I did with Mycology and say "here are the old results which include slow interpreters, from now on I'm only doing the fast ones"
16:04:24 <Taneb> English is a Germanic Language
16:04:25 <elliott> 23013 elliott 20 0 29884 3420 1840 R 101 0.1 2:21.23 shiro
16:04:28 <elliott> At least it doesn't have a memory leak
16:04:39 <elliott> Deewiant: So it'll just be me and CCBI once I fix this fungespace? :-P
16:04:51 <Vorpal> Deewiant, as far as I remember cfunge manages quite a good turn of speed?
16:04:51 <Deewiant> And cfunge and possibly stinkhorn
16:05:07 <Vorpal> Deewiant, even beating your code at some cases iirc
16:05:14 <elliott> Deewiant: cfunge is "fast" for fungicide?
16:05:16 <Vorpal> (diagonal growing wasn't it?)
16:05:35 <elliott> 247.7 vs 3628.5 (worst CCBI vs best cfunge)
16:05:45 <Deewiant> That's total time dude
16:05:50 <elliott> So :P
16:05:54 <elliott> Deewiant: pyfunge is faster than stinkhorn, it looks like
16:05:55 <Deewiant> And that's based on an old cfunge
16:05:56 <elliott> Which is hilarious
16:06:03 <Deewiant> No it's not
16:06:08 <elliott> 10281.2
16:06:09 <elliott> 12888.2
16:06:10 <Deewiant> That table is sorted correctly you know
16:06:16 <Deewiant> elliott: Ran to finish: 74 / 42
16:06:21 <elliott> Oh
16:06:23 <elliott> Heh
16:06:24 <Deewiant> So 32 timeouts :-P
16:06:29 <Deewiant> Or crashes, I forget
16:06:34 <elliott> What's the difference
16:07:07 <Deewiant> And yes, both cfunge and RC/Funge-98 beat CCBI on the diagonal growing
16:07:21 <elliott> Hmm, I like how right after I eliminate a ton of typeclass overhead I'm looking at adding it back in again
16:07:25 <elliott> But I won't, it doubled my Mycology time
16:07:39 <elliott> I know, I'll do something reasonable
16:07:47 <elliott> Fix my non-fingerprint Mycology BADs
16:07:48 <Deewiant> Funny how RC/Funge-98's weird-ass Funge-Space works for it there
16:07:51 <elliott> And then fix all the GHC warnings I can
16:08:07 <Deewiant> (It's something like one linked list of cells for each row)
16:08:11 <elliott> Wrote to mycotmp0.tmp with o in linear text mode.
16:08:11 <elliott> GOOD: o removed space prior to newline
16:08:11 <elliott> UNDEF: o removes spaces prior to newline-valued cells
16:08:11 <elliott> BAD: i misread or o miswrote
16:08:12 <elliott> Ugh >_>
16:08:31 <Vorpal> <elliott> 247.7 vs 3628.5 (worst CCBI vs best cfunge)
16:08:39 <Vorpal> that is because Deewiant never updated it
16:08:41 <elliott> Deewiant: BTW, if you ever remember/loggrep the structure I mentioned I was considering using for fungespace to you, that'd be great :P
16:08:45 <Vorpal> after I fixed that major bug in forking
16:08:56 <Deewiant> Yes, that's what I said
16:09:00 <elliott> Deewiant: I think it was in /msg, FWIW
16:09:28 <elliott> I wonder if a quadtree/octree/... might work out for me
16:09:31 <Deewiant> I can non-/msg-paste relevant things if you like
16:09:53 <elliott> Deewiant: I was hardly revealing trade secrets
16:10:00 <Deewiant> 2011-03-25 06:37:41(elliott) Food for thought: Might a bounding volume hierarchy be a smart choice for fungespace?
16:10:04 <elliott> Ah yes
16:10:04 <Deewiant> 2011-03-25 07:10:11(elliott) (Thought triggered by random comment on interwebs saying that they're usually more appropriate than k-d trees due to the latter having a higher overhead.)
16:10:16 <elliott> http://en.wikipedia.org/wiki/File:Example_of_bounding_volume_hierarchy.JPG
16:10:19 <elliott> Still the best image
16:10:31 <elliott> Hmm, that actually seems to show a situation inapplicable to fungespace
16:10:35 <elliott> Because the "shapes" never overlap
16:10:50 <elliott> "One of the most commonly used bounding volumes is an axis-aligned minimum bounding box."
16:10:52 <elliott> Dammit Deewiant :-)
16:10:59 <Deewiant> :-P
16:11:02 <elliott> I MUST DO SOMETHING COMPLETELY DIFFERENT
16:11:57 <elliott> Gah, my fingerprint code is really, really unsatisfactory
16:12:04 <elliott> I have a typeclass that is always used existentially
16:12:07 <elliott> So it's basically just an ADT
16:12:14 <elliott> And it's so ugly and geh
16:13:47 <Deewiant> Just blame Vorpal for adding that static allocated area in the first place or we'd be living happily in hash table land
16:14:07 <elliott> :D
16:14:16 <Gregor> Hashtable Land is the greatest land in the world.
16:14:29 <elliott> Deewiant: Hey, rename my maybeShiro
16:15:06 <elliott> maybeShiro :: Shiro () -> Shiro ()
16:15:06 <elliott> maybeShiro m = m `catchShiro` handler
16:15:06 <elliott> where handler :: IOException -> Shiro ()
16:15:06 <elliott> handler e
16:15:06 <elliott> | isUserError e = reflect
16:15:07 <elliott> | otherwise = io $ throwIO e
16:15:16 <Deewiant> shiroOrReflect
16:15:17 <elliott> It used to be MaybeT Shiro () -> Shiro (), but then I optomized :P
16:15:30 <elliott> Deewiant: catchReflect, then
16:15:51 <Deewiant> That works
16:15:52 <elliott> liftMaybe :: Maybe a -> Shiro a
16:15:52 <elliott> liftMaybe x = do
16:15:52 <elliott> Just a <- return x
16:15:52 <elliott> return a
16:15:52 <elliott> Here we have a bizarre function that does the right thing only in a catchReflect block :-P
16:16:17 <elliott> I guess maybeReflect is the best name
16:16:18 <Deewiant> And you complain about my code
16:16:20 <elliott> And ioReflect for ioMaybe
16:16:29 <elliott> Deewiant: Hey, there's literally no other way to avoid huge nested case stacks
16:16:39 <Deewiant> At least I don't have functions that have a dependency on what's on the call stack!
16:16:43 <elliott> And pattern matches "fail"ing in do context is well-defined behaviour
16:16:47 <elliott> Deewiant: Uhh, neither do mine?
16:17:05 <elliott> If the pattern match fails, it's Report-defined to "fail", which my handler catches, and reflects
16:17:08 <Deewiant> That's basically what requiring that being in catchReflect is :-P
16:17:26 <elliott> Weeeeeeeeeeeeeeeeeeeeell
16:17:31 <elliott> There's basically one thing I could do
16:17:36 <elliott> Add a phantom parameter to Shiro
16:17:37 <CakeProphet> as I sit here waiting for apt-get to finish. The follow comic comes to mind: http://xkcd.com/303/
16:17:42 <CakeProphet> *following
16:17:45 <elliott> I can't just stack transformers on top, because it puts me in lift hell
16:17:47 <elliott> So I need MonadShiro
16:17:51 <elliott> So everything gets a MonadShiro context
16:17:57 <elliott> So I have a billion SPECIALISE pragmas or it's fucking slo
16:17:57 <elliott> w
16:18:01 <Deewiant> s/can't/don't want to/
16:18:07 <elliott> Deewiant: No, see above
16:18:12 <elliott> It makes my code twice as slow
16:18:15 <elliott> That's a "can't"
16:18:25 <Deewiant> That's the price of writing in high-level languages
16:18:35 <Deewiant> Like C or greater
16:18:38 <elliott> :-D
16:18:42 <Deewiant> I should just do this in asm
16:18:47 <elliott> Deewiant: No, no, Checkout
16:18:51 <elliott> Parallel fungespace processing
16:19:13 <Deewiant> Although I guess if I write enough inline assembly it'll work out
16:19:21 <elliott> Hmm... I could have (Shiro a) be (ShiroE () a)
16:19:24 <elliott> Then catchReflect would be
16:19:39 <elliott> catchReflect :: ShiroE CatchReflect a -> ShiroE e a
16:19:43 <elliott> Hmm, wait
16:19:48 <elliott> (Shiro a) would be (forall e. ShiroE e a)
16:19:54 <elliott> Right
16:20:05 <Deewiant> I spent about 1.5 hours yesterday optimizing "return INT_MAX - a < b ? INT_MAX : a + b"
16:20:10 <elliott> And then in a fingerprint I could have ShiroE (FingerprintE fptype) for the staet...
16:20:12 <elliott> But oh wait
16:20:15 <elliott> How would that stack with CatchReflect
16:20:19 <elliott> I NEED TYPECLASSES TO CONTROL THE NESTING
16:20:24 <elliott> LOLOLOLOLOLOLOLOLOLOLOLOLOLOLOLO
16:20:32 <elliott> Deewiant: Call stack dependencies: THe best.
16:20:39 <elliott> Anyway it works outside of the call stack, it just doesn't catch the failure.
16:20:45 <Vorpal> <Deewiant> Just blame Vorpal for adding that static allocated area in the first place or we'd be living happily in hash table land <-- heh
16:23:15 <elliott> Deewiant: You'll be happy to hear (maybe) that I only get one BAD outside of fingerprints
16:23:21 <elliott> And it's to do with o's text mode and ugh
16:24:10 <Deewiant> unlines . map (reverse . dropWhile (==' ') . reverse) . lines
16:24:10 <Deewiant> HTH
16:24:38 <elliott> textify :: ByteString -> ByteString
16:24:39 <elliott> textify = B8.unlines . reverse . takeWhile (/= B.empty) . reverse . map (fst . B.spanEnd (== space)) . B8.lines
16:24:40 <elliott> Deewiant: You were saying
16:24:53 <Deewiant> WFM
16:24:59 <elliott> Deewiant: It's probably i that's the problem
16:25:03 <elliott> Because, well
16:25:10 <elliott> Have I mentioned mergeByteString? :P
16:26:18 <elliott> I wish the funge instructions had some kind of obvious grouping
16:26:21 <elliott> So I could split Interpreter.hs up
16:28:53 <CakeProphet> lol bamfdaemon
16:31:49 <elliott> $ grep -r 'TODO\|FIXME' . | wc -l
16:31:49 <elliott> 14
16:31:51 <elliott> That few???
16:31:57 <Deewiant> No XXX?
16:32:04 <Deewiant> The instruction grouping's in the spec
16:32:17 <elliott> That just makes me think of comment pornography, and what does XXX even mean
16:32:21 <Deewiant> "Cell Crunching - Integers" etc
16:32:40 <elliott> TODO basically means "Hey do this cleanup/optimisation/etc. sometime", FIXME is "This is really terrible/has an obvious bug/just looks wrong, fix it"
16:33:14 <Deewiant> FIXME is for plain old bohr bugs/missing features, XXX is for stuff like "this works but I don't know why", heisenbugs, and the like
16:33:15 <elliott> Deewiant: Hmm, you're right re: grouping
16:33:21 <elliott> It's rather coarse, but maybe good enough
16:33:33 <Deewiant> When I use XXX I tend to use "TODO FIXME XXX" though
16:33:38 <elliott> Deewiant: I use TODO for features, basically if there's a TODO, I _could_ ignore it, it'll just make my life worse
16:33:49 <elliott> FIXME basically means that there's something that has to get addressed, I'm just too lazy right now
16:33:52 <elliott> And/or don't know how
16:34:04 <elliott> "TODO FIXME XXX" is good though
16:34:17 <elliott> Maybe I should use "WTF:".
16:34:19 <zzo38> I only use TODO regardless of purpose or severity and it works fine for me
16:34:48 <Deewiant> // XXX: I have no idea why /2 makes this work
16:34:51 <Deewiant> That's a good example
16:34:59 <elliott> Heh
16:35:10 <elliott> OK, I should really add proper command-line handling to shiro
16:35:15 <elliott> main = do
16:35:16 <elliott> args@(filename:_) <- getArgs
16:35:16 <elliott> program <- B.readFile filename
16:35:16 <elliott> let st = (fungeStateFromByteString program) { cmdArgs = args }
16:35:16 <elliott> case fungeSpace st of
16:35:18 <elliott> FungeSpace m (minX,minY) (maxX,maxY) m2 m3 ->
16:35:18 <Deewiant> // XXX: this looks like a hack
16:35:20 <elliott> Map.size m `seq` Map.size m2 `seq` Map.size m3 `seq` minX `seq` minY `seq` maxX `seq` maxY `seq` return ()
16:35:23 <elliott> It's currently very pro
16:35:24 <Deewiant> assert (false); // XXX for debugging only
16:35:25 <elliott> By pro I mean terrible
16:35:43 <Deewiant> Dude, rnf
16:35:47 <elliott> Dependencies
16:35:48 <Deewiant> Instead of Map.size
16:35:59 <Deewiant> You know you're going to want threads at some point right
16:36:04 <elliott> base, containers, bytestring, process, random, filepath, time, directory, unix (will be fixed), mtl, hashtables
16:36:07 <elliott> Those are all my dependencies
16:36:12 <elliott> hashtables is overkill
16:36:15 <elliott> Deewiant: Threads howso
16:36:22 <Deewiant> Every program needs threads
16:36:29 <Deewiant> Parallel Funge-Space garbage collectors, etc
16:36:43 <elliott> Deewiant: Well, if I write that debugger/developer...
16:36:55 <Deewiant> (Something I've actually thought about doing but most likely never will)
16:37:07 <elliott> Hmm, I could use cmdargs if I used the pure API
16:37:13 <elliott> I'm a sensitive person
16:37:19 <elliott> Can't even use a top-level unsafePerformIO newIORef
16:37:37 <Deewiant> But you can depend on the call stack
16:37:38 <Deewiant> Nice
16:37:44 <zzo38> If I made the compiler I would make assert(false) compile into an error message (or break into debugger) if debug mode, and into the "unreachable" LLVM command when not debug; this would mix up such things like that... but, then, you could use conditional compilation to make it only for debug, or whatever.
16:37:49 <elliott> Deewiant: It is not a dependency, I renamed them so that their behaviour is perfectly reasonable
16:38:00 <elliott> catchReflect :: Shiro () -> Shiro ()
16:38:00 <elliott> maybeFail :: Maybe a -> Shiro a
16:38:02 <elliott> ioFail :: IO a -> Shiro a
16:38:06 <elliott> You can use the latter two outside of the first if you wish
16:38:14 <elliott> They will do as their name suggests
16:38:21 <elliott> (maybeFail is an unintentionally hilarious name)
16:38:23 <Deewiant> Maybe they'll fail, maybe they won't
16:38:39 <Deewiant> As unintentional as "pun not intended"
16:38:47 <zzo38> What does "Shiro" mean here?
16:38:59 <elliott> zzo38: Funge Haskell magic
16:39:06 <elliott> Deewiant: No, it was unintentional
16:39:07 <elliott> I only just realised :D
16:40:04 <zzo38> How does Funge Haskell magic work?
16:40:14 <elliott> By interpreting Funge programs in Haskell
16:40:43 <CakeProphet> in C++, doing a c-style cast from float to int would just leave the significand right?
16:41:42 <elliott> Deewiant: Have you used any of the option parsing libraries, I suddenly realise I've never written a command-line Haskell program with a non-trivial interface
16:42:02 <Deewiant> Hmm, I wonder
16:42:14 <Deewiant> I don't think I have but I'm not sure
16:42:29 <CakeProphet> also if you have
16:42:39 <CakeProphet> struct foo { int x; ...}
16:42:39 <Deewiant> I've used System.Console.GetOpt I think
16:42:42 <elliott> Ugh, OK, the one that comes with like, the base libraries, is terrible, [Flag] is not a sane result structure
16:42:45 <elliott> Yeah, that one
16:42:47 <Deewiant> Yeah, I've used that
16:42:50 <elliott> I guess I'll just use cmdargs
16:42:59 <CakeProphet> then (int) someStructFoo would be equivalent to someStructFoo.x right? or is there padding and stuff?
16:43:06 <Deewiant> What's wrong with [Flag]
16:43:08 <elliott> record Options{} [a := def += help "hey hey hey", ...] += summary "blah"
16:43:15 <elliott> Deewiant: Because it should be an options record instead?
16:43:18 <elliott> It's just semantically bunk :P
16:43:24 <elliott> Remember that Flag is a type you specify
16:43:27 <elliott> It's not just like returning (string,arg)
16:43:29 <Deewiant> elliott: Just fold over it
16:43:34 <elliott> It lets you pass a constructor function and everything
16:43:51 <elliott> Deewiant: Or just use cmdargs which handles it for me :P
16:44:02 <Deewiant> Fiiine
16:44:21 <zzo38> I would like if LLVM had a union type, it might allow some optimizations that are not done otherwise, even though you can still make up your own unions in LLVM anyways
16:44:26 <elliott> Deewiant: More importantly, I need recursive argument parsing
16:44:41 <elliott> --fprint-turt="--format=svg"
16:45:08 <Deewiant> And you can do that with GetOpt :-P
16:45:36 <elliott> Deewiant: What's so good about GetOpt :P
16:45:42 <Deewiant> Nothing in particular
16:45:45 <elliott> Hmm wait
16:45:46 <elliott> Wait
16:45:47 <elliott> ONE
16:45:47 <elliott> LESS
16:45:48 <Deewiant> The fact that it's in base
16:45:48 <elliott> DEPENDENCY
16:45:50 <Deewiant> Yep
16:45:55 <elliott> YEEEEEEEEEEEEeeeeeeeeeeeessssSSSs
16:47:42 <elliott> Deewiant: One problem: I have no options right now :D
16:48:02 <elliott> Shiro/Types.hs:8:8:
16:48:02 <elliott> Ambiguous module name `Control.Monad.State.Strict':
16:48:02 <elliott> it was found in multiple packages: mtl-2.0.1.0 monads-tf-0.1.0.0
16:48:03 <elliott> SFOJISDFNJSDIOFJISNDJLFOJDNGNJG DON GODNF G
16:48:06 <elliott> I AM GOING TO RIP YOUR SOUL
16:48:07 <elliott> BETWEEN THE BINDS
16:48:08 <elliott> OF EARTH
16:48:09 <elliott> AND HELL
16:48:20 * elliott UNINSTALLS MONADS-TF
16:48:38 * elliott INSTALLS CAB SO HE CAN DO THAT
16:48:44 <Deewiant> elliott: Gotta love type families eh
16:49:07 <elliott> monads-tf may be great, but only one fucking package uses it
16:49:11 <elliott> Oh my god cab has revdeps
16:49:14 <elliott> TIHS CHANGE S EVERYTHIN
16:49:14 <elliott> G
16:50:11 <elliott> Dammit, the default mconcat on functions isn't composition
16:51:06 <CakeProphet> data FlipList a b = a :* FlipList b a | Empty
16:51:08 <CakeProphet> look what I did.
16:52:21 <olsner> use the Endo monoid?
16:52:51 <CakeProphet> data TripList a b c = a :* FlipList b c a | Empty
16:53:01 <CakeProphet> *TripList
16:53:19 <CakeProphet> er? maybe? I don't know what that is.
16:53:32 -!- tswett has quit (Changing host).
16:53:32 -!- tswett has joined.
16:53:37 <zzo38> Is the single field of a newtype constructor allowed to have the same name as other fields of newtype constructors that the other fields have the same type?
16:53:39 <olsner> oh, that was for elliott's comment about mconcat
16:54:49 -!- Nisstyre has quit (Ping timeout: 250 seconds).
16:55:06 <CakeProphet> you could also have the "totally safe" function FlipList a b -> [(a,b)]
16:55:23 <elliott> Deewiant: Guess what GetOpt can't handle nicely, that's right, things like --help and --version
16:55:24 <CakeProphet> with the exception that it's not actually safe because it only works with even-lengths fliplists
16:55:31 <elliott> HMmmmmmmmmmmmmmm
16:55:33 <elliott> UNLESS
16:55:38 <elliott> I made them all of type
16:55:42 <elliott> StateT Options IO ()
16:59:42 <elliott> I wish GHC wouldn't complain when I did
16:59:44 <elliott> import Data.ByteString (ByteString)
16:59:44 <elliott> import qualified Data.ByteString as B
16:59:48 <elliott> without explicitly mentioning ByteString anywhere
16:59:53 <elliott> It's an idiom, GHC
17:07:05 <zzo38> Is there some pragma to not complain in these cases?
17:08:26 -!- Nisstyre has joined.
17:09:21 <elliott> Yeah, turn off the warning :P
17:16:24 <elliott> Deewiant: Is TrieMap ultra-strict by any chance >_>
17:16:42 <elliott> I don't think I have a single bit of laziness in this entire program :P
17:16:44 <Deewiant> It's strict in the key, of course :-P
17:16:48 <elliott> Real laziness, that is
17:16:55 <elliott> Rather than unnecessary laziness
17:17:04 <Deewiant> And it has ' versions for everything when you want to be strict in the value
17:17:46 <elliott> It... might even be faster than Map for (Int32,Int32), mightn't it
17:18:03 <elliott> It'll basically just turn into a nested IntMap, won't it >_>
17:18:15 <Deewiant> What, with [Int32] as the key? Yes :-P
17:18:23 <elliott> Deewiant: With (Int32,Int32) as the key
17:18:39 <Deewiant> TrieMap is a trie, it needs a list
17:19:16 <elliott> Oh right :P
17:21:11 <elliott> Deewiant: Would me creating a funge-specifications repository make Mycology appear on GitHub faster :-
17:21:12 <elliott> :-P
17:21:35 <Deewiant> No :-P
17:21:43 <elliott> Are you suuuuuuuuure
17:21:48 <elliott> What if it was incredibly meticulously organised
17:21:54 <Deewiant> Hey, I made the repo already, there's just no content there
17:21:58 <elliott> s/funge-specifications/funge-archive/ I guess
17:22:10 <elliott> Since I don't see why it shouldn't have fungicide too
17:22:17 <elliott> Deewiant: "Created about an hour ago" Pro :P
17:22:33 <elliott> I find your initial capitals disturbing
17:22:52 <Deewiant> I thought you might
17:30:40 <elliott> Hmph, I should really figure out a way to stack transformers without hell
17:30:57 <elliott> fpRun :: FPIns -> StateT (globalstate,ipstate) Shiro () is pretty much the exact type I want
17:33:50 -!- Taneb has quit (Ping timeout: 260 seconds).
17:36:17 <elliott> Deewiant: So how does Shiro handle per-fingerprint sta-- OH YEAH YOU USE AN IMPERATIVE LANGUAGE LIKE TERRIBLE PEOPLE.
17:36:59 <Deewiant> s/Shiro/CCBI/
17:37:02 <elliott> Oops
17:37:24 <elliott> Meanwhile I'm really annoyed that Fungi exists, even though I'm pretty sure it's way slower than Shiro
17:37:30 <elliott> It has a debugger of some kind and everything
17:37:45 <elliott> (It's N-dimensional and just uses (Map [i]))
17:38:11 <elliott> Although it does have
17:38:11 <elliott> , conservativeMinMaxCoords :: !(Conservative (Vector i, Vector i))
17:38:18 <elliott> where conservative is some weird
17:38:18 <elliott> data Conservative a = Precise !a | Imprecise !a
17:38:19 <elliott> that's a Functor
17:39:10 <elliott> Oh, it's just so that it can only calculate precise bounds when necessary
17:39:12 <elliott> Ha, ha, so slow
17:39:38 <Deewiant> That doesn't necessarily mean "so slow" :-P
17:40:08 <elliott> Deewiant: Yes, but when it does, it uses Map.foldWithKey
17:40:15 <elliott> Ha, ha, so slow
17:41:06 -!- Gregor has set topic: Functor? I hardly knew 'er! | iridium is too mainstream | http://codu.org/logs/_esoteric/.
17:44:13 <elliott> brb
17:52:49 <Gregor> elliott: Wiki's got some new users that need a banhammer.
18:04:52 <zzo38> Does the IO type in Haskell have any constructors?
18:08:44 <pikhq> zzo38: Well, *technically* it absolutely must have a constructor. *However*, it is in no way exported.
18:08:56 <pikhq> (well. Actually, GHC probably offers a way to get at it.)
18:34:54 -!- Taneb has joined.
19:16:40 <elliott> Deewiant: https://github.com/ehird/funge-archive
19:16:43 <elliott> IT BEGINS
19:17:12 <Deewiant> I'M WATCHING YOU
19:17:31 <elliott> People Watching ehird/funge-archive
19:17:31 <elliott> mcmap
19:17:31 <elliott> Oops
19:17:37 <elliott> mcmap created repository funge-archive about a minute ago
19:17:40 <elliott> Also oops
19:17:43 <elliott> How about I try this one again
19:18:11 <elliott> Deewiant: https://github.com/ehird/funge-archive
19:18:13 <elliott> Try again :P
19:18:19 <Deewiant> I'M WATCHING YOU
19:20:46 <Phantom_Hoover> ^quote
19:20:47 <lambdabot> Phantom_Hoover: You have 6 new messages. '/msg lambdabot @messages' to read them.
19:21:15 <elliott> Does anyone know how to make wget or curl set the last modified date
19:22:28 <elliott> -S
19:22:44 <elliott> Ugh, doesn't send
19:29:47 <elliott> Deewiant: Which standard first had fingerprints?
19:30:12 <Deewiant> I don't think there ever were full -96 or -97 standards
19:30:26 <elliott> But -96 had fingerprints?
19:30:32 <Deewiant> I can't remember
19:30:35 <elliott> Bleh :-P
19:30:54 <elliott> Befunge-96 and -ninetyseven, right, not Funge?
19:32:05 <elliott> Or, hmm
19:32:08 <elliott> Was it Funge-97
19:32:21 <quintopia> is there a language that uses ~= for neq?
19:32:34 <Deewiant> Bah, stupid cat's eye with its robots.txt
19:32:46 <Deewiant> No Wayback Machine for the Befunge-96 draft :-P
19:32:51 <elliott> It has no robots.txt
19:32:57 <elliott> Deewiant: But was it Funge-9seven or Befunge :P
19:33:00 <Deewiant> http://liveweb.archive.org/http://www.cats-eye.com/cet/soft/lang/befunge/96.html
19:33:05 <Deewiant> Page cannot be crawled or displayed due to robots.txt.
19:33:10 <elliott> Well, OK, that's a squatter dude :P
19:33:18 <Deewiant> Whatevs :-P
19:33:26 <elliott> Yeah Funge-97
19:34:01 <Deewiant> Mostly Befunge-97
19:34:05 <elliott> Oh
19:34:25 <Deewiant> I'm reading the mailing list archives
19:34:34 <elliott> Deewiant: Look what has actual content: https://github.com/ehird/funge-archive
19:34:41 <elliott> And commit messages meeting your stringent standards :-)
19:35:20 <Deewiant> Fingerprints came in -98 methinks
19:35:27 <elliott> Okay.
19:35:49 <Deewiant> At least this archive doesn't mention them at all :-P
19:35:52 <elliott> Hmm, separate tests/ directory or just put Mycology in the root and the rcfunge ones with their fingerprints
19:36:00 <elliott> I'm not going to bundle the old, shitty test suites
19:36:04 <elliott> Maybe in a bad/ directory
19:37:06 <Deewiant> Meh, just put everything in there somewhere and call it old/ instead of bad/
19:37:17 <elliott> Yeah, OK :-P
19:37:23 <elliott> I think I'll bundle fingerprint tests with their spec
19:37:28 <elliott> So mycology can be in a nice, easily-accessible location
19:40:18 <elliott> Oops, I think I did a bad
19:40:25 <elliott> Deewiant: Sorry, I non-permalinked your page
19:40:26 <elliott> Will fix
19:41:50 <Deewiant> elliott: "A *true* Nefunge should be able to handle 2.5D code :-)"
19:41:55 <Deewiant> Waiting on Shiro to handle that
19:41:56 <elliott> Deewiant: X-D
19:42:22 <elliott> Deewiant: Hey, gimme a oneline summary of slowdown that isn't "slows things down"
19:42:33 <elliott> And that also isn't "a very slow Befunge interpreter"
19:42:42 <Deewiant> Why not "slows things down"
19:42:48 <elliott> Because I want to be useful :P
19:42:48 <Taneb> Well, brainfuck is turing complete with a maximum loop depth of seven
19:43:00 -!- oerjan has joined.
19:43:07 <elliott> Deewiant: It's fair to put slowdown in a bench/ directory, right?
19:43:09 <Deewiant> It loads Befunge-98 code into a random location in Funge-Space and executes it there after wiping itself out
19:43:16 <Deewiant> I wouldn't, that wasn't the intention
19:43:24 <CakeProphet> anyone familiar with webkit?
19:43:29 <elliott> Deewiant: Well, I mean, it's designed to show how inefficient certain models are vs. others
19:43:36 <elliott> To reify the intentions behind it in a classier way
19:43:43 <elliott> That's closer to a benchmark than anything else
19:43:45 <elliott> It's speed-related
19:43:47 <Deewiant> It was meant to slow down wraparound
19:43:55 <elliott> Right
19:44:00 <elliott> But you didn't just write it because you were tapping random keys :P
19:44:05 <elliott> Or did you
19:44:21 <Deewiant> Not to execute a million cycles + push a million cells on stack before even executing the given program, though that ended up happening
19:44:35 <elliott> Heh
19:44:39 -!- ais523 has joined.
19:44:40 <Deewiant> Which is the main "slowdown" noticeable when using it on most programs :-P
19:44:57 <elliott> Well, where should I put it so that people can find it in a relevant-ish place
19:45:08 <Deewiant> I have it in the useful directory called "programs"
19:45:14 <elliott> I'm focusing on implementers, so bench/ means "look in here to find shit to help you make things go faster by showing you how much you suck
19:45:15 <elliott> "
19:45:23 <Taneb> ais523, I think there's been some spam
19:45:32 <elliott> Gregor: BTW, I'm flattered by how you consider me a wiki admin
19:45:37 <Deewiant> You can put a README or whatnot in bench/ :-P
19:45:47 <Deewiant> And say "also look at foodir/slowdown.b98"
19:46:31 <Taneb> Either I haven't been paying attention or elliott just misread Taneb as Gregor and ais523 as elliott
19:46:31 <Gregor> elliott: I have no idea who is :P
19:46:36 <Taneb> Probably the former
19:46:44 <elliott> Deewiant: Also, not literally a million, I take it
19:46:56 <Deewiant> I honestly can't remember
19:47:00 <Deewiant> I think it was over 100k at least
19:47:09 <oerjan> Gregor: the only wiki admin who comes here is ais523
19:47:26 <oerjan> oh wait
19:47:46 <oerjan> cpressey, if you interpret both terms widely :P
19:48:18 <ais523> oh, it's the privacy-aware dating spambots
19:49:00 <oerjan> because you _so_ trust people who spam with privacy
19:49:45 <elliott> Deewiant: https://github.com/ehird/funge-archive Behold :-P
19:50:04 <elliott> TODO: bench/README.md; bench/fungicide
19:50:10 <elliott> Also tons of other things but that's the short-term
19:51:37 -!- variable has quit (Ping timeout: 250 seconds).
19:53:03 <CakeProphet> 15:53 < CakeProphet> anyone familiar with webkit#?
19:53:03 <CakeProphet> 15:53 < NiFkE> crayon cake wtf
19:53:10 <CakeProphet> I guess I shouldn't expect much from ##csharp
19:53:28 <elliott> What :P
19:53:52 <CakeProphet> he whois'd me immediately
19:53:59 <CakeProphet> and just commented on my vhost.
19:54:18 <Gregor> CakeProphet: crayon cake wtf
19:54:41 <CakeProphet> Gregor: are YOU familiar with webkit#?
19:54:48 <elliott> crayon cake wtf
19:54:54 <elliott> CakeProphet: you realise that many clients show hostname on join
19:54:55 <Gregor> CakeProphet: Good lawd no
19:54:55 <elliott> no whois required
19:55:09 <CakeProphet> I AM TRYING TO FIND ELEMENTS BY ID IN A WEBPAGE USING THE WEBVIEW CLASS BUT IT DOESN'T HAVE ANY METHODS THAT SUGGEST THAT IT IS CAPABLE OF DOING THAT AAAAH.
19:55:37 <CakeProphet> no DOM-like thing.
19:56:21 -!- Sgeo_ has changed nick to Sgeo.
19:56:53 <oerjan> google images suggests that a crayon cake is simply a cake shaped like a box of crayons
19:57:32 <CakeProphet> why does C# hate me.
19:58:02 <fizzie> oerjan: There are surprisingly many crayon cake images, too. I wouldn't have thought it was a "thing".
19:58:22 <elliott> Deewiant: It's not worth archiving fungicide rankings, I take it
19:58:29 <oerjan> i was expecting it to be a term for some specific type of cake...
19:58:46 <ais523> CakeProphet: it hates everyone
19:58:50 <elliott> Also neither my tar nor my bash-completion for unxz know .txz which is incredibly irritating
19:58:50 <Deewiant> elliott: Archive the interpreters instead and you can recreate them ;-)
19:59:13 <elliott> Deewiant: So when you download Shiro, you also get Shiro, which includes Shiro, ...
19:59:37 <elliott> Deewiant: This is intended to be something everyone will ship with their interpreter because, hey, test suites 'n specs 'n shit :P
19:59:41 <CakeProphet> apparently no one is familiar with webkit on Freenode.
19:59:42 <oerjan> but given that CakeProphet is the second non-image hit on google for the quoted term...
19:59:42 <CakeProphet> no one.
20:00:05 <fizzie> CakeProphet: You can maybe get the DOMDocument via the WebFrame in the WebView.
20:00:16 -!- sllide has quit (Ping timeout: 252 seconds).
20:00:22 <CakeProphet> WebFrame looked even less promising than WebView but I'll check again.
20:00:37 <Deewiant> elliott: Well, I doubt everyone wants to ship some old benchmark results :-P
20:00:43 <CakeProphet> yeah there's currently no such thing as the DOMDocument class.
20:00:48 <elliott> elliott@katia:~/Code/funge-archive/bench/fungicide$ git commit -a
20:00:48 <elliott> [master 1ca994c] Add Fungicide
20:00:48 <elliott> 1 files changed, 4 insertions(+), 0 deletions(-)
20:00:48 <elliott> create mode 100644 README.md
20:00:48 <elliott> elliott@katia:~/Code/funge-archive/bench/fungicide$ git push
20:00:49 <elliott> fatal: '/home/deewiant/programming/projects/fungicide' does not appear to be a git repository
20:00:51 <elliott> Deewiant: What
20:00:54 <CakeProphet> so I guess this is just a shitty binding?
20:01:00 <elliott> drwxr-xr-x 8 elliott elliott 4096 2011-08-14 21:01 .git
20:01:03 <elliott> Deewiant: Your .txz contains .git
20:01:12 <Deewiant> That can happen
20:01:14 <fizzie> CakeProphet: WebFrame at least has a DOMDocument method in the objc WebKit API. Don't know about the .NET binding. Maybe it uses some .NET-level DOM thing, I think it might have one.
20:02:05 <elliott> Deewiant: Thankfully it's all text, so the whole repository probably won't be more than half a meg uncompressed
20:02:10 <elliott> Probably like three bytes compressed :P
20:02:17 <elliott> Apparently it's 148KB now
20:02:23 <CakeProphet> fizzie: I think this webkit runs over gtk#
20:02:35 <CakeProphet> I'll check again as soon as MonoDevelop stops being frozen...
20:02:59 <fizzie> There is at least some sort of Gtk# WebKit thing, yes.
20:03:22 <CakeProphet> yes, the one I'm using.
20:05:12 <CakeProphet> there is a hashtable on WebFrame called "data"
20:05:15 <fizzie> Mono's WinDorms implementation has Gecko and WebKit-based thingies, but I suppose those might well be something equally crappy, and I don't suppose you want to use Mono's WinForms mess for the rest of your thing.
20:05:20 <CakeProphet> but I enumerated over the keys and it's apparently empty.
20:05:39 <CakeProphet> must be some kind of general metadata thing.
20:06:07 <elliott> Deewiant: BTW, I take it that Fungicide is public domain or whatever
20:06:16 <elliott> Since it has no license notice and I don't like the idea of not being allowed to distribute it :-)
20:06:22 <elliott> This is how copyright law works
20:06:46 <Deewiant> Actually not
20:06:56 <elliott> Are you going to sue me :- (
20:07:14 <elliott> (I didn't notice there was no license until after)
20:07:15 <Deewiant> Expect a call from my lawyer
20:07:22 <elliott> I'm shaking in my boots :(
20:07:35 * elliott tries to work out how the hell your insane fingerprint system works.
20:07:40 <CakeProphet> I'm shaking on the floor, with my boots...
20:07:44 <CakeProphet> on
20:08:20 <CakeProphet> yeah there's nothing Dom-like on WebFrame... but there's a findFrame method but I doubt it's what I'm looking for.
20:09:03 <CakeProphet> if only there were people on IRC that like... knew stuff about these bindings.
20:09:16 <CakeProphet> I went to #webkit but they were are like "ARRRRGH DEV CHANNEL"
20:09:54 <CakeProphet> dev channels are serious business.
20:10:01 <elliott> so
20:10:03 <elliott> go to the
20:10:03 <elliott> non
20:10:04 <elliott> dev
20:10:05 <elliott> chanenl???
20:10:22 <Deewiant> elliott: What insane fingerprint system
20:10:35 <elliott> Deewiant: The one that uses D's insane metaprogramming
20:11:01 <Deewiant> Unhygienic macros whee
20:11:11 <CakeProphet> elliott: does such a thing exist?
20:11:12 <elliott> Deewiant: Never mind unhygienic; not even AST-based
20:11:18 <elliott> CakeProphet: Presumabmlkajbly
20:11:37 <CakeProphet> not on freenode.
20:11:47 <elliott> Deewiant: Hey remember when CCBI two was like ten times slower than the original and blocked on a compiler bug and Vorpal was all HA HA VAPOURWARE
20:11:48 <elliott> Me too
20:11:48 -!- sllide has joined.
20:12:50 <Deewiant> elliott: That bug still isn't fixed (at least officially; I haven't tested)
20:13:56 <elliott> Deewiant: Your stack is still strictly push/pop right? :-P
20:14:02 <elliott> I remember Vorpal going on about his EFFICIENT STRING PUSHING
20:14:18 <Deewiant> Err, somewhat
20:14:42 <elliott> Deewiant.......
20:14:43 <Deewiant> I think there might be some "gimme the top N cells" thing which just happens to be a single memcpy
20:14:44 <elliott> What have you done..............
20:14:50 <elliott> Deewiant: SOME OF US use linked list stacks
20:14:58 <Deewiant> And you suffer for it
20:15:38 <elliott> Deewiant: Not nearly as much as I suffer for my fungespace
20:15:39 <elliott> Probably
20:15:43 <elliott> Hmm, maybe I should optimise the stack first
20:15:46 <elliott> That's the lowest-hanging fruit ever
20:15:49 <elliott> Actually that's not true, coordinates are
20:15:51 <elliott> I'm using tuples
20:15:54 <elliott> Boxing + laziness
20:16:05 <elliott> At the same time (x,y) is a nice syntax.......
20:17:07 <Deewiant> (# x,y #)
20:17:18 <elliott> Deewiant: Now I can't use it as a function argument; sweet
20:17:31 <Deewiant> Your functions have the wrong kind
20:17:38 <Deewiant> Clearly
20:17:38 <elliott> lol
20:17:56 <elliott> Deewiant: Whenever you turn TRDS on in CCBI or, well, anything, it immediately starts leaking tons of memory forever, right?
20:18:00 <elliott> Or at least I don't see how it would avoid doing so
20:18:28 <Deewiant> "Starts leaking" sounds a bit bad :-P
20:18:34 <Deewiant> It takes a snapshot of the current state, yes :-P
20:18:41 <elliott> Well, it's memory, and it can never be reclaimed, and 90 percent of it is garbage
20:18:50 <elliott> That's the definition of a leak
20:18:50 <Deewiant> But it's a one-time hit
20:18:57 <elliott> Oh
20:19:05 <elliott> So if you travel back in time it just goes to the start and simulates until then?
20:19:07 <Deewiant> "Starts leaking" sounds like it loses memory every tick or something
20:19:08 <Deewiant> Yep
20:19:11 <elliott> I thought it saved every state and just rewound to that
20:19:18 <elliott> Deewiant: That's lame for things involving IO, it's not a real TARDIS :P
20:19:29 <Deewiant> It's the only reasonable way of doing it :-P
20:19:35 <elliott> ...and am I right in thinking that taking a snapshot of the state as of when TRDS was loaded, as opposed to at the beginning of the program, is stretching the spec?
20:19:37 <Deewiant> Unless you have a fancy Funge-Space with a lot of sharing
20:19:46 <Deewiant> In which case you might be able to do it even for many ticks
20:19:57 <Deewiant> No, you're not
20:20:10 <Deewiant> TRDS explicitly has a "earliest tick I can go to" command
20:20:14 <Deewiant> And it can be anything
20:20:32 <Deewiant> You could implement it as only ever allowing going to the future if you want to be a jerk about it :-P
20:21:02 -!- monqy has joined.
20:21:27 <Deewiant> Or maybe it requires it to be in the past, but I doubt Mike would've been that precise about it
20:21:39 <elliott> Heh
20:21:55 <elliott> Well
20:21:56 <Vorpal> <elliott> Deewiant: Not nearly as much as I suffer for my fungespace <-- what is your fungespace?
20:21:59 <elliott> The state at the start is easy
20:22:04 <elliott> You just need to store the contents of the file
20:22:12 <Vorpal> <Deewiant> I think there might be some "gimme the top N cells" thing which just happens to be a single memcpy <-- used for stack-stack no doubt?
20:22:14 <elliott> Vorpal: Yours, plus constant-time wrapping
20:22:36 <elliott> data FungeSpace = FungeSpace { spaceMap :: Map Vector Value
20:22:36 <elliott> , minCoords :: Vector
20:22:36 <elliott> , maxCoords :: Vector
20:22:37 <elliott> , rowPopulation :: Map Value Value
20:22:37 <elliott> , colPopulation :: Map Value Value }
20:22:37 <elliott> deriving (Show)
20:22:59 <Deewiant> Modulo the fact that Map is a (non-balancing?) binary tree and not a hash table
20:23:35 <elliott> It's also not micro-optimised bullshit, but it's the same structure theoretically, which is what matter
20:23:35 <elliott> s
20:23:57 <Deewiant> Well, a tree's a different data structure from a hash table :-P
20:24:08 <Deewiant> But yes it's an "associative array"
20:24:14 <Deewiant> Or whatever you want to call it
20:24:21 <Deewiant> Key-value store
20:24:56 <oerjan> i'm pretty sure Map is balanced.
20:25:24 <olsner> a red-black tree iirc
20:25:49 <Deewiant> The implementation of Map is based on size balanced binary trees (or trees of bounded balance) as described by: Stephen Adams, "Efficient sets: a balancing act", Journal of Functional Programming 3(4):553-562, October 1993, http://www.swiss.ai.mit.edu/~adams/BB/. J. Nievergelt and E.M. Reingold, "Binary search trees of bounded balance", SIAM journal of computing 2(1), March 1973.
20:27:24 <elliott> Deewiant: Your fingerprint mechanism essentially reduces to a big ol' list of fingerprint objects, right?
20:27:27 <elliott> Once all the metaprogramming crap is done
20:27:38 <elliott> I'm trying to take inspiration from systems solving totally different problems to mine ;D
20:28:25 <oerjan> fingerprinting should be done with finger trees, obviously
20:28:46 <elliott> oerjan: dont make me get that picture out again
20:29:01 -!- NihilistDandy has quit (Ping timeout: 260 seconds).
20:29:11 <Taneb> Is there such thing as a cellular automaton where the cells are in a tree?
20:29:15 <oerjan> no need, my brain looked it up
20:29:55 -!- Nisstyre has quit (Ping timeout: 250 seconds).
20:30:17 <oerjan> Taneb: hm well if you use a free noncommutative group as your space structure, you can get something like that
20:31:20 -!- NihilistDandy has joined.
20:32:37 <oerjan> like, up and down are still inverse, as are left and right, but going around in circles _without_ retracing your path does not end up at the same point
20:33:01 <Deewiant> elliott: Something like that yeah
20:33:15 <elliott> Deewiant: Right
20:33:16 <oerjan> it's still a group, so still uniform
20:33:19 <CakeProphet> Taneb: I think it would essentially be a tree-rewriting language with a fixed set of rewrite rules;.
20:33:38 <elliott> I could have a pretty near-perfect system if I could just get this stupid typeclass shit working
20:33:49 <oerjan> CakeProphet: well one where you can only change the tree _labels_, not the structure
20:34:06 <CakeProphet> ah yeah
20:34:20 -!- PatashuWarg has joined.
20:35:34 <Phantom_Hoover> <elliott> oerjan: dont make me get that picture out again
20:35:38 <Phantom_Hoover> What picture?
20:35:41 <elliott> Phantom_Hoover: NO
20:35:45 <oerjan> hm i suppose an infinite binary tree is more like the free group on three generators. oh hm the thing that makes that not quite a group is that to reverse going up, you must sometimes go down left and sometimes down right
20:35:49 <Phantom_Hoover> elliott, WHAT PICTURE
20:35:58 <elliott> Phantom_Hoover: NOOOOOOoooooooOOOooooooooOOOOOOOOOOOOOOOOOOOoOOOOOoooooOOOOoooOOOooooooooooo
20:35:58 <Phantom_Hoover> oerjan, why 3?
20:36:22 <olsner> elliott: what picture?
20:36:22 <oerjan> Phantom_Hoover: 3 edges from each node, up, down left and down right?
20:36:27 <oerjan> or wait hm
20:36:32 <Taneb> Only for a binary tree
20:36:36 <elliott> olsner: NOoooooOOOOOOOOOOOOOOOOooooooOOOOOOOOOOOOOOOooooOOOOOOOOOOOOOooooOOOOOOOOOOOoooooooooooooOOOOOOOOOOOOOOOOOOOOOooooooooooooOOOOOOOOOOOOOOOOOOOOOooooooooooooOOOOOOOOOOOOOOOOOOOOoooooooooooOOOOOOOOOOOOOOOOOOOOOOooooooooooooooooooooooooooooo
20:36:58 <oerjan> Phantom_Hoover: well it doesn't fit properly because "up" doesn't have a unique inverse
20:37:22 <elliott> Deewiant: Ew, ugly, each fingerprints' IP-specific state is going to be stored with its global state, not with the IP object. :/
20:37:28 <elliott> As in, a separate (Map IP IPState) in the fingerprint state.
20:37:29 <oerjan> essentially you have two kinds of nodes, left and right ones
20:37:30 <elliott> This makes me sad.
20:37:51 <Phantom_Hoover> oerjan, *ternary* trees, now...
20:38:58 <oerjan> Phantom_Hoover: even worse, now the inverse of "up" has _three_ options...
20:39:17 <Phantom_Hoover> oerjan, sure, but at least the isomorphism is more obvious.
20:39:20 <Taneb> Unary trees: isomorphic to linked lists?
20:39:21 <oerjan> hm unless maybe you lay it out differently
20:39:32 <oerjan> Taneb: pretty much?
20:39:35 <elliott> sheesh not even oerjan cut in to tell me I'm a bad person
20:40:41 <oerjan> Phantom_Hoover: oh right ternary trees work. in fact that's probably precisely what F_2 gives you (free group on two generators)
20:41:00 <Phantom_Hoover> Well, it's ruined a bit by the fact that the root node has 4 leaves.
20:41:32 <oerjan> Phantom_Hoover: um no root, _everything_ has four edges. to make this work you have to not really think of parents
20:41:55 <Taneb> Which ignores the original proposal completely
20:41:58 <Phantom_Hoover> oerjan, yes, but n-ary trees generally have a root node, no?
20:42:06 <Taneb> A cellular automaton on a tree
20:42:06 <CakeProphet> not formally.
20:42:35 <CakeProphet> >_> I think?
20:42:53 <CakeProphet> the root is just arbitrarily chosen.
20:43:01 <oerjan> Phantom_Hoover: i'm just pointing out that the free group on two generators has the structure of a ternary tree, although the directions are not intuitively matched in the same way
20:43:32 <oerjan> trees don't need to have roots, a rootless tree is just a connected acyclic graph
20:43:39 <CakeProphet> though I guess to be n-ary you actually do need a root...
20:43:55 <Phantom_Hoover> oerjan, hence 'n-ary'.
20:44:01 <Taneb> So, a cellular automaton on a tree is possible
20:44:08 <CakeProphet> because the root has n edges but every other node n+1 edges.
20:44:11 <Taneb> And isn't called anything else as far as we are aware?
20:44:16 <oerjan> although the "n-ary" term is intuively based on a rooted tree, since non-leaves have n+1
20:44:48 <fizzie> http://en.wikipedia.org/wiki/Unrooted_binary_tree but that's just a rather arbitrary term.
20:44:56 <CakeProphet> can't see the forest through all of the trees.
20:45:00 <CakeProphet> oh wait, yes you can.
20:45:41 <CakeProphet> forest is such a stupid way to say acyclic graph...
20:46:09 <CakeProphet> well, non-connected as well. I guess it's shorter to say
20:47:23 <fizzie> But do note that to a mathematician, a single tree is already a forest.
20:47:48 <Vorpal> fizzie, how so?
20:47:56 <Vorpal> oh yes the special case of 1
20:48:10 <fizzie> I guess it's not a "proper forest", though.
20:48:16 <fizzie> Compare subset/proper subset.
20:48:26 <fizzie> So maybe it's intuitive enough.
20:48:43 <elliott> ?pl \x -> (f x, x)
20:48:44 <lambdabot> (,) =<< f
20:48:55 <Deewiant> first f . join (,)
20:49:10 <oerjan> best forest: {}
20:49:38 <CakeProphet> best forest: your mom
20:49:59 <Taneb> Is it possible to define a tree as a recursive tuple?
20:50:05 <Vorpal> I have to say that wine is getting bloody amazing. I'm using a shader-heavy DirectX 9c program and there are absolutely no issues in it
20:50:38 <Taneb> Like t is a tuple (bit,bit|t,bit|t)
20:51:03 <Taneb> Is that even a tuple?
20:52:45 <oerjan> apart from syntax, it's pretty much a haskell algebraic datatype
20:53:14 <fizzie> $ cabal
20:53:14 <fizzie> The program 'cabal' is currently not installed. To run 'cabal' please ask your administrator to install the package 'cabal-install'
20:53:14 <fizzie> ^ sadness
20:53:43 <oerjan> data T = T Bit (Either Bit T) (Either Bit T)
20:53:51 <Deewiant> fizzie: That's not a hard problem to solve
20:54:16 <Phantom_Hoover> fizzie, are you your administrator or are you actually (gasp) using a multi-user system?
20:54:28 <fizzie> Phantom_Hoover: I am not an administrator there, no.
20:54:44 <fizzie> Though generally "please install X for me" tickets have been solved in a day or so.
20:54:45 <Phantom_Hoover> :O
20:55:07 <Phantom_Hoover> fizzie, how are you not administrator on everything ever you are so trustworthy.
20:55:09 <CakeProphet> I wonder what would happen if I installed every package in all of my repos
20:55:26 <oerjan> more likely to be written something like data T = Leaf Bit | T1 Bit T | T2 Bit T T
20:55:27 <fizzie> Phantom_Hoover: It's at work, there's a Policy(tm).
20:55:37 <oerjan> er wait
20:55:38 <Phantom_Hoover> fizzie, SO TRUSTWORTHY
20:55:43 <oerjan> not the same
20:55:46 <elliott> <fizzie> $ cabal
20:55:46 <elliott> <fizzie> The program 'cabal' is currently not installed. To run 'cabal' please ask your administrator to install the package 'cabal-install'
20:55:46 <elliott> <fizzie> ^ sadness
20:55:54 <elliott> fizzie: You want to run your own GHC really
20:55:58 <elliott> The distro packages are Really Bad.
20:56:09 <Deewiant> Howso
20:56:12 <elliott> Binary GHC package + source Haskell Platform is usually pretty painless
20:56:20 <elliott> Deewiant: If you just use distro packages, everything is fine
20:56:28 <elliott> Deewiant: If you mix and match with native cabal, version conflicts ahoy
20:56:32 <elliott> And if you ever get a package from both, god help you
20:56:37 <elliott> And you will because cabal is terrible
20:56:40 <Deewiant> I haven't run into problems thus far
20:56:55 <Deewiant> But I haven't been using Haskell heavily lately so maybe I've been lucky
20:57:04 <elliott> http://www.vex.net/~trebla/haskell/sicp.xhtml has a bunch of boring information on it
20:57:19 <elliott> Admittedly Arch is likely to have less problems than Debian in this area
20:57:28 <elliott> But distros lag behind for GHC anyway
20:57:49 <CakeProphet> elliott: of course cabal is terrible, it's written by Haskell-using eggheads. bahahahahaha!
20:57:52 <CakeProphet> >_>
20:58:41 <CakeProphet> they probably love Woodrow Wilson.
20:59:36 <fizzie> The system in question is Ubuntu 10.10, and it has ghc6 and a random sampling of libghc6-foo-dev packages (hunit, mtl, network, parsec2, quickcheck2, regex-base, uulib, x11, x11-xft, xmonad-contrib, xmonad, zlib) installed from the reposies.
21:00:05 <CakeProphet> only US president that had a Ph.D
21:00:20 <Taneb> In what?
21:00:49 <oerjan> ais523: them spammers are being persistent today
21:01:01 <CakeProphet> history and political science
21:01:09 <Taneb> Not bad
21:01:16 <ais523> wow, indeed
21:01:30 <ais523> and I'm just an admin, and they registered accounts, so I can't give them more than a 24-hour block even if I thought it would help
21:02:00 <oerjan> eek
21:03:43 -!- elliott has quit (Ping timeout: 252 seconds).
21:03:47 <ais523> you need checkuser privileges (if the extension is installed), or db access privileges (if it isn't), to do a longer block than that
21:03:55 <ais523> I can block the accounts themselves, but that's pointless
21:03:58 <ais523> as they just make the one post
21:04:18 <CakeProphet> okay so... anyone know anything about webkit# or gtk#
21:05:17 <oerjan> "Wilsonianism calls for the United States to enter the world arena to fight for democracy, and has been a contentious position in American foreign policy."
21:05:21 <oerjan> you don't say.
21:05:24 <fizzie> CakeProphet: I know that from a brief look the webkit-sharp binding looks really bare.
21:05:41 -!- elliott has joined.
21:05:49 <Deewiant> f &&& id
21:05:53 <CakeProphet> fizzie: awesome.
21:05:59 <CakeProphet> mabybe I should find another set of tools.
21:06:11 <elliott> 21:01:30: <ais523> and I'm just an admin, and they registered accounts, so I can't give them more than a 24-hour block even if I thought it would help
21:06:14 <elliott> huh what
21:06:15 <Phantom_Hoover> :t (&&&)
21:06:16 <lambdabot> forall (a :: * -> * -> *) b c c'. (Arrow a) => a b c -> a b c' -> a b (c, c')
21:06:18 <elliott> oh
21:06:22 <elliott> you mean block their ip
21:06:23 <elliott> right
21:07:07 <CakeProphet> so then what's something I can use in mono that a) renders webpages b) has a DOM interface
21:07:13 <CakeProphet> maybe there's Gecko bindings.
21:07:18 <Taneb> Oh god
21:07:18 <elliott> Deewiant: is it good to base my encapsulation mechanism on module scope or is it better to have something ever so slightly uglier that is type safefwfe..........
21:07:23 <Taneb> I know these spambots
21:07:30 <Taneb> The mezzawiki was haunted by them
21:07:33 <fizzie> CakeProphet: There seems to be one "good" (for some values of good) .NET binding of WebKit, and that's Awesomium, which is some sort of proprietary-commercial thing that has free-as-in-beer licenses, and the Mono support seems rather... like an afterthought, if even that.
21:07:39 <Deewiant> elliott: Type safety is good
21:07:45 <Taneb> The owner eventually blocked new user account regisration
21:07:47 <elliott> Deewiant: thisis true
21:07:49 <Taneb> The owner being DMM
21:07:59 <CakeProphet> fizzie: so what you're telling me is
21:08:04 <CakeProphet> I should find Gecko bindings.
21:08:08 <elliott> fpREFC :: Fingerprint
21:08:08 <elliott> fpREFC =
21:08:08 <elliott> Fingerprint
21:08:08 <elliott> { fpName = packName "REFC"
21:08:08 <elliott> , fpInitialGlobalState = newRefStore
21:08:09 <elliott> , fpInitialIPState = return ()
21:08:11 <elliott> , fpHandles = [D,R]
21:08:13 <elliott> , fpRun = run }
21:08:15 <elliott> much nicer than a class instance
21:08:19 <CakeProphet> or use something like jssh to drive Firefox 3.6 with Javascript.
21:08:23 <elliott> also probably much less stupid oevrhead
21:08:25 <elliott> plus
21:08:27 <elliott> about ten fewer language extensions
21:09:16 <fizzie> CakeProphet: Well, I don't know what you want. But I think there is a Gecko binding for the embed-gecko-in-gtk scenario. I don't know how well that one does the "expose DOM to .NET" thing.
21:09:38 <CakeProphet> fizzie: the person who hired me is working on a browser automation scripting engine thing.
21:09:45 <CakeProphet> and wants a linux port... using basically anything.
21:10:11 <CakeProphet> I can use any kind of backend to display and control a rendered web page.
21:10:18 <elliott> Deewiant: techiecniecialy it is typjepesafe... it would just mean that fingerprints could (theoretically) access the data of other fingerprints, if the module exports did not prevent that
21:10:24 <CakeProphet> but it has to work with Mono/C#
21:10:42 <CakeProphet> I guess it would be frontend actually. a rendering engine is a frontend. :P
21:10:47 <Deewiant> elliott: Some fingerprints need to interact anyway
21:11:00 <elliott> Deewiant: Hmm, like what
21:11:03 <elliott> That would poke a major hole in my model ;-)
21:11:04 <Deewiant> SOCK/SCKE :-P
21:11:22 <elliott> Deewiant: Bleh
21:11:27 <Deewiant> Blame fizzie for that one
21:11:36 <oerjan> <Taneb> The mezzawiki was haunted by them <-- btw last i checked i couldn't find any link to the mezzawiki on any of the iwc, d&d or mezzacotta frontpages
21:11:39 <elliott> fizzie: shakes fist
21:11:50 <Taneb> oerjan: It was very secretive
21:12:02 <elliott> Deewiant: I'll probably do that one by adding the shared socket state to FungeState directly
21:12:08 <Taneb> oerjan: http://mezzacotta.net/wiki/Main_Page
21:12:23 <elliott> Vorpal: How's ATHR
21:12:32 <fizzie> Yeah, SCKE was not really a good idea. But perhaps you can opt to just support the (nonexistant) NSCK.
21:12:46 <fizzie> CakeProphet: Well, gecko-sharp is at least part of mono, based on the fact that the download links point to ftp.novell.com/pub/mono/sources/. It might not do the DOM any better though.
21:13:28 <elliott> fizzie: Has anyone who isn't you ever used SCKE?
21:13:42 <fizzie> elliott: Not to my knowledge, no.
21:14:13 <fizzie> Actually I'm not really sure "used" is a right word for my case either.
21:14:15 <elliott> fizzie: I'll implement it anyway out of general masochism but we could just bribe you to stop using it.
21:14:21 <Deewiant> The same goes for SOCK :-P
21:14:32 <fizzie> Because fungot doesn't use it either, I never got that HTTP client part done.
21:14:32 <fungot> fizzie: you have a great appreciation for the fine arts. you use the hammer and nails. they will come a day
21:14:57 <CakeProphet> fizzie: well seeing as webkit# seemingly has no DOM at all, anything would instantly be "better"
21:15:04 <elliott> Deewiant: There are more Funge implementors in the world than programmers, which wouldn't be surprising (see brainfuck) if not for the fact that it's so damn hard to implement and quite easy to code in
21:15:37 <Vorpal> <elliott> Vorpal: How's ATHR <-- feeling well
21:15:38 <Deewiant> I shouldn't've made Mycology, it made it too easy to implement
21:15:47 <Vorpal> just asked it
21:15:52 <elliott> Vorpal: Is it implementable
21:15:55 <elliott> Deewiant: Speak for yourself
21:15:58 <Vorpal> elliott, forgot XD
21:16:23 <elliott> Deewiant: Also try to avoid generalising based on Vorpal's ability to copy CCBI code ;-)
21:16:30 <elliott> See with you, I just coerced the code out in English form slowly.
21:16:54 <oerjan> <Taneb> oerjan: It was very secretive <-- oh so it's not _intended_ to be findable by ordinary visitors?
21:17:20 <fizzie> CakeProphet: Well, I grepped the Gecko.WebControl APIdoc .xml file (I can't figure out how to actually show that with monodoc without installing it somewhere, and it's not easily findable in the web) and the only thing matching "dom" (case-insensitively) is some event-handlers.
21:18:11 <elliott> fizzie: It might be like .getDocument
21:19:14 <pikhq> Deewiant: I'd say it really hasn't made it too easy to implement.
21:19:30 <elliott> Says someone who's never done it
21:19:47 <pikhq> Deewiant: Just harder to unintentionally fuck it up.
21:19:54 <elliott> Really at this point it's a vehicle for me to show how awesome Haskell is ;-)
21:20:26 <elliott> And also to convince fizzie that he should run fungot on it, once I can prove it runs faster than cfunge.
21:20:26 <fungot> elliott: just be patient, the answer, the fact remained except the pony a begrudging pat, as gently in the horn fell off. dammit.
21:21:14 <Vorpal> elliott, as far as I remember most of ATHR is implementable but not really the inter-thread communication stuff
21:21:25 <Vorpal> that needs reworking
21:21:47 <elliott> Vorpal: Please let me know when it exists, it'll be fun figuring out interactions between it and TRDS
21:22:05 <Vorpal> elliott, well I will leave that part completely up to you
21:22:22 <elliott> Vorpal: What part
21:22:25 <Vorpal> elliott, I would assume TRDS happens inside each ATHR thread, but bugger all of you go back past a ATHR fork
21:22:43 <Vorpal> elliott, the part of figuring out interactions
21:22:44 <Gregor> elliott: muuuuuuuuuuuuuuuuuudem
21:24:01 <elliott> Gregor: Can't you fix the three lines that need changing yourself :P
21:25:06 <Gregor> Are there only three lines that need changing?
21:25:46 <Gregor> Last I recall, it's still in non-buffering land.
21:25:57 <CakeProphet> fizzie: well uh... apparently C# bindings suck.
21:26:01 <CakeProphet> and I just need to use jssh.
21:26:02 <elliott> Gregor: Uhh, both ends use select
21:26:05 <elliott> And buffer
21:26:12 <elliott> I don't know WHICH three lines need changing
21:26:16 <elliott> But it should, conceptually, work
21:26:41 <Gregor> Ahhhhhhhhhhhhhhhhhhhhhhhh
21:26:55 <elliott> Gregor: Just see my latest sprunge links :P
21:26:59 <elliott> Whenever those were
21:27:41 <Gregor> http://sprunge.us/CUiE is the latest I have
21:27:44 <fizzie> CakeProphet: The browser backends supported by monodoc are Gecko, GtkHtml, WebKit and MonoWebBrowser; you'd probably have to pick one of those to actually render a page. All of them seem quite hacky. (And GtkHtml will not support much of anything.)
21:28:45 <elliott> Gregor: Looks right to me
21:28:51 <elliott> Gregor: It selects on both ends, it has buffers
21:29:00 <elliott> Just Doesn't Work(tm)
21:29:21 <elliott> I'm too tired to debug it today, I'll have a look tomorrow if you don't miraculously twiddle it into workingness :P
21:29:31 <Gregor> Pff
21:29:49 <CakeProphet> software problems | Functor? I hardly knew 'er! | http://codu.org/logs/_esoteric/
21:29:53 -!- CakeProphet has set topic: software problems | Functor? I hardly knew 'er! | http://codu.org/logs/_esoteric/.
21:29:56 <CakeProphet> :3
21:30:10 <sllide> funky
21:30:46 <fizzie> CakeProphet: At least Mono.WebBrowser's IWebBrowser interface has a Document property that gives you an IDocument, which is from a Mono.WebBrowser.DOM namespace, which seems to have interfaces corresponding to a DOM tree.
21:31:05 <fizzie> (The underlying machinery there is Gecko via gluezilla.)
21:31:11 <CakeProphet> fizzie: this is good...
21:32:11 <elliott> lol gecko
21:32:19 <fizzie> (I have no idea why none of this shows up in the online monodoc thing; I had to fetch the mono-2.10.2.tar.bz2 source-ball and peek at the .cs files in mcs/class/Mono.WebBrowser/.)
21:32:53 <CakeProphet> fizzie: what does WebBrowser render on top of?
21:32:56 <CakeProphet> gtk#?
21:33:39 <fizzie> CakeProphet: That's a good question; it's official use case is to be the browser control in the Mono WinForms implementation.
21:33:55 <fizzie> Oh.
21:34:10 <fizzie> "Mono.WebBrowser is also a class library, but a private one (i.e., it's in the gac but can't be "discovered" by pkg-config tools since it doesn't ship a .pc file. It can obviously be linked to directly). Winforms depends on it directly, and it exposes interfaces that hide browser engine implementation details. The interfaces are more in line with the DOM spec, but are not as complete, mainly because the .NET Winforms WebBrowser control is not feature-complete i
21:34:10 <fizzie> n itself."
21:34:22 <fizzie> Heh, it doesn't sound terribly usable as a standalone component.
21:35:19 <CakeProphet> uuuugh
21:35:32 <CakeProphet> that entire paragraph
21:35:40 <CakeProphet> is pretty much nonsense to me.
21:36:36 <fizzie> As far as I can tell it translates mostly down to "it's not really meant to be used directly, just by the WinForms browser control".
21:37:18 <fizzie> I don't know how "serious" that is and whether some stuff does in fact use it directly.
21:37:35 <fizzie> At least there is an interface there. (It abstracts over Gecko and WebKit backends, turns out.)
21:37:44 <Gregor> elliott: I think I know the problem. If you have no data to send, you should not have it in the write set for select(). IIRC, it will only signal that the write buffer is ready once; you must write() at least once for it to signal again.
21:37:58 <elliott> Gregor: Ah.
21:38:10 <elliott> Easy enough to fix, just filter for non-empty write_buffer
21:38:24 <elliott> Oh, except that conns don't know their conn_id
21:38:36 <elliott> But whatever you can just get it from handle_for_id and then add the stdio thing
21:38:36 <Gregor> elliott: Nope, I'm a terrible liar.
21:38:41 <elliott> derp
21:39:30 <Gregor> elliott: Although I /do/ think it will be a busy loop that way, that doesn't seem to be the bug.
21:39:30 <elliott> Gregor: Go on
21:39:39 <elliott> Yay :P
21:40:00 <Gregor> (Still verifying)
21:40:39 <fizzie> select is level-triggered, isn't it not? It'll keep telling you "yes you can write" as long as you actually can write.
21:40:56 <Gregor> fizzie: Yup.
21:41:07 <Gregor> Which makes this a busy loop, which is less than ideal, but not the bug :P
21:41:24 <elliott> Gregor: Have I mentioned how easy this would be in @ :-P
21:41:28 <elliott> Seriously Unix IO is so terrible AUGH
21:42:32 <Gregor> elliott: What the bloody huh? host.py is in a loop of thinking it can read from stdin, then reading nothing ...
21:43:47 <CakeProphet> fizzie: can't seem to find Mono.Mozilla or Mono.Webkit
21:44:36 <elliott> Gregor: Hmm
21:44:39 <elliott> Gregor: That means stdin is EOF
21:44:47 <elliott> I just assumed EOF would never happen :D
21:45:29 <Gregor> Oh, lul, didn't notice socket.error: [Errno 98] Address already in use
21:45:44 <elliott> lol
21:49:46 <Vorpal> elliott, EOF on stdin can happen easily.
21:51:39 <elliott> No shit
21:53:23 <CakeProphet> fizzie: so yeah there's an IWebBrowser interface but there doesn't seem to be an actual base class.
21:53:34 <elliott> now to construct
21:53:56 <elliott> forall cat a r. (Category cat, forall b. Applicative (cat b)) => a -> cat (cat (a, cat a a) r) r
21:54:01 <elliott> CAN IT EVEN BE DONE
21:54:26 <Deewiant> ?djinn forall cat a r. (Category cat, forall b. Applicative (cat b)) => a -> cat (cat (a, cat a a) r) r
21:54:27 <lambdabot> Cannot parse command
21:54:31 <Deewiant> Signs point to "no"
21:54:34 <elliott> Deewiant: That's not even a valid Haskell signature
21:54:35 <elliott> With any extensions
21:54:44 <elliott> Can't forall in a context like that
21:54:51 <elliott> And djinn doesn't even begin to handle half of any of that anyway :P
21:55:47 <Vorpal> elliott, what is djinn?
21:55:54 <elliott> A thing
21:56:02 <elliott> ?djinn (a -> b -> c) -> (b -> a -> c)
21:56:02 <lambdabot> f a b c = a c b
21:56:12 <elliott> ?djinn a -> (b -> a) -> Maybe b -> a
21:56:12 <lambdabot> f a b c =
21:56:12 <lambdabot> case c of
21:56:12 <lambdabot> Nothing -> a
21:56:12 <lambdabot> Just d -> b d
21:56:16 <oerjan> 10:10:02 <elliott> data Conservative a = Precise !a | Imprecise !a
21:56:16 <oerjan> 10:10:03 <elliott> that's a Functor
21:56:18 <elliott> ?djinn (a -> a) -> a
21:56:18 <lambdabot> -- f cannot be realized.
21:56:35 <Vorpal> err, can't it?
21:56:45 <oerjan> no it's not it breaks on fmap (const True) . fmap (const undefined) >:)
21:57:07 -!- variable has joined.
21:57:14 <elliott> Vorpal: not in a logically sound manner
21:57:15 <elliott> oerjan: wat
21:57:19 <elliott> heh
21:57:21 <Vorpal> elliott, okay that is true
21:57:32 <Vorpal> ?djinn a -> a
21:57:32 <lambdabot> f a = a
21:57:41 <Vorpal> ?djinn a -> b
21:57:41 <lambdabot> -- f cannot be realized.
21:57:43 <Vorpal> hm right
21:57:52 <Vorpal> ?djinn a -> b -> b
21:57:53 <lambdabot> f _ a = a
21:57:59 <Vorpal> ?djinn a -> a -> a
21:57:59 <lambdabot> f _ a = a
21:58:03 <Gregor> elliott: I think somebody's disagreeing on the protocol somewhere ...
21:58:09 <Vorpal> well there are a lot of interpretations for that
21:58:13 <Vorpal> Gregor, btw what are you doing?
21:58:25 <Gregor> elliott: After getting the initial connection command, the host is receiving a command of length 1, unprintable character.
21:58:28 <Gregor> Vorpal: MAGIC
21:58:49 <Vorpal> Gregor, the gathering?
21:58:49 <Gregor> elliott: Specifically, 0 ...
21:59:03 <elliott> Gregor: Nice :P
21:59:11 <elliott> Gregor: It might be a write string call or whatever
21:59:14 <elliott> Gregor: Guest might not be sending "c"
21:59:18 <Vorpal> Gregor, I bet zzo38 will be interested in it if it is that
21:59:24 <elliott> <Vorpal> well there are a lot of interpretations for that
21:59:29 <elliott> Vorpal: All proofs are indistinguishable
21:59:38 <Gregor> elliott: What the heww? Why was handle_connection sending the error code back?
21:59:46 <elliott> Gregor: Oh
21:59:48 <Vorpal> elliott, err. Hm
21:59:51 <Gregor> elliott: err = read_short() \n write_short(err) # whuuuu?
21:59:52 <elliott> Gregor: Probably it meant to send to the "TCP client"
21:59:54 <elliott> Who does not exist any more
21:59:59 <elliott> And I forgot that you have to specify destinations
22:00:01 <elliott> Yeah
22:00:16 <Gregor> elliott: You'se gots lots o' protocol problems here, bub
22:00:46 <elliott> Gregor: Just remove the write_short(err) :P
22:01:02 <Vorpal> <Vorpal> elliott, err. Hm
22:01:02 <Vorpal> <Gregor> elliott: err = read_short() \n write_short(err) # whuuuu?
22:01:17 <Vorpal> hm... seems I'm clairvoyant
22:01:38 <Vorpal> (I even got the column of the text right)
22:01:56 <oerjan> Vorpal: i think ?djinn works in a terminating language only superficially similar to haskell
22:02:02 <Vorpal> oerjan, ah
22:02:18 <oerjan> so as to be logically sound in the curry-howard sense
22:02:19 <elliott> argh how does this work
22:03:04 <oerjan> also it doesn't really support recursion, even terminating
22:03:07 <elliott> aha
22:03:33 <Gregor> elliott: Still no go
22:04:27 <oerjan> ?djinn ((b -> a) -> a) -> a
22:04:28 <lambdabot> -- f cannot be realized.
22:05:26 <oerjan> hm that's not right is it
22:05:37 <oerjan> for pierce's law
22:05:53 <elliott> Gregor: Huh
22:06:10 <oerjan> ?check \a b -> ((b <= a) <= a) <= (a :: Bool)
22:06:11 <lambdabot> "Falsifiable, after 1 tests:\nFalse\nTrue\n"
22:06:39 <oerjan> ?check \a b -> ((b <= a) <= a) <= (b :: Bool)
22:06:40 <lambdabot> "Falsifiable, after 1 tests:\nTrue\nFalse\n"
22:07:47 <CakeProphet> 18:07 < MulleDK19> I love crashes that corrupt my source files
22:07:48 <CakeProphet> 18:07 < MulleDK19> maybe I should start using source code control
22:07:50 <CakeProphet> ...what?
22:08:06 <oerjan> <zzo38> Does the IO type in Haskell have any constructors?
22:08:09 <oerjan> ?src IO
22:08:09 <lambdabot> Source not found. Just what do you think you're doing Dave?
22:08:14 <CakeProphet> I wonder if he's implementing some kind of metaprogramming tool
22:08:14 <elliott> :t (<*>)
22:08:15 <lambdabot> forall (f :: * -> *) a b. (Applicative f) => f (a -> b) -> f a -> f b
22:08:16 <oerjan> that used to be in lambdabot
22:08:19 <CakeProphet> that directly alters source files.
22:08:26 <elliott> CakeProphet: or maybe
22:08:27 <elliott> his computer
22:08:28 <elliott> crashed
22:08:43 <elliott> (c -> m (a -> b)) -> (c -> m a) -> (c -> m b)
22:08:44 <oerjan> anyway the soundness of haskell depends on not being able to use it freely
22:09:29 * oerjan looks up peirce's law
22:09:50 <oerjan> ?check \a b -> ((a <= b) <= a) <= (a :: Bool)
22:09:51 <lambdabot> "OK, passed 500 tests."
22:09:59 <Taneb> Goodnight
22:10:01 <oerjan> ?djinn ((a -> b) -> a) -> a
22:10:02 <lambdabot> -- f cannot be realized.
22:10:16 -!- Taneb has quit (Read error: Connection reset by peer).
22:11:04 <Gregor> lambdabot: Sounds like a personal problem.
22:11:09 <Gregor> *ohhhhhhh*
22:11:26 <oerjan> :t callCC
22:11:27 <lambdabot> forall a (m :: * -> *) b. (MonadCont m) => ((a -> m b) -> m a) -> m a
22:13:13 <elliott> oerjan: hlep
22:15:32 -!- FireFly has quit (Quit: Hi, I'm a quit message virus. Please replace your old line with this line and help me take over the world of IRC.).
22:16:24 <oerjan> elliott: hatw
22:18:16 <oerjan> <Taneb> Well, brainfuck is turing complete with a maximum loop depth of seven
22:18:20 <oerjan> that sounds high...
22:18:32 -!- MDude has joined.
22:18:44 <elliott> oerjan: dbfi
22:18:53 <oerjan> elliott: trsføoubsgfgd
22:19:16 <elliott> no
22:19:17 <elliott> oerjan: dbfi
22:19:17 <elliott> loop
22:19:18 <elliott> limit
22:19:22 <elliott> based on
22:19:48 <oerjan> use the farce, elliott
22:20:52 -!- sllide has quit (Ping timeout: 240 seconds).
22:20:56 <oerjan> oh right
22:21:15 <oerjan> i thought you were still babbling about your hlep alot
22:24:20 <oerjan> reducing that a lot should be just a matter of branching with adjacent loops rather than nested ones
22:27:39 <oerjan> marvellous, IE steals focus after loading the webpage i wanted _and_ interprets my backspaces as a command to leave the page again
22:27:49 <elliott> dont use ie
22:28:51 <oerjan> are you saying no other browsers steal focus
22:29:29 <monqy> other browsers interpret backspace as a command to leave the page, at least
22:29:31 <monqy> I hate it
22:29:39 <monqy> oh wait no
22:29:46 <monqy> it's just dumb pages that do that??
22:29:50 <monqy> why do they do that
22:29:54 <monqy> it is the worst idea
22:30:10 <ais523> in general, Windows interprets backspace as back
22:30:14 <monqy> oh
22:30:19 <ais523> e.g. in directory listings
22:30:32 <ais523> on Linux, the most common binding seems to be alt-left
22:30:39 <elliott> <oerjan> are you saying no other browsers steal focus
22:30:52 <elliott> chrome has never stolen my focus
22:31:02 <elliott> oerjan: and chrome remembers form details on returning to a page through history
22:31:04 <elliott> as does firefox
22:31:08 <elliott> making it much less annoying
22:31:09 <oerjan> ais523: alt-left also works, it's what i use when i do it deliberately
22:31:14 <elliott> dunno if ie does that nowadays
22:31:24 * Sgeo starts reading why's poignant guide to ruby
22:31:32 <monqy> chromme appears not to do backspacery when there isn't javascript that makes the backspacery happen
22:31:39 <monqy> why anyone would make that javascript is beyond me
22:31:52 <Sgeo> Backspace = back is pain
22:32:20 <oerjan> i can do a lot of grumbling about how programs should not interpret text entry keys as commands but it all stumbles into the fact i use vim :P
22:33:31 <monqy> well at least vim has different modes for that stuff and is generally predictable about it???
22:33:45 <oerjan> i've several times been annoyed when i accidentally typed an n or a q into simon tatham's puzzle windows
22:39:55 -!- elliott has quit (Ping timeout: 246 seconds).
22:44:21 -!- Nisstyre has joined.
22:47:40 <Phantom_Hoover> oerjan, vim???? DIE
22:48:03 <Phantom_Hoover> * Sgeo starts reading why's poignant guide to ruby
22:48:13 <Phantom_Hoover> I thought you'd already loved and lost Ruby.
22:48:30 <Sgeo> Did I ever say I loved it? I don't remember
22:48:42 <Sgeo> I'm pretty sure that I would have lost it to Smalltalk
22:49:08 <Sgeo> But I want a refresher, I guess
22:50:05 <monqy> I remember disliking ruby
22:50:24 <CakeProphet> I hate everything.
22:50:41 <CakeProphet> I'm going to smoke hookah and contemplate a solution to all of this.
22:51:57 <CakeProphet> I actually like Ruby though I know very little practical knowledge of it
22:52:09 <CakeProphet> just the syntax/some-semantics
22:54:49 <oerjan> such a rube
22:57:50 -!- itidus20 has joined.
22:59:55 <Phantom_Hoover> itidus20!
23:00:29 <itidus20> Ph:!
23:00:32 <itidus20> hmm
23:00:36 <itidus20> Phantom_Hoover: !
23:01:11 <Phantom_Hoover> itidus2432902008176640000
23:02:30 <Phantom_Hoover> Sgeobot, check for updates.
23:03:52 <oerjan> oh no, you've summoned itidus20's evil clone!
23:04:15 <Phantom_Hoover> oerjan, quick, get your evil twin to fight him!
23:08:25 <CakeProphet> this is hopeless.
23:09:37 <Phantom_Hoover> There is always hope.
23:10:30 <Phantom_Hoover> Except for the release of the HURD.
23:11:43 <CakeProphet> no, there's no hope
23:11:47 <CakeProphet> this approach isn't going to work.
23:12:09 <CakeProphet> all bindings for web browser rendering engines in Mono C# are stupid.
23:14:11 <CakeProphet> Mono.WebBrowser has all of these DOM interfaces... but, uh, no actual code.
23:14:57 <Phantom_Hoover> http://hyotynen.kapsi.fi/trekfailure/
23:15:13 <Phantom_Hoover> This... this is completely identical to authentic Treknobabble.
23:15:27 <Phantom_Hoover> They should sell it.
23:29:23 <itidus20> procedural generation is popular in part because it reduces the necessary labor and is more productive. on the downside, the lack of direct human control over each generated thing imbibes a lack of meaning in the created content
23:30:05 <itidus20> having said this the failure generator is pretty awesome
23:31:48 <fizzie> fungot: Did you notice he called you meaningless?
23:31:48 <fungot> fizzie: and just what your porkhollow's fat ass needs. when the full chain was nearly closed that you would have a mayoral business which you take very seriously and you will defend this package with your life.
23:33:30 <itidus20> fizzie: i just want to ramble on about it like captain picard.. except not into a lonely document.. but into a channel
23:34:54 <itidus20> I like discovering tradeoffs. Because explanations based on tradeoffs lend themselves to objectivity.
23:35:27 <itidus20> So the tradeoff is the productivity of procedural generation versus the intimacy and warmth of manual creation
23:35:51 <monqy> solution: slave labour
23:37:03 <itidus20> The way I see it, humans reject _some_ procedural things because they sense that they are being cheated.
23:37:47 <monqy> maybe you do
23:37:56 <monqy> I personally like procedural things
23:38:18 <itidus20> For instance, most people would rather not read a procedurally generated textual novel.
23:38:30 <monqy> I'd love it
23:38:34 <Sgeo> itidus20, that's because the procedures aren't good enough yet
23:38:35 <Sgeo> >.>
23:38:42 <monqy> bad procedures are cute
23:38:54 <itidus20> theres a difference between sampling a procedure and reading a whole slab of it
23:39:12 <monqy> the difference is slabs are bigger
23:39:12 <itidus20> now.. uhh.. having said this..
23:39:26 <itidus20> no no wait umm
23:39:29 <itidus20> hm
23:39:41 <itidus20> well people read novels because there is value in them
23:40:27 <itidus20> but a novel full of procedurally generated content is likely to leave a person feeling cheated
23:40:40 <CakeProphet> fungot: write a novel
23:40:40 <fungot> CakeProphet: this is a really hot look for a stronger! but you were asleep. how exciting! a realm that is a ring
23:41:21 <CakeProphet> fungot: write a novel
23:41:21 <fungot> CakeProphet: what a surprise, you are dragging your schizophrenic hopping
23:41:36 <CakeProphet> fungot: write a novel
23:41:36 <fungot> CakeProphet: of what?! no man, cage is sweet. so sweet. so sweet. so sweet. you feel pangs of jealousy, though in a way that it shakes is the same as the word " crazy"
23:41:47 <itidus20> hehe
23:42:00 <itidus20> ok that was pretty cool
23:42:27 <CakeProphet> uuuugh
23:42:36 <itidus20> i actually like that one :-s
23:42:38 <CakeProphet> I am going to fucking bash my head into a sturdy solid object.
23:42:49 <CakeProphet> or, just use jssh to do this crap.
23:44:04 <itidus20> i dont hate procedural stuff. i am sure there are solutions where hybrid uses of procedural generation and manual generation can be greater than the sum of the parts
23:46:40 <itidus20> i think that if you procedurally generate something.. and then.. proceed to shape it with only manual stuff, you can win out.. that would be what minecraft did
23:47:44 <Phantom_Hoover> Wha?
23:47:47 <itidus20> if the demarcation between when the procedural generation begins and ends is clear that would help a lot
23:48:04 <Phantom_Hoover> Procedural generation... doesn't make sense without manual stuff.
23:48:18 <zzo38> itidus20: Yes I think it can be possible to make things in that way; possibly music can be done, or other things. Possibly it can experiment using random output of FurryScript to do stuff such as D&D game and then modify stuff. The included scripts are too simple for that but you can improve it to do that
23:48:38 <Phantom_Hoover> You need, at some point, to define a function from noise to interactale stuff.
23:48:44 <Phantom_Hoover> *interactable
23:49:10 <itidus20> ok a much nicer way to say it is
23:49:42 <itidus20> you could use procedural generation to establish the initial state... but then get humans to carry it forward from there
23:50:29 <Phantom_Hoover> Procedural generation is a matter of mapping a very very large set of meaningless values to something that can be perceived as having a certain structure.
23:50:43 <itidus20> in mezzacotta.. humans vote on which days are good
23:50:47 <itidus20> :D
23:50:53 <itidus20> so that adds value
23:50:54 <Phantom_Hoover> And that's... different.
23:51:16 <itidus20> it has an initial state and each day won't change
23:51:48 <itidus20> like.. 2000bc is set in stone
23:52:09 <monqy> once again itidus20 philisophises without knowing what he's talking about
23:56:30 <itidus20> true
23:57:16 <itidus20> i am confusing general procedural generation with random number generation
23:58:19 -!- Phantom_Hoover has quit (Quit: Leaving).
23:59:06 <itidus20> if a game had hardcoded random number seeds then that would add an interesting twist that you could learn how it unfolds
23:59:08 <oerjan> mezzacotta's algorithm is actually deterministic, iirc. that way they can clear away the cache of rarely visited days.
23:59:32 <itidus20> well yeah.
23:59:38 <ais523> itidus20: at least one final fantasy game (FF1?) is like that
23:59:52 <itidus20> oh i didn't know that
23:59:57 <itidus20> @ ais
←2011-08-13 2011-08-14 2011-08-15→ ↑2011 ↑all