←2007-12-29 2007-12-30 2007-12-31→ ↑2007 ↑all
00:01:08 <ehird`_> FUCK orange broadband and their GOD DAMN ROUTER
00:08:18 -!- puzzlet has quit (Remote closed the connection).
00:08:20 -!- puzzlet_ has joined.
00:08:23 <Sgeo> How do I access modules that are above the current directory?
00:08:26 <Sgeo> re puzzlet_
00:08:41 <ehird`_> You can't, Sgeo.
00:09:41 <ehird`_> oklofok: I took up the task of making a language like oklotalk, but logical and cleaner
00:09:44 <ehird`_> Yes, I am crazy :D
00:10:09 <ehird`_> "+\1 2 3" is 6
00:10:25 <Sgeo> import sys
00:10:25 <Sgeo> sys.path += ['../..']
00:10:26 <ehird`_> + is what you expect, \ is NOT a binary 'fold' operator but instead a postfix operator
00:10:31 <ehird`_> Sgeo: Well yes
00:10:35 <Sgeo> Would that work or fail on Windows, though?
00:10:37 <ehird`_> and what \ does, here +\
00:10:48 <ehird`_> returns a function which does the folding
00:11:07 <ehird`_> so +\'s result is an operator taking a list and folding it over +
00:11:11 <ehird`_> then the list 1 2 3
00:11:20 <ehird`_> ergo, "+\1 2 3" is 6
00:11:25 <ehird`_> / is \ but for 'map'
00:14:14 -!- puzzlet_ has quit (Remote closed the connection).
00:14:26 -!- puzzlet has joined.
00:14:55 <Sgeo> rere puzzlet
00:15:23 <faxathisia> I don't know python
00:16:13 <Sgeo> btw, you won't need to learn Python to use PSOX
00:16:18 <Sgeo> Just to implement domains..
00:17:23 <Sgeo> My code looks FUGLY
00:18:17 <Sgeo> GregorR, on Windows, does printf() wait for just a 0x0A, or would it be expecting the other thing too?
00:18:32 <faxathisia> http://rafb.net/p/NpqVc215.txt
00:19:36 <faxathisia> can view the graphs with that
00:19:54 -!- ehird` has quit (Success).
00:20:41 <GregorR> Sgeo: Since printf("\n") works in every Windows CC I've ever used, I would imagine just \n.
00:20:57 <Sgeo> ty
00:21:35 -!- puzzlet_ has joined.
00:21:36 <oklofok> faxathisia: i already show them in a similar fashion, i meant graphically
00:21:52 <faxathisia> graphviz can render those formats
00:22:00 <oklofok> oh
00:22:02 <oklofok> cool
00:22:27 <GregorR> Hahahahahaha, they're advertising a magnet you put on your left ear that helps you quit smoking X-D
00:22:28 <oklofok> anyhow, did you try the lang?
00:22:33 <GregorR> Can you say "placebo"?
00:22:40 <oklofok> you don't need to know python to be able to
00:22:48 <oklofok> heh, lol
00:22:55 * Sgeo worries that PSOX.py might be something of a slapdash implementation
00:24:21 <Slereah> GregorR : Might work if you're a robot.
00:24:27 <Slereah> Remember Futurama?
00:25:18 <faxathisia> :[
00:25:32 * faxathisia thinks... general purpose languages should have multiline comments
00:28:34 <oklofok> faxathisia: you can't say you wanna try it and then not :)
00:28:43 * faxathisia is trying to make a web
00:28:48 <ehird`_> GregorR!!!!!!!!
00:29:00 <GregorR> No, I'm not here.
00:29:02 <ehird`_> stop stop stop stop stops tops tops tops tospt ostpsotpsotsptosptsotpsotpstosptostpsotpstosptosptospsotsptosptsoptsotspooo
00:29:04 <faxathisia> oh I just realised how to do multiline comments in python
00:29:10 <ehird`_> YOU ARE WRONG :(
00:29:17 <ehird`_> in C \n does not mean 0x0A
00:29:20 <ehird`_> it means newline
00:29:22 <ehird`_> which in windows is CR LF
00:29:24 <ehird`_> not LF
00:29:29 <ehird`_> the compiler does this, it is standard
00:29:44 <faxathisia> """multiline commen"""
00:29:51 <ehird`_> faxathisia: oh god python no :(
00:29:57 <GregorR> I got a ticket on a project of mine because it put non-Windows newlines in a file on Windows.
00:30:06 <GregorR> It did that because I used \n.
00:30:11 <GregorR> I did not fix it, since it wasn't broken.
00:30:31 <GregorR> But the point is, it didn't use CR LF.
00:31:52 -!- puzzlet has quit (Read error: 110 (Connection timed out)).
00:45:28 <faxathisia> this is hard to use :p
00:45:33 <ihope> A ticket?
00:47:59 <ehird`_> GregorR: it was opened in binary mode
00:51:20 <oklofok> faxathisia: did you try it? :D
00:51:34 <faxathisia> yeah
00:51:48 <faxathisia> I'm still trying to make this thing without infinitelooping
00:54:52 <oklofok> heh
00:55:06 <oklofok> currently, you need to actually have the pattern die out
00:55:13 <oklofok> i mean, in the version you have
00:55:31 <oklofok> i made it stop when the same object is found twice
00:56:34 <faxathisia> this is cool http://img339.imageshack.us/img339/8556/picture5mx0.png
00:56:42 <faxathisia> that's the grid one though
00:56:56 <faxathisia> (using a stupid layout)
00:58:17 <oklofok> what?
00:58:23 <oklofok> what's that?
00:58:38 <faxathisia> Grid2d 15 15
00:58:50 <oklofok> xD
00:58:58 * oklofok knows a better graphical representation
00:59:47 <faxathisia> that's the same one energy minimized http://img174.imageshack.us/img174/8382/picture6id6.png
01:01:20 <oklofok> oh, that's actually pretty close
01:01:44 * ehird`_ ponders elegant-but-alien-looking languages
01:01:57 <ehird`_> i.e. simple, but not too simple, and no does-everything features, no hacks
01:02:00 <ehird`_> but still strange
01:02:10 <ehird`_> lambda calculus is ofc the classic in that area
01:02:55 <ihope> What do you mean, lambda calculus is alien? :-P
01:03:10 <faxathisia> i think that I can trick people into using lambda calculus for real programming
01:03:24 <faxathisia> because.. if you just add enough syntax...
01:03:26 <ihope> Pi calculus is either the ultimate in artificial intelligence stuff or actually quite unremarkable.
01:03:31 <ihope> ...you get Haskell!
01:03:39 <Slereah> I think combinators are harder than lambda calculus.
01:03:45 <faxathisia> oh damn it's been done already!
01:03:53 <Slereah> It's not too hard to define a function in lambdas.
01:03:56 <faxathisia> I want to try some other lambda calculi though
01:04:02 <ihope> Well, you can algorithmically translate lambdas to combinators.
01:04:23 <Slereah> You can do it for all languages!
01:04:24 <ihope> Depending on the algorithm, it might actually do a decent job. :-P
01:04:58 <oklofok> pi calc is fun
01:05:18 <ihope> I'm going to check up on just what it is.
01:05:22 <faxathisia> can't I have more than 2 parameters?
01:10:59 <ihope> Ah, indeed, after reading up on it, pi calculus is fun.
01:11:53 <faxathisia> I like λ∏ but most of the theory is way too hard for me right now
01:12:50 <ihope> You like what?
01:12:56 <ihope> Lambda and pi?
01:13:49 <oklofok> faxathisia: if you have any interest left, wanna draw http://www.vjn.fi/pb/p165564435.txt for me?
01:14:00 <oklofok> or is it just for bidirectional graphs?
01:14:06 <oklofok> not that it matters really
01:14:13 <oklofok> anyhow, directed graphs should work now
01:14:31 <faxathisia> I think explains it ok http://people.cs.uu.nl/andres/LambdaPi.html
01:15:29 <ihope> Lambda and pi stuck together?
01:16:03 <ihope> Lambda calculus with dependent typing?
01:17:04 <faxathisia> It's lets you define functions whose return type depends on it's arguments
01:17:11 <faxathisia> yeah
01:17:27 <ihope> I imagine it doesn't have a full first-order logic system taking full advantage of the Curry-Howard isomorphism and all.
01:18:12 <faxathisia> oklofok: it's just a circle
01:21:11 <oklofok> hehe
01:21:32 <oklofok> i wondered whether it gets it circle, or if it'd be eight'y or something
01:26:27 <ehird`_> RANDOM SILLY IDEA
01:26:31 <ehird`_> A lambda calculus CPS transformer
01:29:17 <ehird`_> oklofok: your bot has lambdacalculus infrastructure
01:29:17 <ehird`_> do eet
01:29:24 <Slereah> What, a giant robot that can transformate into a lambda expression?
01:30:26 <oklofok> ehird`_: o
01:30:33 <ehird`_> e
01:30:38 <ehird`_> Slereah: heh
01:30:46 <oklofok> making a lambda calculus infrastructure is a 20 min job :\
01:30:59 <oklofok> i have things to do, gotta look at my parser!
01:31:13 <oklofok> and hope it codes itself.
01:31:40 <ehird`_> yeh well i don't like writing cps transformers
01:31:43 <ehird`_> (cps=http://en.wikipedia.org/wiki/Continuation_passing_style)
01:33:03 * faxathisia had fun writing one first time around
01:34:20 <oklofok> i haven't written one, but given a parsed code, i don't think it's hard
01:35:23 <ehird`_> oklofok: It's not really hard, no
01:35:28 <ehird`_> but irritating
01:35:34 <ehird`_> Hmm. I want to implement ISWIM
01:35:56 <faxathisia> ooh it's by Peter J. Landin
01:36:53 <ehird`_> yes
01:37:01 <ehird`_> it's the 'the next 700 programming languages' language
01:38:04 * Sgeo is back
01:38:23 <Sgeo> Once PSOX 1.0 is out, would anyone here be willing to make an IRC domain?
01:38:59 <ehird`_> no
01:39:28 * Sgeo thinks an answer from someone who thinks positively of PSOX would be more useful
01:41:40 <ehird`_> there is no point
01:42:06 <oklofok> ehird`_: you actually see no point in the whole io wrapper thing?
01:42:16 <oklofok> i think it's an awesome idea :\
01:42:23 <ehird`_> i said not that
01:42:26 <ehird`_> i said no point in the irc domain
01:42:37 <oklofok> oh, right, guess it's just bsmnt
01:43:08 <oklofok> what's an irc domain?
01:43:12 <oklofok> irc network?
01:45:13 <Sgeo> irc domain = spec for PSOX stuff to access IRC
01:45:22 <Sgeo> And implementation of such
01:45:32 <Sgeo> a domain, in PSOX, is roughly like a library
01:45:41 <faxathisia> eah that would be cool
01:45:46 <faxathisia> (having ISWIN implementation)
01:45:50 <faxathisia> ISWIM*
01:46:02 <Sgeo> ISWIM?
01:46:14 <faxathisia> http://www.cs.utah.edu/~eeide/compilers/old/papers/p157-landin.pdf
01:46:18 <faxathisia> It's got the J operator
01:46:28 <Sgeo> http://trac2.assembla.com/psox/browser/trunk/spec/psox.txt
01:46:37 <faxathisia> I think it's a bit like the infinite improbability drive
01:49:19 <ehird`_> haskell etc are descended from iswim
01:49:29 <ehird`_> it has the off-by-one rule and all that
01:49:35 <ehird`_> it would be interesting
01:50:00 <faxathisia> What's the off-by-one rule?
01:50:17 * Sgeo isn't going to write the IRC domain himself.. at least not until after PSOX 1.0 is released
01:50:19 <ehird`_> faxathisia: indentation for braces
01:50:25 <ehird`_> err
01:50:27 <ehird`_> off-side rule
01:50:28 <faxathisia> oh right
01:50:30 <ehird`_> heh :)
01:50:40 <ehird`_> but the cool kind
01:50:52 <ehird`_> instead of just indenting N places, you line it up
01:53:54 <ehird`_> oklofok: you should form an Oklotalk Comittee
01:54:15 <Slereah> "The bikeshed comittee"
01:54:18 <ehird`_> that means you're licensed to release the standard as "Report on the Oklotalk algorithmic language"
01:54:43 <ehird`_> and provide a black-on-really-dark-gray in times-roman html version
01:54:53 <ehird`_> with tacky gifs on your home page with 3d graphics of the language name
01:55:00 <ehird`_> and form an Oklotalk Advocacy Group
01:55:16 <Sgeo> sgeo@ubuntu:~/dev/psox/trunk/impl$ python PSOX.py bf test.b
01:55:16 <Sgeo> Client's PSOX Ver: PSOX 0.5-11
01:55:16 <Sgeo> Running PSOX 0.9
01:56:01 <Sgeo> Doesn't like it when I try to make one of the parts of the version 10
01:56:07 * Sgeo isn't going to fix that yet
01:56:34 <Sgeo> PSOX 1.10 is still a ways off
01:57:04 <faxathisia> oh PSOX is also an interpreter?
01:57:10 <faxathisia> or is it executing the bf program?
01:57:25 <Sgeo> PSOX.py is the name of the interpreter, which executes the bf command
01:57:31 <Sgeo> (is executing)
01:57:38 <faxathisia> why not just bf test.b | python PSOX.py
01:57:42 <Sgeo> I have the bf program in my path
01:57:54 <faxathisia> would that be possible too?
01:57:56 <Sgeo> faxathisia, because I need the PSOX server on both sides
01:58:04 <Sgeo> on both stdin and stdout
01:58:09 <faxathisia> ohh I see
01:59:06 * Sgeo thought of an interesting change to the PSOX spec
01:59:11 <Sgeo> But it would be a major change
01:59:38 <Sgeo> instead of using 0x00 before all functions, all output chars, unless 0x00, specify the domain of the function, as thought there was an implied 0x00
01:59:47 <Sgeo> 0x00 would just be regular output
02:00:34 <Sgeo> Probably not PSOX 1.0 though
02:01:49 <ehird`_> faxathisia: about that ISIWM interpreter, i might have a go
02:02:00 <faxathisia> good luck :D
02:02:05 <faxathisia> It'd be fun to mess with
02:02:08 <ehird`_> the paper doesn't specify what typing
02:02:12 <ehird`_> so i can do dynamic or inferenced
02:02:16 <ehird`_> inferenced seems the purest, but harder
02:02:22 <faxathisia> wiki said probably dynamic, but I don't see any reasons to go either way
02:02:33 <ehird`_> hmm, someone offer help in writing it :P
02:02:41 <ehird`_> yes YOU!
02:02:44 <faxathisia> what're you going to write it in?
02:02:54 <ehird`_> faxathisia: beats me. Scheme maybe?
02:03:01 -!- ihope has quit ("CGI:IRC").
02:03:06 <ehird`_> Not C, let's put it that way
02:03:13 <faxathisia> That's a good idea :D
02:03:24 <Slereah> Does someone have any idea how to make a 2D tape for a Turing machine on Python?
02:03:32 <Slereah> That is, infinite in all direction.
02:03:41 <ehird`_> Slereah: use a hash table :P
02:03:45 <faxathisia> can you make an infinite 1D tape?
02:03:47 <Slereah> I don't really want to program some N->ZxZ isomorphism.
02:03:56 <faxathisia> N->NxN though?
02:03:57 <Slereah> I made one.
02:03:59 <faxathisia> oh right..
02:04:07 <Slereah> N->Z is easy.
02:04:12 <ehird`_> faxathisia: do you know scheme? :P
02:04:22 <faxathisia> ehird: Yeah
02:04:25 <Slereah> N-> NxN isn't, but the function already exist, it's the pairing function.
02:04:26 <ehird`_> yaey
02:04:44 <Slereah> I tried to make N->ZxZ, I really don't want to program that.
02:04:52 <ehird`_> the thing with scheme is that you have to choose an implementation and stick with it
02:05:01 <ehird`_> they are just too different
02:06:49 <Sgeo> The PSOX spec will probably be finalized soon
02:07:03 -!- ihope has joined.
02:07:19 <Sgeo> re ihope
02:07:24 <ihope> Ello.
02:07:49 <ihope> The people of Sine aren't wondering if I'm dead, are they?
02:07:59 <ehird`_> faxathisia: annoyingly most scheme systems aren't batch which makes this kind of stuff a pain :-)
02:08:21 <ehird`_> chicken, gambit, bigloo are considerations then i guess
02:11:06 <ehird`_> i guess i'll quiz in #scheme
03:05:26 * Sgeo has an idea to make things like a version 1.10 easier
03:07:01 -!- ihope has quit ("CGI:IRC (Ping timeout)").
03:11:44 * Sgeo can't help thinking that PSOX.py is incredibly ugly..
03:12:44 <Sgeo> A lot of the code is probably WTF quality..
03:20:32 -!- ehird`_ has quit.
03:28:54 <Sgeo> sgeo@ubuntu:~/dev/psox/trunk/impl$ python PSOX.py bf test.b
03:28:54 <Sgeo> Client's PSOX Ver: PSOX 0.0-10
03:28:54 <Sgeo> Running PSOX 0.0
03:34:14 <Sgeo> PSOX.py now has support for the possibility of a client saying Version 10
03:41:34 <pikhq> PSOX!
03:41:46 <Sgeo> :D YAY PSOX! GO PSOX!
03:42:05 <pikhq> Now is the time. . . The time to implement psox.pebble.
03:42:19 <Sgeo> you're doing that?
03:42:32 <pikhq> No; I don't know where the spec is.
03:42:41 <pikhq> Hand it to me, and I shall have PEBBLE using PSOX.
03:42:55 <Sgeo> Spec isn't quite finalized yet, but it's close
03:43:00 <Sgeo> At least, the main part anyway
03:43:09 <Sgeo> Still working on the specs for the builtin domains
03:43:28 <Sgeo> http://trac2.assembla.com/psox/browser/trunk/spec/psox.txt
03:43:39 * pikhq shall work on a Rubik's cube while waiting
03:43:43 <pikhq> I give you 2 minutes. :p
03:44:51 <Sgeo> Waiting for what? The specs for domains to be complete?
03:45:40 <pikhq> Sure.
03:45:42 * pikhq is done
03:45:42 <Sgeo> Or for finalization of psox.txt?
03:45:46 <Sgeo> >.>
03:45:46 <pikhq> Either.
03:46:20 <Sgeo> I think psox.txt is final
03:46:24 <pikhq> Mmkay.
03:46:45 <Sgeo> Of course, I have the ability to change everything completely, but I don't think there will be.
03:47:10 <Sgeo> There were some changes I remember wanting to make, but I think I made all of them
03:47:41 <Sgeo> Actually, psox.txt isn't done.. the List of Builtin Domains isn't complete..
03:48:03 <Sgeo> and the url for simple utilities is wrong
03:48:19 <Sgeo> But everything else should be good
03:48:32 <Sgeo> Although the implementation so far violates the spec
03:49:27 <Sgeo> And will probably keep violating it
03:49:38 <Sgeo> Is this a problem, pikhq?
03:50:34 <Sgeo> "After that, the server responds with its minorver" should probably be "the minorver in use"
03:50:39 <Sgeo> But that's not the vio
03:51:28 * Sgeo will go in 10min to watch Seinfeld
03:51:28 <pikhq> Not yet.
03:51:33 <pikhq> What's the violation?
03:52:20 <Sgeo> According to the spec, if the client isn't PSOX, or if it's the wrong version, the Server lets it know, and lets the client keep running without PSOX features. The implementation exits on those conditions..
03:53:54 <pikhq> Think you could provide a version-invariant method of exitting if the client is using the wrong version?
03:55:31 <Sgeo> ?
03:55:58 <Sgeo> When the implementation exits, the client is killed >.>
03:56:17 <pikhq> Oh. NM.
03:57:14 * pikhq has the psox.bfm header set up.
03:57:24 <Sgeo> May I see?
03:57:51 <pikhq> Just a sec.
03:58:53 <pikhq> http://pastebin.ca/838136
04:00:33 <Sgeo> You're forgetting the 0x0A
04:01:03 <pikhq> The spec did not say a \n was needed there.
04:01:14 <Sgeo> Also, that's PSOX 0.0
04:01:30 <pikhq> Which the spec claims to be.
04:01:55 <pikhq> I can only code to the spec. ;)
04:02:19 <Sgeo> When PSOX 1.0 is released, you'll need to change the code >.>
04:02:31 <Sgeo> But that should be easy enough
04:04:02 <Sgeo> It's a good think you did the psox.bfm now
04:04:08 -!- ihope has joined.
04:04:16 <Sgeo> Ok, psox.txt updated
04:04:51 <Sgeo> Hi ihope
04:07:47 <Sgeo> pikhq, updating the header?
04:09:40 <pikhq> Updated.
04:10:55 <Overand> this is twisted
04:11:00 <Overand> I'm glad I'm idling here.
04:11:17 <Sgeo> pikhq, where?
04:11:31 <Overand> PSOX is a fantastic concept =]
04:11:50 <Sgeo> ty Overand
04:11:51 <pikhq> Sgeo: Lemme post a tarball of my stuff when I'm done implementing all the stuff in the basic spec.
04:17:17 <Sgeo> ihope, you know Sine has a web-irc gateway?
04:20:44 <Sgeo> Overand, did you read the spec?
04:22:10 <pikhq> Does 2.6 return 1 if somestring was a specified safety option, 0 otherwise?
04:23:50 <Sgeo> yes
04:24:42 <Sgeo> pikhq, will psox.pebble be able to handle LNUM/LBYTES/VARG?
04:26:22 <pikhq> As of yet, I don't have any special handling for it.
04:26:54 <Sgeo> Is the language capable of handling it though?
04:27:42 <pikhq> I may need to do some special patching of PEBBLE to make LNUM *convenient*. . .
04:28:04 <ihope> Sgeo: I was a little bit aware of it, but I don't know where it is.
04:28:07 <Sgeo> what about LBYTES and VARG?
04:28:25 <pikhq> But certaintly, you can just pass the macros that take strings of some sort an LNUM, LBYTES, or VARG. . .
04:29:26 <pikhq> I'll *probably* want to do something in PEBBLE like [lbytes foo bar baz] to be able to conveniently handle that stuff, though.
04:29:37 <pikhq> But this is a matter of convenience, not functioning. ;)
04:29:51 * Slereah made some program to generate possible programs for them Turing machine
04:29:56 <Slereah> With associated numbers!
04:30:07 <Sgeo> As long as it can. I'm pretty sure that in bfcomp (which is what I wanted PSOX to work with) it would have been difficult, if not impossible
04:30:08 <Slereah> To maybe compute the first digits of its Turing number.
04:30:58 <ihope> Turing number?
04:31:08 <Sgeo> ihope, why don't you have an IRC client?
04:31:19 <Slereah> The nth digit is 1 if the program is circle free, 0 otherwise, or if it's not a valid program.
04:31:20 <pikhq> Sgeo, bfcomp is a really inflexible bit of language.
04:31:25 <Slereah> (Circle free = halts)
04:31:43 <pikhq> Because my macro parsing is so damned *cheap*, I can freely pass strings around in the macro parser.
04:31:59 <Slereah> It's like a gentler Chaitin constant.
04:32:13 <faxathisia> hmm how is it different to Chaitins constant?
04:32:19 <ihope> Sgeo: I'm not using my computer, so I'm without one for a day or two more.
04:32:19 <Overand> Sgeo: some of it.
04:32:25 <Sgeo> ah
04:32:27 <Overand> (read some of the spec)
04:32:38 <Sgeo> Overand, thoughts?
04:32:39 <Slereah> faxathisia : Chaitin's constant is a probability.
04:32:43 <Sgeo> ihope, did you get my PM?
04:32:50 <faxathisia> I thought that it is the same thing
04:32:58 <Slereah> The Turing constant is just a bunch of numbers.
04:33:07 <ihope> Sgeo: yes.
04:33:10 <Overand> Sgeo: I'm not good enough with this stuff to offer a particularly informed opinion.
04:33:22 * Sgeo once attempted to prove that God cannot exist by using Chaitin's constant
04:33:24 <Slereah> I'd calculate the Chaitin constant, but I don't even understand what "prefix free" mean.
04:34:47 <Slereah> It's probably prettier. I already know the first 1500 digits of the Turing constant, and it's 0 because it's all strings that aren't valid programs.
04:34:54 <faxathisia> I have a feeling it's the same thing
04:35:07 <ihope> Suppose a person who is God can create a stone that is too heavy for him to lift. He cannot lift this stone, so he is not really God. Therefore, a person who is God cannot create a stone that is too heavy for him to lift. Therefore, a person who is God is not really God.
04:35:11 <Slereah> Well, you can probably use the Turing constant to calculate the Chaitin one.
04:36:28 <oklofok> god can do anything -> god can do things he can't do
04:36:32 <oklofok> paradox.
04:36:47 <Slereah> It's a paradox only if you assume that god can do anything.
04:36:51 <oklofok> still focking, ay? :\
04:36:53 -!- oklofok has changed nick to oklopol.
04:36:54 <Sgeo> My "proof" was against omniscience
04:40:41 <faxathisia> oh I think I see the difference
04:40:46 <ihope> How does one define omniscience formally?
04:40:49 <pikhq> What if one assumes that God can do anything except that which he has designed specifically for him not to be able to do?
04:40:50 <faxathisia> is this righT?
04:41:00 <faxathisia> the nth bit of turings constant is 1 or 0 if the nth program terminates
04:41:33 <Slereah> Well, that's what I saw at least!
04:41:41 <ihope> I don't think I've heard of a Turing constant.
04:42:07 <faxathisia> ok so Chaitins constant is different, because the nth bit is not any longer whether the nth program halts or ont
04:42:20 <faxathisia> instead .. you sum all halting programs of size n * 2^-|n|
04:42:56 <faxathisia> (for every n)
04:43:02 <Slereah> If you know what "prefix free" means, I would be grateful.
04:43:28 <Slereah> I'd rather have a probability than a huge bunch of zeros.
04:44:05 <faxathisia> I don't really know but I think this explains it http://en.wikipedia.org/wiki/Instantaneous_code
04:44:17 <ihope> A language is prefix-free if and only if there are no two strings in the language such that one starts with the other.
04:44:24 <faxathisia> '{0, 10, 11} has the prefix property; a code consisting of {0, 1, 10, 11} does not, because "1" is a prefix of both "10" and "11".'
04:45:42 <pikhq> Sgeo: I'll finish up the System domain tomorrow (I stopped short of file descriptor manipulation).
04:45:52 <Sgeo> pikhq, coolness
04:46:17 <pikhq> http://pikhq.nonlogic.org/psox.tar.bz2
04:46:17 <Slereah> So since my code is {*,+,<,>}, am I in the clear?*
04:46:40 <Slereah> Is it the symbols that compose it, or the strings themselves that must be prefix free?
04:46:42 <faxathisia> I think if you have * in the set, then you can't have ** also in the set
04:46:43 <pikhq> If you see simple bugs in there, would you be kind enough to fix, include a changelog, and bat the tarball back at me?
04:46:55 <ihope> {*,+,<,>} is prefix-free.
04:47:08 <Sgeo> What if there's what looks like a bug because the spec is wrong?
04:47:22 <pikhq> Then fix the spec for God's sake. :p
04:47:32 <Sgeo> brb
04:47:50 <ihope> The important part is that if you concatenate some words, you can tell that it's those words rather than some other words that concatenate to the same thing.
04:49:04 <Sgeo> back
04:49:34 <Slereah> Okay
04:49:48 <Slereah> So my code is prefix free then.
04:49:51 <ihope> Yes.
04:49:59 <Slereah> Good.
04:50:57 <Sgeo> pikhq, make sure users realize that psox_installed doesn't check that psox is installed..
04:51:30 <Sgeo> Also, if I knew the bfm language, that would probably be helpful
04:51:36 <Sgeo> >.> Imean PEBBLE
04:51:52 <ihope> (Not only can you do that, but if you concatenate some words and then an initial segment of a word, you can tell that it's those words followed by that initial segment.)
04:52:48 <Slereah> So in other word, it's just the ability to tell apart any two different pieces of code?
04:53:07 <ihope> More or less, yes.
04:53:21 <pikhq> Sgeo: Probably a good idea, that.
04:53:29 <pikhq> Learn PEBBLE.
04:53:31 <Sgeo> what does "exit" do?
04:53:56 <pikhq> It calls the "exit" function in PSOX-System.
04:54:05 <pikhq> PSOX 2.1. ;)
04:54:22 <Sgeo> ah. Why do you want to exit just because a domain you checked for wasn't there?
04:54:29 <ihope> If the code is {0,1,10,11} and I say 110, you don't know whether it's 1-1-0, 11-0, or 1-10. If the code is {0,10,11} and I say 111, you know that it's 11-1, the 1 on the end being part of a word.
04:54:40 <Sgeo> Shouldn't that be the business of the program using the library, and not the library itself?
04:55:23 <pikhq> Um. Probably.
04:56:30 <Sgeo> Also, is pin that convenient?
04:56:37 <Slereah> Well, so far, I have 252 programs that might be valid (if my program works correctly).
04:56:54 <Slereah> Although I must take out the ones that refers to states that don't exist
04:56:58 <pikhq> I should probably have pin take the amount of things to ask for instead. . .
04:57:11 <pikhq> s/ask for/input/
04:57:15 <Sgeo> Because the return from the input function also includes EOF data etc.
04:57:23 <Sgeo> and padding nuls, etc
04:57:41 <Sgeo> Also, will this library be able to easily call arbitrary PSOX functions?
04:57:55 <Sgeo> Because (hopefully) there will be domains not part of the official spec
04:58:36 <Sgeo> Why is there no "in" in psox_gethandprint.bfm?
04:58:51 <pikhq> That would be the job of other libraries. This library is basically just a wrapper around the builtin PSOX domains.
04:59:09 <pikhq> And there is no "in" in psox_gethandprint.bfm because gethandprint returns a string. . .
04:59:22 <pikhq> I assume that the user of the macro will then handle inputting the whole string.
04:59:33 <pikhq> However the user sees fit.
05:00:23 * Sgeo should keep working on PSOX.py
05:01:37 <pikhq> You know what'd be amusingly roundabout?
05:01:45 <pikhq> Implementing a C library to use PSOX. ;)
05:02:26 <Sgeo> Writing Python stuff to use PSOX might actually help testing PSOX.py
05:02:38 <pikhq> That it might.
05:02:45 <pikhq> I'll do something like that tomorrow.
05:02:57 <pikhq> I'll call it something like "The C PSOX Library and Test Suite".
05:03:08 * Sgeo is currently using a bf program that outputs fixed numbers
05:03:50 <Sgeo> I seem to have the handshake (PSOX-Init) working
05:11:25 <pikhq> I'm working on the C PSOX library now, for no good reason.
05:11:45 * Sgeo doesn't really know C
05:12:03 * pikhq does
05:13:26 <Slereah> Hm. How can you find which function halts with Chaitin's constant, since it only gives you a probability?
05:28:37 -!- calamari has joined.
05:37:14 -!- oklopol has quit (Read error: 104 (Connection reset by peer)).
05:37:49 <Sgeo> Hi calamari
05:38:02 <Sgeo> Did you see the recent updates to the PSOX specZ?
05:38:04 <Sgeo> spec?
05:38:14 <Sgeo> Or pikhq's PEBBLE stuff for PSOX?
05:39:11 * Sgeo should probably go to sleep soon
05:39:27 * Sgeo is glad he finished the handshake code though
05:39:36 <Sgeo> And, with pikhq's help, fixed the spec >.>
05:40:33 <ihope> Slereah: it depends on what Chaitin's constant you use, I think.
05:40:48 <Sgeo> oO one run of the thing I got a "Broken pipe" error
05:40:52 <Sgeo> the next runs I didn;t
05:40:58 <ihope> If it's for a uniform probability over a finite set of Turing machines, you can use it to find out how many Turing machines halt, and once you've found those, you know that the rest don't halt.
05:41:19 <ihope> Maybe there's a way to find it for all Chaitin's constants; I don't know.
05:41:31 <calamari> hi Sgeo
05:41:34 <calamari> no I didn't
05:42:12 <calamari> did you get the pesoix code working?
05:42:24 <pikhq> PSOX, actually.
05:42:26 <Slereah> Yes, but can you use it to find out what machines halt?
05:42:41 <calamari> name change?
05:42:45 <Slereah> Is there some sort of bijection between that number and the set of halting programs.
05:42:55 <calamari> or are we talking about something else?
05:43:25 <pikhq> Something else.
05:43:28 <Slereah> When I read about it, it seems like it, but now I'm not so sure.
05:43:32 <Sgeo> esolangs.org/wiki/PSOX
05:43:47 <Sgeo> Remind me not to do what I just did
05:45:00 <calamari> no that's the same idea as pesoix
05:45:22 -!- Sgeo has quit (Read error: 104 (Connection reset by peer)).
05:46:31 -!- ihope has quit ("CGI:IRC (Ping timeout)").
05:46:58 -!- Sgeo has joined.
05:47:09 <Sgeo> Crashed
05:47:11 <Sgeo> What did I miss?
05:47:17 <Sgeo> After <Sgeo> Remind me not to do what I just did
05:47:38 <calamari> <calamari> no that's the same idea as pesoix
05:48:14 <Sgeo> It's not compatible with PSOX, also, don't some parts of PESOIX interact directly with "cells" instead of going through stdio?
05:48:45 <calamari> true, but my implementation wasn't going to do that
05:49:05 <pikhq> So, your implementation was basically going to selectively ignore parts of the spec.
05:49:17 <calamari> yeah
05:49:24 <Sgeo> My implementation is going to violate my spec a bit :/
05:49:24 <calamari> you got a problem with that?
05:49:28 <calamari> :)
05:49:36 <Sgeo> PESOIX is less flexible than PSOX =P
05:49:57 <calamari> anyhow.. so whatever it is.. did you get it working?
05:50:26 * Sgeo is almost done with the core part of the spec, and has implemented the handshake
05:50:48 <calamari> ahh so not implemented?
05:51:04 <Sgeo> Not yet
05:51:08 * pikhq is coming up with a C library to use it for no good reason
05:51:16 <calamari> that's the hard part :)
05:51:35 <calamari> I hadn't even really started on the "spec" part
05:51:40 <calamari> of the implementation
05:51:52 <calamari> just trying to get the I/O wrapper going and I failed
05:53:08 <Sgeo> The I/O issues is why I'm requiring clients (the esolang using PSOX) to send a command in order to receive input from stdin
05:53:29 <calamari> ahh.. so it won't work with arbitrary interpreters
05:53:49 <calamari> that would make it much easier
05:53:51 <Sgeo> arbitrary interpreters it will work with. The esolang is required to send the command though
05:54:16 <calamari> oh, gotcha.. hopefully that works out
05:54:18 <Sgeo> (actually, the interpreter needs to receive from stdin character-by-character)
05:54:42 <Sgeo> Read http://trac2.assembla.com/psox/browser/trunk/spec/psox.txt under Pseudodomains
06:02:29 <Sgeo> calamari, read/
06:02:31 <Sgeo> ?
06:02:55 <calamari> no I didn't, sorry
06:03:20 <calamari> been trying to find a PCI video card with composite/svideo out that also doesn't have a fan
06:04:11 <Sgeo> Thank you for all your work on PESOIX btw
06:06:46 <calamari> yw, but it doesn't even work, so don't thank me too soon :)
06:07:31 <Sgeo> Well, the spec was the inspiration for PSOX
06:10:41 * Sgeo pokethanks calamari
06:10:55 <calamari> ahh, the spec wasn't my work.. that was TheRaven
06:11:05 <Sgeo> ..oh
06:11:08 <calamari> except the esoapi part ;)
06:11:16 <Sgeo> Who was EsoAPI?
06:11:19 <calamari> me
06:11:40 <Sgeo> Well, thank you very much for something that inspired something that inspired PSOX
06:11:48 <calamari> lol.. yw
06:12:22 <calamari> there, something interesting might out of all that esoteric os stuff after all
06:12:41 <Sgeo> I don't think PSOX can be used to make an esoteric OS :/
06:13:18 <calamari> that reminds me.. a while back some guy emailed me saying he was using BOS in one of his classes. So my name was probably cursed by many a student on that one :)
06:13:47 <Sgeo> Although, in theory, you can use a subset of PSOX, extended with a custom domain, as a thingamagigy for an EsoOS
06:14:05 <Sgeo> hehe
06:25:21 * Sgeo should probably go to slepp
06:27:00 -!- Slereah_ has joined.
06:38:15 -!- Slereah has quit (Read error: 110 (Connection timed out)).
06:38:36 -!- Slereah has joined.
06:45:52 <Sgeo> Implementation agenda: output w/ 0x00 0x00, then class Domain, then domain dispatcher
06:46:07 <Sgeo> Sound good?
06:47:23 <Sgeo> After that, I'll get working on the implementation of the domains themselves, which should be quick, assuming the specs are done..
06:48:48 <pikhq> Hmm.
06:49:06 <Sgeo> Also, I should note in psox.txt somewhere that "," can be delayed.. the server stores it up until requested by the client, effectively
06:49:25 <Sgeo> Good?
06:49:29 -!- Slereah_ has quit (Read error: 110 (Connection timed out)).
06:49:30 <pikhq> Mmkay.
06:49:34 * Sgeo needs to go to sleep now, g'night
06:49:58 -!- Sgeo has quit (Remote closed the connection).
07:00:39 -!- puzzlet_ has quit (Remote closed the connection).
07:00:46 -!- puzzlet has joined.
07:02:07 -!- puzzlet has quit (Client Quit).
07:02:43 -!- puzzlet has joined.
07:17:01 -!- Slereah- has joined.
07:24:47 -!- calamari has quit ("Leaving").
07:35:43 -!- Slereah has quit (Read error: 110 (Connection timed out)).
07:35:49 -!- Slereah- has quit (Read error: 110 (Connection timed out)).
07:35:57 -!- Slereah- has joined.
07:42:10 -!- puzzlet has quit (Remote closed the connection).
07:42:18 -!- puzzlet has joined.
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:34:30 -!- oerjan has joined.
09:55:39 -!- helios_24c3 has joined.
10:09:08 -!- Hiato has joined.
10:34:35 -!- oerjan has quit ("leaving").
10:56:36 -!- helios_24c3 has quit ("Leaving").
11:12:22 -!- RedDak has joined.
11:56:34 -!- Hiato has left (?).
11:59:25 <GregorR> After my experiments with PVC instruments, I'm extremely confident that, with practice, I could play right to the finish a nocturne on a drainpipe flute.
11:59:30 -!- Hiato has joined.
11:59:40 -!- Hiato has left (?).
12:07:22 -!- oklopol has joined.
12:31:01 -!- Slereah has joined.
12:34:20 -!- RedDak has quit (Read error: 110 (Connection timed out)).
12:35:34 -!- RedDak has joined.
12:49:17 -!- Slereah- has quit (Read error: 110 (Connection timed out)).
12:49:38 -!- Slereah- has joined.
12:50:09 -!- Slereah has quit (Read error: 110 (Connection timed out)).
14:01:25 -!- helios_24c3 has joined.
14:29:49 -!- ehird`_ has joined.
15:03:16 <oklopol> finally, i'm fairly sure it works
15:03:31 <oklopol> that was one hellish language to parse :\
15:04:08 -!- Slereah- has changed nick to Slereah.
15:07:45 <ehird`_> oklopol: do show
15:10:36 <oklopol> lol, found a bug : )
15:19:13 <oklopol> oh, right, i just forgot i need to fix the evaluator too
15:19:14 <oklopol> lol
15:31:52 <oklopol> http://www.vjn.fi/pb/p612225632.txt
15:32:45 <oklopol> the same unidirectional ring i showed before, now demonstrating the syntax
15:32:58 <oklopol> the computation syntax that is
15:33:24 <oklopol> well, to be exact, the syntax of expressions, since statements and expressions are very clearly separated.
15:35:55 -!- sebbu has joined.
15:51:42 -!- sebbu2 has quit (Connection timed out).
15:53:39 -!- ihope has joined.
16:04:54 <Slereah> Hello ihope
16:09:31 <ihope> Ello.
16:13:24 <Slereah> Let's say that the Love Machine 9000 has 2 strings of length 5 that are valid programs. Both of these programs are circle-free (I won't say "halting", no program in the minimal syntax ever halt. The tape doesn't even stop moving).
16:13:45 <Slereah> What would be the first term for the Chaitin constant of this machine?
16:14:31 <Slereah> (The two programs are q0, S0 -> PS0, LE -> q0 and q0, S0 -> PS0, RI -> q0)
16:25:08 <oklopol> makes you wonder when a book written in 1997 says "it would take tens of man-years to write a compiler for a high-level language like pascal"
16:25:27 <oklopol> were people stupider back then? :)
16:25:27 <Slereah> Heh.
16:25:40 <Slereah> Possibly just lazy.
16:25:45 <oklopol> well, true
16:26:11 <oklopol> but wtf, pascal is simple as hell :\
16:26:28 <oklopol> or then i just know a subset of it and think that's all
16:27:34 <oklopol> i mean, i'm pretty sure i could write a decent pascal compiler in a month, and i'm not even a professional :\
16:27:57 <oklopol> i just create boy-years, which are like man-months.
16:28:21 <oklopol> gonna get some keb ->
16:31:35 <ehird`_> someone should make a programming language that is based on an editor
16:31:44 <ehird`_> the program simply manipulates the editor buffer of the program
16:31:45 <ehird`_> :D
16:31:57 <ehird`_> and the only way to loop is to manipulate the program with a quine
16:34:03 -!- jix has joined.
16:35:23 -!- oerjan has joined.
17:07:32 -!- faxathisia has quit ("Leaving").
17:14:28 <ehird`_> ,[.,]
17:14:28 <ehird`_> ((in 0) (loop 0 ((out 0) (in 0))))
17:14:32 <ehird`_> now for optimization
17:16:00 <oerjan> what are the 0's for?
17:16:40 <ehird`_> oerjan: at-position
17:16:49 <ehird`_> >>,<< will be optimized to (in +2)
17:17:01 -!- helios_24c3 has quit ("Leaving").
17:17:21 <oerjan> ic
17:19:57 <ehird`_> oerjan: then after optimization it can be put into $BACKEND
17:20:09 <ehird`_> i'm going to write one for brainfuck, just for kicks :-)
17:20:44 -!- RedDak has quit (Remote closed the connection).
17:20:59 <ehird`_> bf-bloatarize :-)
17:21:07 <ehird`_> also C (obviously), probably also an x86 machine code backend
17:21:12 -!- jix has quit ("CommandQ").
17:21:18 <ehird`_> maybe scheme, and try and make it work as functionally as possible while being fast :P
17:22:03 <oklopol> ehird`_: do you do any optimization for unmatching <>'s
17:22:03 <ehird`_> oerjan: there's also some special instructions, right now just 'clear' which optimizes (loop X ((add 0 -1))) to (clear X)
17:22:25 <ehird`_> oklopol: uh, i don't see any real sensible optimizations i could do
17:23:37 <oklopol> i should make a real optimizer sometime, the ones i've made in c++ suck ass :P
17:24:40 <ehird`_> scheme will be great for writing my optimizor in :-)
17:25:01 <ehird`_> except... (add x y) (add x z) optimizations need destruction :(
17:32:39 <ehird`_> hm, that destruction really IS infuriating
17:36:29 <oerjan> what destruction?
17:37:49 <oerjan> seems like a trivial pattern match to me
17:39:23 <oerjan> although basic scheme doesn't have easy pattern matching built in afair
17:39:55 <oerjan> (i'm sure someone must have made macros for it)
17:42:16 <oerjan> oh wait you weren't using scheme at this stage were you?
17:42:17 <ehird`_> i've decided to lessen my scope for now
17:42:27 <ehird`_> oerjan: yes, i am
17:42:51 <ehird`_> instead of generic optimization and backends, first i'm going to write a highly-aggresively-optimizing BF->x86 machine code compiler
17:43:02 <ehird`_> syscalls will jsut be OS X, since it's what i know :-) that could easily be changed
17:43:13 <ehird`_> what's the fastest known BF compiler right now?
17:44:14 <oerjan> don't know
17:44:42 <ehird`_> ok, well what's a fast one :P
17:44:51 <ehird`_> specifically, i'm going to be comparing mandelbrot.b performance
17:44:57 <oerjan> check the wiki
17:45:00 <ehird`_> the fastest interpreter runs it in around 10 seconds
17:45:09 <ehird`_> so compiled, i dunno... i think i could do 2 seconds? :-)
17:46:20 <ehird`_> from the wiki: "Due to the fact that the last half of its name is often considered one of the most offensive words in the English language, it is sometimes referred to as ... b****fuck ..."
17:46:21 <ehird`_> brilliant
17:46:25 <ehird`_> b****fuck
17:47:36 <ehird`_> does egobf have a compiler?
17:50:21 <pikhq> Sure. egobfc.
17:50:59 <pikhq> Which does all the optimization that egobfi does. ;)
17:51:45 <pikhq> Also, that editor language you discussed?
17:51:50 <pikhq> We have a name for it: TECO.
17:57:47 <ehird`_> teco's not what i meant
17:57:48 <ehird`_> :-)
17:58:08 <ehird`_> you can do a factorial in teco without quining the program in its editor buffer and changing various parts of it to the result
18:05:53 <ehird`_> most bf impls seem to be interps, oerjan
18:05:55 <ehird`_> the iwki is not much heklp
18:07:06 <oerjan> pikhq: what about yours? didn't you have a Pebble-based bf compiler?
18:08:40 <oerjan> via C iirc
18:13:16 <ehird`_> he does
18:13:20 <ehird`_> but it's not that optimizing as far as i know
18:13:33 <ehird`_> http://www.zathras.de/angelweb/blog-generating-machine-code-at-runtime.htm now this would be a good way to make a bf interp
18:13:41 <ehird`_> compile to machine code then execute onthefly :-)
18:13:51 <ihope> Just-in-time, eh?
18:14:00 <ehird`_> :D
18:15:06 <ehird`_> I don't know a simple tutorial to the mach-o format for writing out executables actually
18:15:09 <ehird`_> :-(
18:19:36 <ihope> Mirek's Cellebration 4.20 is 6 years old and it still seems to be the best cellular automata program for many purposes.
18:23:55 <pikhq> oerjan: Sure. PFUCK.
18:24:13 <pikhq> It's lightly optimizing.
18:27:30 <ehird`_> 0m1.680s, with gcc -O2 using C outputted by http://esoteric.sange.fi/brainfuck/impl/compilers/bf2c.hs which seems to do a lot of optimization
18:27:33 <ehird`_> mandelbrot.b
18:27:35 <ehird`_> not bad at all
18:29:53 <ehird`_> haskell seems really suited to that
18:30:01 <ehird`_> since bf optimization is pattern matching
18:30:08 <ehird`_> if only i knew haskell
18:34:19 <pikhq> Where's mandelbrot.b?
18:34:51 <ehird`_> http://esoteric.sange.fi/brainfuck/bf-source/prog/mandelbrot.b
18:34:53 <ehird`_> like all bf programs!
18:35:08 <ehird`_> bff, fastest (or second-fastest?) bf interpreter, runs it in a bit over 10 seconds
18:35:15 <ehird`_> that compiler does it in 1.680 with gcc optimizations
18:35:33 <ehird`_> gimme pfuck's compiled-c version
18:35:35 <ehird`_> i'll test it
18:35:46 <oklopol> all optimization is pattern matching
18:35:50 <oerjan> ehird`_: that was sort of the unwritten part of my pattern matching statement above ;)
18:36:11 <ehird`_> oklopol: using pattern matching could get quite verbose for some optimizations :-)
18:36:20 <ehird`_> oerjan: yeah, well, teach me haskell
18:36:21 <ehird`_> :P
18:37:09 <oklopol> graphica is getting quite awesome now, i'm fairly sure you can do an n dimensional hypercube now
18:37:17 <oklopol> in fact, i'll try
18:37:18 <ehird`_> show me a graphica 3d hello world
18:37:25 <oklopol> :P
18:38:35 <oklopol> now that i've given it a bit of thought, graph rewriting may be quite a nice platform for programming
18:38:48 <oklopol> it has the minor defect of being superturing to implement.
18:38:53 <oklopol> errrr
18:38:58 <oklopol> that was badly put ::P
18:39:02 <oklopol> but i guess you got it
18:42:25 <pikhq> http://pikhq.nonlogic.org/mandelbrot.c
18:48:25 <ihope> Graphica and graph rewriting, eh?
18:50:44 <oklopol> yes
18:50:46 <oklopol> why?
18:53:12 * ihope shrugs
18:53:24 <oklopol> has it been done?
18:53:41 <oklopol> never heard about it :\
18:53:56 <oklopol> not that i care, really
18:54:04 <oklopol> but i am interested
18:54:34 <ehird`_> here goes pikhq
18:55:59 <ehird`_> pikhq: 2.5-3 seconds
18:56:03 <ehird`_> you lose, by a lot
18:57:47 <ehird`_> oerjan: would a brainfuck->? compiler be a good learn-haskell project do you think? :-)
18:58:01 <pikhq> ehird`_: But not bad at all for such simple optimisation.
18:58:01 <ehird`_> and i actually mean from scratch - use my little knowledge of haskell, hack something out, learn from it
18:58:07 <ehird`_> no darn tutorials :-)
18:58:20 <ehird`_> pikhq: i did give you the benefit of gcc -O2, and this machine is recent
18:58:35 <ehird`_> (dec 06, with the model being introduced sept 06)
18:59:22 <pikhq> Still, consider that I'm doing barely anything to the code. ;p
18:59:45 <ehird`_> :p
19:00:08 <pikhq> And it's in Brainfuck. Surely that's worth something. :p
19:00:28 <oklopol> hmm, isn't the gregor's one the official fast bf interp?
19:00:30 <ehird`_> no, it's in pebble
19:00:35 <ehird`_> oklopol: not interp: compiler
19:00:47 <oklopol> well, interp in that it's used as one
19:00:55 <ehird`_> no i mean
19:00:59 <ehird`_> i'm lookin for a compiler
19:01:05 <oklopol> well, it compiles
19:01:12 <pikhq> egobfi8 and egobfc8.
19:01:19 <oklopol> compiles to binary code and runs it, iirc
19:01:19 <pikhq> They're both insanely fast in my experience.
19:01:36 <oklopol> ehird`_: compare yours to that
19:01:47 <oklopol> more interesting
19:01:55 <ehird`_> egobfc8, someone give me it as a c file :P
19:02:37 <oklopol> eso archives?
19:02:37 <pikhq> http://pikhq.nonloigc.org/mandelbrot.c
19:03:04 <ehird`_> er i meant the compiler. but ok :P
19:03:22 -!- UnrelatedToQaz has joined.
19:04:05 <oerjan> ehird`_: i don't know about not looking at a tutorial, but otherwise i think so
19:04:41 <ehird`_> oerjan: well i've read YAHT in the past, g ot iup to the bit where it started talking about crazy mutant types :-)
19:05:02 <ehird`_> pikhq: Ha, ha, egobfc8 sucks! Bus error.
19:07:59 <ehird`_> pikhq: :-)
19:08:14 <pikhq> Um?
19:08:25 <pikhq> Gah.
19:08:33 <pikhq> GregorR: I thought you *fixed* that bug.
19:08:39 <oklopol> hehe :P
19:08:50 <oklopol> it's not about working, it's about how great it would be if it works!
19:08:56 <oklopol> *worked
19:09:27 <oklopol> none of you happen to be graphica experts? :\
19:09:40 <oklopol> i want to know if a binary n dimensional hypercube is possible
19:09:44 <ehird`_> oerjan: haskell pattern matching can't handle variable stuff, right?
19:09:48 <ehird`_> what i meani s
19:10:05 <ehird`_> ++++++++++++ -> one instruction would have to be done by matching ++ then recursing, right?
19:10:18 <oerjan> oklopol: er of course it's possible, mathematically
19:10:23 <oklopol> you can define new patterns
19:10:27 <oklopol> oerjan: it is?
19:10:55 <oerjan> if it means what i think it is
19:11:02 <oklopol> did you prove graphica tc? :P
19:11:21 <oerjan> i am not talking about graphica
19:11:26 <oklopol> hehe
19:11:39 <oklopol> i mean, is it possible to define one in graphica
19:11:46 <ehird`_> oerjan: also, why doesn't emacs auto-indent haskell? :(
19:11:47 <oerjan> no idea
19:11:54 <ehird`_> i have haskell-mode etc
19:12:10 <oerjan> ehird`_: apparently you need to cycle through possible indentations
19:12:18 <oerjan> (so i hear)
19:12:18 <ehird`_> to take an example from bf2c.hs, "norm_move p = fst (nm p 0 0) where" is followed by some indented lines, but if i C-j on the 'where', i just get 0-indent
19:12:29 <ehird`_> oerjan: oh jesus. no way am i going to do that
19:12:41 <ehird`_> python has this problem, and python-mode uses the SANE indent level by default and THEN lets you cycle :(
19:12:42 <oklopol> i'll make a spec and hope one of the math wizzes here shows me how it's done
19:12:46 <ehird`_> oerjan: so what do you edit haskell with?
19:12:52 <oerjan> vim
19:12:59 <oklopol> i'm pointing my hairy hand at you, oerjan and ihope!
19:13:07 <ehird`_> does that indent your code for you, oerjan? :P
19:13:08 <oerjan> and i don't claim it's good
19:13:10 <ehird`_> i know vim does autoindent
19:13:11 <ehird`_> but for haskell?
19:13:16 <oerjan> for indentation
19:13:38 <ehird`_> ah
19:13:40 <ehird`_> :(
19:13:53 <oerjan> although i have not tried any fancy setup
19:14:55 <ehird`_> hm my bf compiler will be written in haskell and target c
19:14:59 <ehird`_> though i shall be sure to only use the simplest of c
19:15:08 <ehird`_> damn, now i have to name it :P
19:15:09 <oerjan> i just use the default language insensitive autoindent
19:16:14 <ehird`_> i'll just use emacs :P
19:16:39 <oerjan> as for +++++ i would just match on the first + and use span or something to get the rest
19:17:03 <oerjan> span (== '+')
19:17:27 <ehird`_> oerjan: i'll be applying optimization iteratively anyway
19:17:29 <ehird`_> something like
19:17:36 <ehird`_> while optimization_done: optimization_done = optimize()
19:17:49 <ehird`_> so it'll aggressively do as much as possible
19:18:04 <oerjan> that's extremely unhaskelly way of writing it :D
19:18:17 <oerjan> mutable Bool
19:18:19 <ehird`_> oerjan: yeah, i know :-)
19:18:24 <ehird`_> oerjan: it was just pseudocode
19:18:30 <ehird`_> to demonstrate what i meant
19:20:38 <ehird`_> frainbuck
19:22:15 <ehird`_> oerjan: do you know anyting about yi?
19:23:15 <oerjan> only that it's a haskell editor
19:24:19 <ehird`_> heh
19:24:23 <ehird`_> http://haskell.org/haskellwiki/Haskell_mode_for_Emacs i'm going to do that haskell unicode thing
19:24:26 <ehird`_> because i am curazy!
19:28:09 <oerjan> be careful not to mess up indentation with characters with the wrong width
19:28:19 <ehird`_> :-) sure
19:32:37 -!- sebbu2 has joined.
19:34:41 <ehird`_> $ darcs get --partial http://code.haskell.org/yi/
19:34:41 <ehird`_> Copying patch 238 of 1251...
19:34:48 <ehird`_> you call that PARTIAL, darcs?!
19:41:34 -!- calamari has joined.
19:41:36 -!- ihope has quit ("CGI:IRC (Ping timeout)").
19:48:25 -!- sebbu has quit (Read error: 110 (Connection timed out)).
20:01:26 <ehird`_> oerjan: those algebric thingy-types are "data" not "type", right?
20:01:43 <ehird`_> the X = Y a b | Z a b stuff
20:03:08 -!- ihope has joined.
20:03:13 <ehird`_> yes, yes they are
20:03:57 <oerjan> yep
20:04:02 <ehird`_> Damn, bf2c.hs optimizes /loads/
20:04:16 <oerjan> type is for synonyms
20:04:25 <ehird`_> it optimizes ifs, sums, and even multiplications (of arbitary forms)!!
20:04:39 <oerjan> newtype is for single field data types, removing the usual box
20:07:44 <ehird`_> i don't think i can live up to the amazingness of bf2c.hs :(
20:07:55 <ehird`_> it's *really good*
20:08:08 <Slereah> Huzzah!
20:16:49 -!- Hiato has joined.
20:16:59 <Hiato> Wassabi all :P
20:17:21 <oerjan> no thanks
20:17:32 <oerjan> i hear it's quite strong
20:17:34 <Hiato> lol, ok : Sup all
20:17:37 <Hiato> :) true
20:17:37 <ehird`_> oerjan: how do i add an instance? i'm trying to get show working :-)
20:17:39 <Hiato> but nice
20:17:55 <oerjan> ehird`_: data ... deriving (Show)
20:18:30 <ehird`_> oerjan: indented the same as a |?
20:18:43 <oerjan> or do you mean a custom one?
20:18:53 <ehird`_> also, how do i then define 'show' on it
20:18:57 <oerjan> for example
20:19:13 <oerjan> um deriving (Show) gives you the default instance
20:19:45 <oerjan> (i.e. neither | or deriving have very strict indentation requirements, just more than the "data")
20:20:46 <oerjan> for a custom one, you don't use deriving, but instance Show MyType where show x = ...
20:20:47 <ehird`_> i mean, oerjan, I want to define how to 'show BF'
20:20:52 <ehird`_> ah
20:20:54 <ehird`_> thank you
20:21:15 <ehird`_> instance Show BF\nwhere, right?
20:21:24 <oerjan> (assuming you don't need to deal with parenthesis precedences)
20:21:31 <oklopol> http://www.vjn.fi/pb/p136521315.txt tell me if any part of that makes sense, will ya :)
20:21:59 <oerjan> need at least a space before the where in that case
20:22:23 <oerjan> i would use instance Show BF where\n show ...
20:22:46 -!- tejeez has quit ("mit helvetti t mun irssi sekoilee").
20:22:50 <oerjan> (the where starts a new indentation block)
20:23:04 <Hiato> wow, oklopol, impressive
20:24:24 * oerjan wonders if helvetti means what he thinks it means
20:24:31 <oklopol> hell
20:24:37 <oerjan> right
20:24:39 <ehird`_> graph rewriting...
20:24:39 <ehird`_> !
20:24:48 <oklopol> it doesn't rewrite anything yet.
20:25:02 <oklopol> currently, it's a graph *description* language.-
20:25:17 <oklopol> but, as always, i aim higher than i'll prolly ever get.
20:25:26 <ehird`_> oerjan: haskell-mode doesn't consider "instance Show BF where\n " to be a proper&right indentation
20:25:34 <ehird`_> leastmost is aligned with 'Show BF'
20:25:45 <oerjan> bah
20:25:47 <oklopol> mitä helvettiä tää mun irssi sekoilee == what the hell is my irssi doing
20:25:51 <oklopol> roughly translated
20:26:16 <oklopol> Hiato: thanks, although i don't agree :)
20:26:47 <oerjan> ehird`_: well the next line does need to be indented
20:27:05 <oerjan> how much doesn't matter
20:27:34 <ehird`_> oerjan: can i pattern-match "negative" and "positive"?
20:27:36 <ehird`_> on an Int
20:27:46 <oklopol> in case anyone happened to start reading the spec, tell me ;)
20:27:54 <oklopol> morning coke ->
20:27:59 <Hiato> I did :)
20:28:00 <oerjan> use a guard
20:28:29 <oerjan> for example, f n | n < 0 = ...
20:28:35 <oklopol> cool, i don't think it's any good if you don't know the syntax somewhat already, since it's very formal and simultaneously not that unambiguous.
20:28:35 <ehird`_> oh yes! those things
20:28:40 <oklopol> *any good though
20:29:01 <oklopol> i'll include the example progs i made
20:29:43 <Hiato> Yes please
20:31:35 <Hiato> Where can I paste some text, quickly, anonymousely?
20:31:44 <oerjan> and also if i'm not here don't be afraid to ask in #haskell, the world's friendliest programming language channel
20:31:57 <Hiato> on the web?
20:31:59 <oerjan> pastebin.ca rolls off my tongue
20:31:59 <oklopol> http://www.vjn.fi/pb/p123363511.txt
20:32:23 <Hiato> right, thanks
20:32:27 <ehird`_> oerjan: http://hpaste.org/4720
20:32:33 <oerjan> but there are lots of them
20:32:38 <oklopol> also /pb/, if you don't care about quality ;)
20:32:43 <ehird`_> hahaha how ironic, you just mentioned #haskell, and someone mentioned pastebins
20:33:00 <ehird`_> the best ever pastebin will be written by me in oklotalk :P
20:33:05 <ehird`_> Or maybe Haskell, since I seem to like haskell
20:33:06 <Hiato> :)
20:33:10 <oerjan> ehird`_: replicate b '+'
20:33:29 <oerjan> etc.
20:33:44 <oklopol> oh, right, the coke
20:33:47 <oklopol> ->
20:34:02 <oklopol> damn... at this hour you still need coke outside :<
20:34:14 * oklopol needs to turn his sleep cycle forward...
20:34:18 <oklopol> whoooops
20:34:25 <oklopol> damn... at this hour you still need clothes outside :<
20:34:31 <ehird`_> oerjan: is the show (Move a) ++ blah good though?
20:34:36 <ehird`_> otherwise, it's code repetition
20:34:40 <oklopol> freudian slip
20:34:45 <oklopol> or is that anti-freudian
20:34:47 <oklopol> ->
20:35:36 <oerjan> ehird`_: er, don't you need a backwards move too?
20:35:58 <ehird`_> show (Add 0 b) | b > 0 = '+' : show (Add 0 (b - 1))
20:35:59 <ehird`_> show (Add 0 b) | b < 0 = '-' : show (Add 0 (b + 1))
20:35:59 <ehird`_> show (Add a b) = show (Move a) : show (Add 0 b)
20:36:03 <ehird`_> i mean show (Add a b) there
20:36:10 -!- UnrelatedToQaz has quit ("ChatZilla 0.9.79 [Firefox 2.0.0.11/2007112718]").
20:37:00 <ehird`_> anyway
20:37:03 <oerjan> ehird`_: need ++ not : at least
20:37:04 <ehird`_> oerjan: before and after: http://hpaste.org/4720
20:37:09 <ehird`_> yeah
20:37:12 <ehird`_> i did that :-)
20:38:03 <oerjan> actually: replicate (abs b) (if b < 0 then '-' else '+')
20:38:20 <Hiato> http://hpaste.org/4721
20:38:27 <Hiato> check it out, let me know
20:39:14 <ehird`_> oerjan: that's a bit ugly
20:39:37 <oerjan> as you wish
20:39:56 -!- RedDak has joined.
20:40:29 <oerjan> oh and it doesn't matter here but the usual way to do a second line after a guard is | otherwise without repeating the pattern
20:42:07 <oerjan> Hiato: hpaste is really only for relatively short haskell code
20:42:14 <Hiato> woops
20:42:18 <oerjan> your text was truncated
20:42:20 <Hiato> should I remove it?
20:42:24 <ehird`_> show (Loop a b) = show (Move a) ++ "[" ++ show (Move (-a)) ++ show b ++ show (Move a) ++ "]"
20:42:25 <Hiato> aha, I see
20:42:29 <ehird`_> oerjan: there has to be a better way to od that
20:42:30 <oerjan> and amusingly colored :)
20:43:07 <bsmntbombdood> someone give me a name
20:43:16 <bsmntbombdood> not overtly common but not unusual
20:43:16 <oerjan> Paul
20:43:22 <bsmntbombdood> a full name
20:43:29 <oerjan> John B. Griffith
20:43:40 <ehird`_> bsmntbombdood: Rodger Nintendo
20:43:42 <Hiato> how do I remove?
20:43:42 <ehird`_> wait, what
20:43:42 * oerjan wonders if he exists :)
20:43:50 <oerjan> Hiato: i don't think you can
20:44:06 <Hiato> meh
20:44:13 <oerjan> the author identification is not working...
20:44:31 <bsmntbombdood> i'll go with Paul Griffith
20:45:23 <oerjan> ehird`_: i don't think there is any much better way there
20:45:24 <oklopol> Hiato: i have to agree with pikhq, you have some skill at designing esolangs
20:46:16 <Hiato> Thanks oklopol
20:46:17 <Hiato> :)
20:46:25 <Hiato> http://rafb.net/p/x491Ou33.html
20:46:29 <Hiato> ok, full manual
20:46:59 <ehird`_> oerjan: http://hpaste.org/4720#a2 i really don't like the look of this :(
20:47:22 <ehird`_> also i keep bleeding up against 80 cols :(
20:48:24 <oerjan> hm a helper function:
20:49:06 <oerjan> showMoveBrak a s = show (Move a) ++ s ++ show (Move (-a))
20:49:12 <ehird`_> Brak?
20:49:19 <oerjan> er, bracketed
20:49:25 <oerjan> couldn't think of a good name
20:49:39 <ehird`_> :P it'll do
20:49:44 <oklopol> Hiato: what country is .za? just wondered about your name :)
20:49:55 <Slereah> Zambia?
20:50:01 <Hiato> sure, its South Africa
20:50:03 <Hiato> nope
20:50:05 <ehird`_> south africa
20:50:10 <ehird`_> ...haha
20:50:11 <Slereah> Zouth Africa?
20:50:12 <ehird`_> google powah
20:50:17 <Hiato> well Zuid Africa
20:50:22 <Hiato> in afrikaans
20:50:25 <ehird`_> None of the official names for South Africa can be abbreviated to ZA, which is an abbreviation of the Dutch Zuid-Afrika. This is a legacy of when Dutch was an official language in South Africa, before being replaced by Afrikaans, in which the name of the country is Suid-Afrika. Afrikaans joined English and Dutch as an official language of the South Africa in 1925, and in the South African Constitution of 1961 Dutch was removed as an of
20:50:27 <oerjan> ehird`_: also you can break things into more than one line
20:50:33 <Hiato> and sa is south ammerica
20:50:37 <ehird`_> oerjan: i did, but it looks ugly
20:50:46 <Hiato> yip, eihrd`_ nailed it :)
20:51:05 <ehird`_> wikipedia powah
20:51:12 <Hiato> :)
20:51:53 <Slereah> Are you the only guy on the esomap from South Africa?
20:52:00 <Slereah> Klerksdorp.
20:52:06 <oklopol> "i.e. executing No-Op will
20:52:06 <oklopol> result in the data origin remaining intact but the data destination being modified."
20:52:09 <oklopol> i don't get it
20:52:09 <Slereah> Or are you not on it.
20:52:12 <Hiato> I think so
20:52:13 <oklopol> isn't no-op a nop?
20:52:18 <Hiato> well, I'm not on it :0
20:52:23 <Hiato> No-Op = No Operation
20:52:54 <Hiato> Ie, when you send things through a No-Op, the data destination is increased by the value in the data origon
20:52:59 <Hiato> well, yes
20:53:04 <Hiato> No-Op = nop
20:53:08 <Hiato> but I prefer No-Op
20:53:24 <ehird`_> oerjan: showMoveBrak :: Int -> String -> String
20:53:27 <ehird`_> i can has type sig!
20:53:42 <Hiato> Sleereah, I'm in Johannesburg, not Klerksdorp ;)
20:54:05 <ehird`_> oerjan:
20:54:06 <ehird`_> *Main> parse ",[.,]" [,,[[.,,]],.,,]
20:54:08 <ehird`_> i have work to do
20:54:17 <Slereah> 'kay
20:54:28 <ehird`_> on my parser, though
20:54:28 <oklopol> ah, so ~ always moves stuff from one memory layer to the other
20:54:48 <Slereah> (I remembered that there was just one point in Africa, and it was South Africa)
20:54:49 <ehird`_> oh wait
20:54:49 <Hiato> yuip
20:54:54 <ehird`_> i really want an instance of Show [BF] too
20:54:59 <Hiato> (lol :P )
20:55:10 <Hiato> I'm not so sure how clear that was oklopol, sorry
20:55:28 -!- ihope has quit ("CGI:IRC (Ping timeout)").
20:55:32 <Hiato> but during it's move, it's modified by the current command
20:55:42 <ehird`_> oerjan: show [x,y] where show x = "a" and show y = "b" is "ab"
20:55:45 <ehird`_> what function does that?
20:55:51 <ehird`_> i.e. map-then-join-with-no-sep
20:56:09 <oklopol> Hiato: i guessed that, but it may well be said clearly in the spec
20:56:17 <oklopol> i'm bad at noticing stuff
20:56:39 <oklopol> hmm, what exactly does it mean when a row is shifted?
20:56:40 <Hiato> lol, no prob. It's probably written badly though, haven't revised it at all
20:56:53 <Hiato> well, picture a grid type situation
20:56:57 <oklopol> yeah
20:57:02 <Hiato> where you have a row containing say 6 4 5
20:57:07 <Hiato> then you shift left
20:57:08 <oklopol> yeah
20:57:13 <ehird`_> oerjan: unwords adds a space
20:57:16 <Hiato> it becomes 4 5 6
20:57:28 <Hiato> almost kinda like a rubix cube
20:57:33 <oklopol> oh, hehe, thought the whole row moves :)
20:57:34 <Hiato> but 2d and wrap around
20:57:45 <oklopol> but indeed, row is - and column is |
20:57:57 <Hiato> lol :D. I will revise the spec to make that more clear :)
20:58:11 <Hiato> yep (that is right? )
20:58:50 <oerjan> ehird`_: concatMap
20:59:09 <ehird`_> instance Show [BF] where show = concatMap show
20:59:14 <ehird`_> lean, mean, currying, one-lining machine
20:59:23 <ehird`_> Illegal instance declaration for `Show [BF]' (The instance type must be of form (T a b c) where T is not a synonym, and a,b,c are distinct type variables) In the instance declaration for `Show [BF]'
20:59:37 <oerjan> ehird`_: there is already a general instance for []
20:59:52 <Hiato> so Slereah, fixed the beer problem for the lm ?
21:00:04 <oerjan> actually that error is more subtle, it is because you have not enabled extensions
21:00:10 <oerjan> but you don't need them for this.
21:00:18 <ehird`_> oerjan: so, what do i do :P
21:00:57 <Slereah> Hiato : Yes I habe
21:01:02 <oerjan> instead, in the instance for BF _itself_, add a line showList = (concatMap show ++)
21:01:11 <Slereah> Here it is : http://paste-it.net/5486/raw/
21:01:14 <Slereah> With comments and all!
21:01:25 <oerjan> er wait
21:01:34 <oerjan> messed up
21:01:43 <Slereah> If it doesn't work, I'll also upload the last version of the love machine. I don't remember which one I uploaded last
21:01:53 <oerjan> showList l s = concatMap show l ++ s
21:02:02 <oerjan> too much pointlessness :)
21:02:23 <ehird`_> showLis tl = concatMap show l ++
21:02:27 <ehird`_> just right!
21:02:27 <Hiato> cool, thanks Slereah
21:02:27 <ehird`_> :-)
21:02:28 <Hiato> :)
21:03:07 <Hiato> awesome stuff that comments state :)
21:03:12 <ehird`_> oerjan: i think i need to ditch the ++
21:03:14 <ehird`_> *Main> parse ",[.,]" ,[.,].,
21:03:25 <oklopol> hihi happy comments :)
21:03:27 -!- dak has joined.
21:03:39 <Slereah> Actually, it just takes advantage of the fact that the love machine doesn't look what's in a state until it calls them.
21:03:54 <oerjan> ehird`_: you missed the s in my correction
21:03:58 <Hiato> lol, cool :)
21:04:01 <Slereah> I could probably make a better comment system
21:04:08 <Hiato> ps: Line feeds make it way way slower.....
21:04:18 <Hiato> hugely slow
21:04:46 <ehird`_> yes oerjan but i missed the param too :-)
21:04:49 <ehird`_> so it's valid pointless
21:05:05 <Slereah> Doesn't seem any slower than before to me.
21:05:13 <oerjan> ehird`_: for pointlessness you need to have parentheses around it
21:05:18 <Hiato> So overall, oklopol, is it worth pursuing as an Esolang?
21:05:24 <Slereah> It's not a very efficient program, you should know that.
21:05:37 <Slereah> I could probably make a better version.
21:05:50 <Hiato> :)
21:05:50 <ehird`_> i did oerjan
21:05:53 <Slereah> I'll probably try once I isntalled m-states.
21:05:54 <oerjan> because it has an operator at the end
21:05:59 <ehird`_> showList l = (concatMap show l ++)
21:06:17 <Hiato> Sure, well priorities... (beer should be up there :P j/k )
21:06:17 <ehird`_> *Main> parse ",[.,]" ,[.,].,
21:06:19 <ehird`_> still wrong
21:06:26 <ehird`_> oh wait
21:06:26 <ehird`_> duh
21:06:33 <ehird`_> parse ('[':s) = Loop 0 (parse s) : parse s
21:06:34 <oklopol> Hiato: i'd say, and considering the amount of trivial brainfuck derivatives, that's quite a sophisticated lang
21:06:37 <ehird`_> see if you can spot the error! :-)
21:06:51 <Hiato> Thanks very much oklopol :D
21:06:52 <oerjan> yep
21:07:12 <oklopol> Hiato: only being polite so you'd read the graphica spec ;))
21:07:16 <oerjan> you may need a more clever parser
21:07:16 <ehird`_> oerjan: http://hpaste.org/4722 i think i'd have to do a pretty major parser change for that
21:07:19 <oklopol> (just kidding)
21:07:27 <ehird`_> (note that this also behaves weird on ]s in other places, iut was just a quick hack)
21:07:31 <Hiato> lol, I read it anyway ;)
21:07:34 <Hiato> (lol)
21:07:55 <ehird`_> oklopol: does oklotalk have objects?
21:07:58 <ehird`_> or classes
21:08:52 <oklopol> no classes
21:09:09 <oklopol> prototype-based oo is possible
21:09:16 <oklopol> using functions.
21:09:24 <ehird`_> ok.
21:09:25 <oklopol> kinda like javascript ;;;;)
21:09:43 <ehird`_> i'm going to sketch out my Counter application for my hypothetical oklotalk-based web framework :P
21:09:47 <ehird`_> give me an example of that oo?
21:10:05 <oerjan> ehird`_: the usual trick is to return the part remaining after the parse
21:10:38 <oerjan> so parse "++-+]-+++" = (something, "]-+++")
21:10:49 <ehird`_> oerjan: i see
21:10:50 <ehird`_> :-)
21:11:07 <ehird`_> i'll need a helper function instead of : then
21:11:10 -!- Sgeo has joined.
21:11:22 <oklopol> Animal={§say -> outn "A generic animal says nothing!"}; Turtle=Animal+{§say -> outn "Turtle says moo"}
21:12:00 -!- RedDak has quit (Read error: 110 (Connection timed out)).
21:12:01 <ehird`_> oklopol: ok, now pick another symbol instead of fucked-S so i can type it
21:12:12 <oklopol> lol :)
21:12:16 <ehird`_> alternatively, this is an idea:
21:12:21 <ehird`_> use tons of unicode chars
21:12:21 <ehird`_> instead of =>
21:12:25 <oklopol> heh
21:12:28 <ehird`_> use the unicode two-pronged-arrow-right thing
21:12:45 <ehird`_> then, i won't complain and instead will just make an emacs/whatever mode that rebinds loads of keys to that
21:12:49 <oklopol> just make your own simplified oklotalk -dialect...
21:12:49 <ehird`_> like an APL-for-modern-machines does! :D
21:12:57 <ehird`_> my idea is cooler :(
21:13:00 <ehird`_> it's more weird, like oklotalk!
21:13:07 <oklopol> you won't be able to make a full interp anyway using the examples i give you
21:13:14 <ehird`_> i know that
21:13:14 <ehird`_> but even so
21:13:41 <oklopol> that'd be a cool idea if i knew how to produce those characters.
21:13:49 <ehird`_> oklopol: what editor do you use
21:13:50 <oklopol> i don't really care about the characters.
21:14:00 <oklopol> gedit nowadays
21:14:01 <Sgeo> Grr my dad locked the computer
21:14:24 <ehird`_> oklopol: OK, well start using emacs and i'll write an oklotalk-mode that lets you type then :-)
21:14:25 <ehird`_> *them
21:14:26 <ehird`_> :P
21:14:39 <ehird`_> alternatively, release an oklotalk spec using them and i'll write an editor in it that lets you type them
21:14:39 <ehird`_> :D
21:14:47 * Sgeo is a bit too irritated to really work on PSOX
21:14:52 <oklopol> heh
21:14:52 <Sgeo> pikhq, what do you have?
21:15:14 <Hiato> wassup Sgeo :)
21:15:16 <ehird`_> oklopol: with that thing you did, how can you do super? i.e. call the same function in the parent object, and how do you clone an object, and how do you create an initialization function?
21:15:24 <ehird`_> i guess:
21:15:33 <oklopol> you can make those synthetically
21:15:36 <ehird`_> yes
21:15:38 <ehird`_> but
21:15:40 <ehird`_> how do i call a method
21:15:41 <ehird`_> :-)
21:15:43 <oklopol> and they'll be there as built-ins.
21:15:59 <oklopol> Object!§Method
21:16:12 <oklopol> or object §method
21:16:18 <oklopol> there are lots of ways to calla function
21:16:20 <oklopol> *call a
21:16:21 <Hiato> Sgeo : http://www.rafb.net/p/x491Ou33.html tell me what you tink
21:16:25 <Hiato> *think
21:16:26 <ehird`_> is there a 'returning x as y, z'?
21:16:27 <ehird`_> that is:
21:16:33 <ehird`_> well
21:16:33 <ehird`_> i mean
21:16:36 <ehird`_> a construct behaving like this:
21:16:46 <ehird`_> x = y; ...stuff using x...; y
21:17:11 * Sgeo has no opinion
21:17:24 <ehird`_> oklopol: wait, don't need it
21:17:32 <Sgeo> Does the interpreter read character-by-character, or line-by-line?
21:17:33 <Hiato> (gee thanks -_-)
21:17:38 <Sgeo> I mean, read stdin
21:17:40 <Hiato> ( ;) )
21:17:47 <ehird`_> oklopol: ok, one final question: how can i check whether an object has a certain method or not
21:18:04 <Sgeo> It needs to read stdin character-by-character in order to work with PSOX
21:18:13 <Hiato> My interpreter?
21:18:20 <ehird`_> well, naive new: New={o=_+{}; o §init; o}
21:18:22 <Sgeo> It can write to stdout line by line, and in fact, PSOX.py will do that :/
21:18:25 <Sgeo> Hiato, yes
21:18:33 <ehird`_> oklopol: what about instance vars
21:18:40 <ehird`_> and what about 'self'
21:18:46 <oklopol> function gives out it's patterns using F!#something
21:18:46 <Hiato> Yes, character by character (the Full 0 one at least, this one doesn't exist yet)
21:18:49 <oklopol> don't remember what
21:19:09 <oklopol> do a {_!0}\(F!#ptrns)
21:19:14 <oklopol> and you have the methods
21:19:28 <oklopol> self is '
21:21:27 <oklopol> anyhow, hope that really is your final question, since i think i'll stop answering your further questions now :<
21:21:34 * oerjan read that as instance wars
21:21:50 <ehird`_> oerjan: should i do (list, rest)?
21:21:53 <oklopol> uhh, what a title
21:21:55 <ehird`_> or could 'list' be something better
21:22:09 <oklopol> Instance Wars: The Awakening
21:22:24 <oerjan> whatever structure you want
21:22:45 <oerjan> for a list of BF commands, list seems fine...
21:22:47 <ehird`_> oerjan: asking for a suggestion :-)
21:22:56 <ehird`_> hm
21:23:00 <oklopol> Hiato: you read the spec as future tense, present or past?
21:23:02 <ehird`_> i need some kind of parse-dispatcher
21:23:03 <ehird`_> to loop parse
21:23:06 <oklopol> since i wants opinions :-)
21:24:39 <oerjan> you may have a single command parser, and a command list parser which are mutually recursive
21:24:45 <Hiato> lol, sorry
21:24:56 <Hiato> you know what I meant though
21:25:19 <oklopol> err no actually, that's why i asked :)
21:25:38 <Hiato> lol, ok "I want opinions"
21:25:55 <oklopol> opinions regarding graphica, that is
21:26:00 <Slereah> I want onions.
21:26:03 <oklopol> who doesn't
21:26:07 <Hiato> shrek
21:26:10 <Hiato> :)
21:26:16 <ehird`_> oerjan: alrighty
21:26:25 <ehird`_> oerjan: parse and parseChar, dynamic duo
21:26:48 <Hiato> wait, now I'm confused
21:26:51 <oerjan> ehird`_: except parseChar will parse an entire loop if it hits one
21:27:07 <ehird`_> oerjan: parseInstruction's a bit too long...
21:27:09 <ehird`_> oerjan: parseFoo?
21:27:10 <Hiato> who's spec was that that I read and said wants opinions? Mine are yours oklopol ?
21:27:10 <oklopol> i'll try to explain, if you're confused about the spec.
21:27:17 <oklopol> ...?
21:27:18 <oerjan> parseCmd
21:27:24 <Hiato> I am soo lost
21:27:27 <oklopol> hehe
21:27:31 <oklopol> Graphica spec is by me
21:27:35 <oklopol> and i want onions about it.
21:27:38 <Hiato> yes, I know that
21:27:40 <Hiato> oh
21:27:41 <ehird`_> oerjan: you've almost fully converted me to loving haskell, byt he way :-)
21:27:41 <Sgeo> Would anyone object that PSOX.py writes to stdout line-by-line?
21:27:46 <ehird`_> it's a lot simpelr than i thought
21:27:53 <oerjan> heh :)
21:28:05 <Hiato> "Hiato: you read the spec as future tense, present or past?" Because I though that that was a comment about something I had said about my spec
21:28:06 <oklopol> i didn't paste it here for your enjoyment, but because i wanna know if it's readable :P
21:28:09 <ehird`_> oerjan: parseCmd :: String -> BF -- seems right to me
21:28:14 <oklopol> oh, sorry
21:28:30 <oklopol> i meant about the grph. spec
21:28:33 <Sgeo> ehird`_, does this mean you're going to write a PSOX Server in Haskell?
21:28:37 <oerjan> ehird`_: -> (BF, String)
21:28:42 <ehird`_> Sgeo: If you want. SUre.
21:28:47 <ehird`_> oerjan: Whoops, yes
21:28:57 <Hiato> sure, will read and concentrate now :)
21:28:57 <Sgeo> erm, that was a joke >.> you don't need to do that
21:29:04 <ehird`_> oerjan: and parse :: String -> ([BF], String)?
21:29:16 <ehird`_> Sgeo: Well why not
21:29:20 <oerjan> right
21:29:36 <oerjan> in fact take a look at the definition of ReadS
21:29:50 <Sgeo> ehird`_, it would be a bit of a project, and also domain implementors would also need to implement their domains in Haskell >.>
21:30:01 <oerjan> it's a type for simple parsers, used by the Read class
21:30:12 <ehird`_> Sgeo: so what you won't have a standard for domain implementation languge
21:30:17 <ehird`_> Sgeo: also no it wouldn't be
21:30:21 <ehird`_> no harder than psox.py
21:30:28 <ehird`_> someone get lambdabot in here
21:30:32 <ehird`_> s/lambdabot/a lambdabot./
21:30:38 * Sgeo considers PSOX.py to be a bit of a project
21:30:59 <ehird`_> psox is trivial
21:31:40 <Sgeo> Have you read the specs at any time after it came into existance from being branched off of PESOIX?
21:31:45 <ehird`_> yes
21:32:14 <oerjan> bah, lambdabot doesn't have @src ReadS anyhow
21:32:32 <oerjan> just do :i ReadS in the interpreter
21:33:04 <Hiato> hrmm, well oklopol... I must say, that yes, I get the basic gist of what is going on, but the syntax is laid out awkwardly
21:33:17 <oklopol> you mean the bnf thingie?
21:33:21 <Hiato> the explination, that is
21:33:23 <Hiato> yip
21:33:34 <oklopol> the expression syntax would've been too weird given as a bnf...
21:33:39 <oklopol> i mean, that's what i thought
21:33:44 <oklopol> so it's explained separately
21:33:48 <Hiato> I see
21:33:50 <oerjan> ehird`_: although for more complicated parsers, the Parsec library is your friend.
21:34:00 <oklopol> can you point out what exactly is bad about it?
21:34:21 <ehird`_> oerjan: I've tried Parsec before! I liked it. Nice paradigm.
21:34:24 <ehird`_> But not for Brainfuck
21:34:25 <ehird`_> :-)
21:34:34 <oerjan> it's a bit overkill for that
21:34:40 <ehird`_> *Main> :i ReadS type ReadS a = String -> [(a, String)] -- Defined in Text.ParserCombinators.ReadP
21:34:44 <ehird`_> how useless
21:34:59 <Hiato> well, just the way that things are broken down, perhaps start with the most basic structers and then build it up
21:35:10 <Hiato> instead of starting with something that needs
21:35:27 <Hiato> to be referenced from the bottom of the list
21:35:37 <Hiato> perhaps have the smallest ones first/most basic
21:35:44 <Hiato> then the more composite and advanced structers
21:35:50 <ehird`_> Hiato: that's not how most bnf is layed out
21:35:55 <Hiato> anyway, that's what I feel
21:36:03 <Hiato> well, yes, but the Graphi one isn't
21:36:06 <Hiato> it's backwards
21:37:15 <Hiato> *Graphica
21:37:25 <Hiato> or have I had one too many
21:37:41 <ehird`_> oerjan: so what IS readS
21:37:44 <ehird`_> :-))
21:37:46 <ehird`_> oh wait
21:37:48 <ehird`_> it's a type
21:37:49 <ehird`_> duh :-)
21:37:59 <oerjan> also do :i Read
21:38:04 <ehird`_> hm so parse :: ReadS BF
21:38:10 <oerjan> that's the class that uses it
21:38:26 <oklopol> i don't consider that an issue really, but usually bnf's go bottom-down
21:38:30 <ehird`_> Read confuses me, so I'm going to ignore it!
21:38:31 <oklopol> at least that's my experience.
21:38:39 <ehird`_> ... is that ok? :P
21:38:48 <oklopol> ...
21:38:51 <oklopol> bottom-down xD
21:38:53 <oklopol> top-down
21:38:54 <ehird`_> Actually, I think for BF i should just repeat the readS type
21:38:54 <oklopol> i mean
21:38:55 <ehird`_> it's tiny anyway
21:38:56 <oklopol> lol
21:38:58 <oerjan> although i don't think you need the list around just for bf
21:39:31 <Hiato> lol, well sure, it's your language, and you're more experienced
21:39:34 <oerjan> otoh maybe you do, an empty list signals a parse error
21:39:51 <Hiato> but I just felt it awkward to reference stuff that hadn't yet been introduced
21:39:51 <ehird`_> parse :: String -> [(BF, String)] parse "" = [] parse s = let (p, s') = parseCmd s in p : parse s'
21:39:57 <ehird`_> oerjan: looks right to me
21:40:24 <oerjan> er... no that's not how it's used
21:40:37 <ehird`_> welp, it should work fine actually
21:40:39 <ehird`_> looking at this code
21:40:54 <oerjan> you want ([BF], String)
21:41:00 <ehird`_> nope
21:41:09 <oklopol> Hiato: apart from that, do you understand it? i don't see any difference in the order they're given myself, i've just seen top-down more frequently, so i used that.
21:41:20 <ehird`_> err
21:41:24 <ehird`_> that makes parse String -> [BF]
21:41:28 <oklopol> the evaluation part is top-down too.
21:41:29 <ehird`_> yeah i'll fix that.
21:41:44 <ehird`_> no wait. you are right oerjan
21:41:54 <Hiato> hrmm, yes that aside, I get the flow of it, but not the whole thing entirely
21:42:57 <ehird`_> uh oerjan what should an example result look like from parse
21:43:02 <ehird`_> say (parse ",[.,]")
21:43:19 <Hiato> I feel like I'm missing something (not sure what) but something to make the jump from bnf to example
21:43:29 <Hiato> but I could get it if I stared at it long enough I suppose
21:43:39 <oerjan> ([In 0, Loop 0 [Out 0, In 0]], "")
21:43:55 <oerjan> iirc your types
21:43:56 <oklopol> yeah, i myself feel it explains it all, but doesn't really explain anything :)
21:44:08 <oklopol> should be a bit more example'y i guess
21:44:21 <ehird`_> oerjan: Write and Read, actually. So - parse always is (tree, "")?
21:44:36 <oerjan> not always
21:44:47 <oerjan> if you call parse recursively, it should stop at ]
21:45:15 <ehird`_> parse ",[.,],[.,]" -> ?
21:45:17 <oerjan> because it is then used to parse inside a loop
21:45:25 <Hiato> Yeah, that would be nice, like a walk through idiot example
21:45:26 <Hiato> just one
21:45:36 <oerjan> that will also end with ""
21:45:51 <oklopol> i'll make a short tutorial, that + the spec might clear it up a bit
21:46:04 <oklopol> hmmm... wonder if it's time to put my languages on the esowiki :-)
21:46:04 <ehird`_> oerjan: what wouldn't
21:46:09 <ehird`_> (this is like talking to SHRDLU :-))
21:46:19 <oklopol> been wondering whether i should from the day i joined here
21:46:31 <oerjan> but parse ".,],[.,]" = ([Write 0, Read 0], "],[.,]")
21:46:52 <Hiato> Yeah, that would be awesome. Ha, I think it's about time Full 0 got onto the wiki
21:46:56 <Hiato> but I have no clue how
21:46:59 <ehird`_> shoudln't you get a parse error, oerj?
21:47:03 <oerjan> and that one would be a recursive call used for the loop of the former one
21:47:13 <oklopol> Hiato: just as you'd use any other wiki
21:47:14 <oerjan> no.
21:47:15 <oklopol> ...i think
21:47:29 <oklopol> oerjan and ehird`_ can tell you that
21:47:39 <oklopol> i've never touched a wiki in my life :P
21:47:40 <ehird`_> oerjan: i don't see what definition parse could have
21:47:41 <ehird`_> :(
21:47:42 <oklopol> scaaary
21:47:44 <Hiato> Ditto
21:47:54 <Hiato> we see the same things :)
21:47:59 <ehird`_> Oklowiki will solve that! it shall be trivial!
21:48:03 <ehird`_> and written in Oklotalk!
21:48:05 <Hiato> :P
21:48:06 <ehird`_> With my fictional web framework
21:48:09 <Hiato> oh yeah :)
21:48:11 <oklopol> heh
21:48:28 <Hiato> To help protect against automated account creation, please solve the simple sum below and enter the answer in the box (more info): 32 + 10 = LOLOLOL
21:48:37 <oerjan> ehird`_: you just add a special case parse s@(']':_) = ([], s)
21:48:39 <ehird`_> 32 + 10 = 3210
21:48:42 <oklopol> oklowiki is a virtual wiki that automatically uses every wiki it can find on google simultaneously.
21:48:43 <Hiato> a malbolge script could do that
21:48:50 <ehird`_> oerjan: s@p? bizzare
21:48:51 <ehird`_> oklopol: haha no
21:48:52 <Hiato> Wicked
21:49:00 <ehird`_> Hiato: btu it won't know to look for that.
21:49:17 <ehird`_> Hiato: it will just say 'porn viagra cuddly toy' for all fields, or similar
21:49:19 <ehird`_> and thus fail
21:49:21 <Hiato> well, it will with PSOX and some genetic algorithms :)
21:49:22 <oklopol> ehird`_: don't use + for concatenation!
21:49:29 <Hiato> lol
21:49:30 <Hiato> true
21:49:31 <oklopol> a wise man once told me that
21:49:39 <ehird`_> oklopol: it was a pun based on such
21:49:42 -!- Sgeo has quit (Connection timed out).
21:49:46 <oerjan> ehird`_: that's an "as" pattern. it means bind s to the string, but also check that it matches the pattern ']':_
21:49:56 <ehird`_> oerjan: blind mown
21:49:56 <oklopol> ehird`_: and what i said was totally serious.
21:50:08 <oerjan> huh?
21:50:17 <ehird`_> oerjan: spoonerize it
21:50:47 <Hiato> :D nice ehird`_
21:51:07 <ehird`_> oerjan: i have my two base cases! but no parse s! time to do that :P
21:51:22 * Slereah fixed some more colon troubles on the love machine
21:51:32 <Hiato> This is awesome: "Someone, probably you from IP address 198.54.202.234, has registered an account "Hiato" with this e-mail address on Esolang."
21:51:33 <Hiato> lol
21:51:35 <Slereah> Printing them or taking them as accepting characters is annoying
21:51:53 <Slereah> (The sentence should not be interpreted in any sodomy sense)
21:52:05 <oklopol> Hiato: have you?
21:52:14 <Hiato> lol, yes oklopol
21:53:13 <Hiato> how do I create a new labguage page?
21:53:17 <Hiato> *language
21:53:41 <ehird`_> Hiato: MAGIC & LUFF
21:53:50 <Hiato> no really
21:54:01 <ehird`_> search bar
21:54:03 <ehird`_> type in name
21:54:04 <ehird`_> enter
21:54:04 <ehird`_> edit
21:54:05 <ehird`_> voila
21:54:09 <Hiato> ok, thanks
21:54:46 <oerjan> also when logging in check the box "remember me"
21:55:05 <oerjan> otherwise there is a tendency you don't stay logged in
21:55:05 <oklopol> what's that do?
21:55:12 <Hiato> well, not necessary as I delete cookies automatically when closing FFX
21:55:39 <ehird`_> Hiato: i guess you also use tor
21:55:40 <oerjan> er the problem is it sometimes forgets you _too_ soon
21:55:47 <Hiato> tor?
21:55:57 <Hiato> oh, I see
21:55:57 <ehird`_> ok, forget that
21:56:06 <Hiato> no please
21:56:07 <oerjan> but maybe it depends on browser
21:56:12 <Hiato> don't make me google it :P
21:56:28 <Hiato> tor -ibash?
21:56:29 <Hiato> tor -rent?
21:56:43 <Hiato> bit- tor -nado?
21:56:58 <oerjan> the onion router iirc
21:56:59 <ehird`_> no, just Tor
21:57:16 <Hiato> hrmm
21:57:19 <Hiato> ok, google
21:57:38 <Hiato> Tor: anonymity online
21:57:39 <Hiato> aha
21:58:05 <Hiato> well, no :P But I do use Browzar and CCleaner
21:58:25 <ehird`_> you can always tell the type of person.
21:59:18 <Hiato> yeah, tor looks wicked, downloading
21:59:22 <ehird`_> oerjan: i can't figure out a 'parse s' definition
21:59:26 <ehird`_> sigh, hiato. sigh.
21:59:33 <ehird`_> next up; freenet, i guess
21:59:59 <Hiato> ps: is there a way of using it without having to bounce many connections (limited bandwidth means I don't want to sopend it on some-one's download)
22:00:03 <Hiato> googling :P
22:00:20 <Hiato> ahh, no
22:00:26 <Hiato> freenet is a step way too far
22:00:31 <Hiato> over the edge :)
22:01:02 <Hiato> meh
22:01:03 <oerjan> well the main case should be something like:
22:01:07 <Hiato> actually tor is boring
22:01:38 <oerjan> parse s = let (p,s') = parseCmd p; (ps, s'') = parse s' in (p:ps, s'')
22:01:43 <Hiato> (PS: I clear cookies for a reason : I don't want my sis loggin in for me, and no, I do not delete history incase you were gonna ask)
22:02:10 <Slereah> http://paste-it.net/5499
22:02:11 <Slereah> http://paste-it.net/5500
22:02:17 <Slereah> Hope it works okay now.
22:02:32 <ehird`_> oerjan: what i already had was close, interestingly
22:02:44 <ehird`_> but parseCmd p?
22:02:44 <ehird`_> what is p
22:02:44 <oerjan> ehird`_: i based it on yours
22:02:46 <ehird`_> i think you mean s
22:02:51 <oerjan> er, s
22:02:53 <oerjan> sorry
22:03:01 <ehird`_> also, i'll replace ; with 'in'
22:03:11 <ehird`_> oh
22:03:12 <ehird`_> i see
22:03:13 <ehird`_> :-)
22:04:50 <oerjan> you can also remove the ; and put (ps, s'') straight under (p,s')
22:05:09 <Hiato> seems to work Slereah
22:05:11 <Hiato> just fine
22:05:21 <ehird`_> doing that, where does 'in' line up, oerjan ?
22:05:30 <ehird`_> 'let'?
22:05:33 <oerjan> doesn't matter
22:05:44 <ehird`_> parseCmd (']':s) = error, right?
22:06:01 <Slereah> I had to change it. Dealing with ":" made it crash
22:06:08 <oerjan> no, that should return ([], ']:s)
22:06:23 <Slereah> For instance, the function .+[<.+>] on the BF Love Machine 9000
22:06:26 <ehird`_> oerjan: where do i handle unmatched [s and ]s then?
22:06:31 <oerjan> it's the essential part for allowing parse to be used for parsing inside loops
22:06:39 <Slereah> It works now though.
22:07:00 <ehird`_> oerjan: parseCmd
22:07:01 <ehird`_> not parse
22:07:22 <oerjan> oh right
22:07:46 <ehird`_> hm
22:07:47 <ehird`_> *Main> parse ",[.,]" (,[.,],"]")
22:07:53 <oerjan> yep, although that error should never be triggered
22:08:05 <oerjan> yay
22:08:11 <ehird`_> parse (']':s) = ([], s)
22:08:19 <ehird`_> not: parse s@(']':_) = ([], s)
22:08:20 <ehird`_> :)
22:08:25 <ehird`_> to get rid of "]"
22:08:33 <ehird`_> or is that wrong
22:08:34 <ehird`_> :/
22:08:37 <oerjan> oh bad idea
22:08:54 <ehird`_> *Main> parse ",[.[-],]" (,[.[-],],"")
22:08:55 <ehird`_> it works fine
22:09:08 <oerjan> try parse ",]"
22:09:22 <ehird`_> well. that should be an error anyway
22:09:28 <oerjan> but it isn't
22:09:43 <ehird`_> with your definition:
22:09:44 <ehird`_> *Main> parse ",]" (,,"]")
22:09:46 <ehird`_> still isn't!
22:09:57 <ehird`_> *Main> parse "[" ([],"")
22:09:59 <ehird`_> also wrong
22:10:04 <oerjan> but that is correct
22:10:07 <oerjan> er wait
22:10:10 <ehird`_> no, [s don't magically close
22:10:11 <ehird`_> :-)
22:10:25 <ehird`_> remember, everything before ," should be the program verbatim
22:10:34 <oerjan> the latter shows you have the loop part wrong
22:10:40 <ehird`_> if it's something else (sans removing of comments), that's wrong
22:10:58 <oerjan> the loop part should check that what remains after the subparse starts with ]
22:11:55 <ehird`_> in english
22:12:01 <ehird`_> anyway
22:12:03 <ehird`_> parse s@(']':_) = ([], s)
22:12:05 <ehird`_> that is wrong, somehow
22:12:10 <ehird`_> some error check is missing, somehow
22:12:16 <oerjan> yep, should be ([], ']':s)
22:12:49 <oerjan> parse should not do error checks, it should just stop and the caller should check
22:13:06 <ehird`_> no, it should call 'error'
22:13:06 <ehird`_> :P
22:13:11 <oerjan> NO!
22:13:15 <ehird`_> bah
22:13:16 <ehird`_> why not
22:13:17 <ehird`_> :(
22:13:23 <oklopol> ehird`_: are you making a bf parser or was that something more complicated already?
22:13:28 <oklopol> i forgot what you were doing
22:13:30 <oklopol> :P
22:13:32 <ehird`_> oklopol: bf parser
22:13:35 <oklopol> yarrr
22:13:40 <oklopol> made one once
22:13:44 <ehird`_> which will then optimize and compile :P
22:13:44 <oerjan> because parseCmd ('[':s) calls parse s
22:13:57 <ehird`_> oerjan: i didn't say it should always call error
22:14:20 <oerjan> sure, the caller should check, not parse
22:14:29 <ehird`_> no, because 'parse' is toplevel parsing
22:14:50 <ehird`_> theoretically, main = dump (compile (optimize (parse read))))
22:14:51 <ehird`_> not literal ofc
22:15:03 <oerjan> then you need another function
22:15:18 <ehird`_> :|
22:15:39 <oerjan> say parseCmdList
22:15:57 <ehird`_> to be equal to the current parse?
22:16:02 <oerjan> yep
22:16:10 <ehird`_> ok, now tell me how i check for errors from parse
22:16:10 <ehird`_> :|
22:16:44 <oerjan> parse s = case parseCmdList of (cmdList, "") -> cmdList; _ -> error ...
22:17:04 <ehird`_> oerjan: hmm, also i'd like to be able to say "Unmatched [ at line X, column Y" and the same for ]s
22:17:12 <ehird`_> which seems like it'd quickly veer into non-haskelly territory
22:17:14 <oerjan> *parseCmdList s
22:17:27 <oerjan> um...
22:17:49 <oerjan> you want to keep track of file positions?
22:18:09 <ehird`_> no.
22:18:15 <ehird`_> but: parse "a["
22:18:17 <ehird`_> is
22:18:23 <oerjan> in that case Parsec doesn't seem as that much overkill anymore. it does that.
22:18:27 <ehird`_> error "Unmatched [ at line 1, column 2."
22:18:37 <ehird`_> wouldn't parsec be a bit slow for this though?
22:18:57 <ehird`_> well
22:19:00 <ehird`_> i just mean it has so much stuff
22:19:07 <ehird`_> and bf parsing isn't /that/ complex
22:19:14 <oerjan> an Unmatched [ would always be at the end of the program...
22:19:51 <ehird`_> no, oerjan
22:19:58 <ehird`_> parse ",[.,"
22:20:00 <ehird`_> line 1, column 2
22:20:02 <oerjan> oh wait
22:20:06 <ehird`_> the [ is the thing that is unmatched
22:20:08 <oerjan> hm right
22:20:22 <oerjan> in that case even Parsec needs a bit of trick
22:21:51 <oerjan> well you now have to keep track of lines and columns
22:21:54 <ehird`_> oerjan: ofc this is nothing special
22:21:56 <ehird`_> hm
22:22:05 <ehird`_> i guess parseCmd and parseCmdList could take line/col args
22:22:09 <ehird`_> but that seems... ugly
22:22:59 <oerjan> the alternative is using a state Monad
22:23:10 <ehird`_> oerjan: that souhnds kind of ugly too :)
22:23:11 <oerjan> (which passes line/col under the hood)
22:23:23 <ehird`_> monad sounds nicer than the args, though
22:23:24 <ehird`_> so: shoot
22:23:35 <oerjan> ouch
22:23:53 <ehird`_> shoot foot
22:23:59 <ehird`_> main = shoot foot
22:24:25 <oerjan> i'm not sure i am ready to explain monads practically
22:24:34 <ehird`_> i know monads!
22:24:41 <oerjan> ok
22:24:54 <ehird`_> they're just dummy objects which bubble up the call stack.
22:25:02 <ehird`_> the implementation catches them and does stuff with them
22:25:05 <ehird`_> well, IO monads at least...
22:25:10 <oerjan> ayeeh
22:25:12 <ehird`_> I may be totally wrong! :D
22:25:36 <ehird`_> i guess i might be about to get a haskell mindbender
22:25:46 <ehird`_> why me? :( i even read The Little Schemer without blinking an eye!
22:26:30 <oerjan> ok i'll try a bit. recall that ReadS type?
22:26:37 <ehird`_> no, but i can
22:26:40 <ehird`_> tap tap tap click
22:26:42 <oerjan> type ReadS a = [Char] -> [(a,[Char])]
22:26:51 <ehird`_> thank you
22:26:51 <ehird`_> :P
22:27:01 <ehird`_> and it's String, actually. but same thing
22:27:13 <oerjan> now there is another type lurking around in Control.Monad.State ...
22:27:30 <ehird`_> called Cuddly?
22:27:42 <oerjan> newtype StateT s m a = StateT { runStateT :: s -> m (a,s) }
22:27:56 <ehird`_> okay, wait, let me get that
22:28:11 <ehird`_> what does the X .. = X { ... } stuff mean?
22:28:20 <ehird`_> i get that you have a runStateT function
22:28:36 <ehird`_> which takes a value of type s, returns a value of... something?
22:28:42 <oerjan> it's a newtype definition, the format is basically like data
22:28:49 <oerjan> but this uses record syntax
22:28:52 <ehird`_> the what
22:29:20 <oerjan> it is almost the same as data StateT s m a = StateT (s -> m (a,s))
22:30:03 <ehird`_> OK this isn't getting muchplace :P
22:30:28 <oerjan> anyway it is just a type wrapper around the s -> m (a,s)
22:30:57 <oerjan> now set s = String, m = []
22:31:11 <oerjan> and you get String -> [(a, String)]
22:31:35 <ehird`_> ok.
22:31:42 <ehird`_> So how does this help me with line and col numbers!
22:32:02 <oerjan> er right
22:32:14 <oerjan> maybe a bit mixup there
22:32:30 <ehird`_> :D
22:33:55 <oerjan> well let's say we have some data SourcePos = SourcePos SourceName !Line !Column
22:34:07 <ehird`_> !Line? !Column?
22:34:10 <ehird`_> whut is !
22:34:10 <oerjan> (from Parsec)
22:34:23 <oerjan> er ignore those !'s, they're strictness annotations
22:35:01 <oerjan> type Line = Int; type Column = Int
22:35:22 <ehird`_> So I'll just do Int Int :P
22:35:40 <ehird`_> newtype SourcePos = Int Int -- am i rite
22:35:44 <oerjan> then State SourcePos is a monad which passes that around
22:35:50 <oerjan> no
22:35:53 <ehird`_> ok
22:35:57 <oerjan> you need a constructor
22:36:10 <oerjan> and newtype can only take one field
22:36:42 <oerjan> excuse me i need some food
22:37:04 <ehird`_> hello
22:39:53 * oerjan munches
22:40:03 * ehird`_ crunches
22:41:10 <oerjan> like any monad, the state monads State and StateT can be used with the somewhat imperative-style do blocks of "commands"
22:41:46 <oerjan> the state monads have the special commands get and put, which access the passed around state
22:42:29 <ehird`_> it's a mutable proxy
22:42:32 <ehird`_> is that it?
22:42:52 <oerjan> it's a simulated mutable cell
22:43:00 <ehird`_> and if so, wouldn't line/col parameters be better for this?
22:43:13 <oerjan> could be
22:43:21 <ehird`_> parseCmd :: String -> ([BF], String, Int, Int)
22:43:23 <ehird`_> etc
22:43:39 <oerjan> at least it saves you having to consider general monads at this stage
22:44:17 <ehird`_> the next part of this is trying to determine an unmatched [ or ] as soon as possible
22:44:20 <ehird`_> so i can know which one
22:44:59 <oerjan> unmatched ]'s are easy
22:45:11 <oerjan> but unmatched ['s need to search to the end.
22:46:54 <ehird`_> right
22:47:07 <ehird`_> time to look and see what is called when a ] is called outside of an inner
22:47:17 <ehird`_> because afaics there's nothing in particular
22:47:21 <ehird`_> i.e. no 'error call'
22:48:08 <Hiato> http://esoteric.voxelperfect.net/wiki/Full_0
22:48:10 <Hiato> wohoo
22:48:11 <Hiato> :)
22:48:12 <oerjan> as i said, parseCmdList (']':s) = ([], ']':s)
22:48:24 <ehird`_> oerjan: that doesn't mean there's been an error though
22:48:34 <oerjan> so the caller knows something is wrong if it doesn't expect the ]
22:48:59 <ehird`_> parseCmdList :: String -> Int -> Int -> ([BF], String, Int, Int) best. typedefinition. ever.
22:49:23 <oerjan> ah you decided to pass the Int's in as well
22:49:30 <ehird`_> well yeah
22:49:31 <ehird`_> how else? :)
22:49:32 * ehird`_ parseCmdList (']':s) = ([], ']':s)
22:49:35 <ehird`_> err
22:49:35 <ehird`_> parseCmdList (']':s) = ([], ']':s)
22:49:42 <ehird`_> parseCmdList s@(']':_) = ([], s)
22:49:47 <ehird`_> what is the difference, and which is cleaner?
22:49:52 <oerjan> there is a monad called Writer that only passes things out
22:50:24 <ehird`_> Hiato: full 0 interpreter in full 0 anyone?
22:50:50 <oerjan> well the last one does not reconstruct a new list by putting on a ']' after taking it away
22:51:04 <Hiato> he, that's hellish ahrd
22:51:07 <Hiato> *hard
22:51:10 <ehird`_> ok, but which is 'better'? :P
22:51:14 <ehird`_> Hiato: ok - full 0 interpreter in brainfuck
22:51:31 <oerjan> matter of opinion
22:51:39 <Hiato> err... right... perhaps one in Malbolge then :P ?
22:51:43 <ehird`_> oerjan: rawrrrr
22:51:44 <ehird`_> :P
22:51:54 <ehird`_> Hiato: full 0 interpreter in glass
22:52:04 <Hiato> hrmm... still hellish
22:52:12 <oerjan> er what did i answer?
22:52:16 <Hiato> even id delphi, it was allot of code
22:52:20 <Hiato> *in
22:52:36 <Hiato> but sure, ehird`_ , don't let me get in the way
22:52:37 <Hiato> :)
22:53:17 <Hiato> perhaps though, when there is time, I'll do it in a nice Esolang
22:53:27 <Hiato> something that isn't 100% 1 command type language
22:53:33 <Hiato> hopefully soon :)
22:55:12 <ehird`_> oerjan: So, when a ] is found and we're not in ['s loop, what would be called?
22:55:15 <ehird`_> can't figure it out
22:55:24 <ehird`_> i think
22:55:25 <ehird`_> parseCmdList (']':s) l c = ([], ']':s, l, c)
22:55:31 <ehird`_> but i don't know how i'd tell if that's 'bad'
22:55:45 <oerjan> the top parseCmdList would return the program prior to the ]
22:55:53 <oerjan> together with what's after.
22:56:26 <oerjan> and it would naturally return the position of the ] as well
22:57:10 <oerjan> so the caller can easily check: if the remainder starts with ], it's an unmatched ] and it's got its position
22:57:31 <oerjan> (the caller would be your parse function, i assume)
22:58:17 <oklopol> Hiato: since you are the only one showing interest, when are you leaving today? that somewhat defines my schedule since i want you to see the tutorialish once i make it
22:58:35 <oklopol> i mean, people usually go to sleep at some point.
22:59:02 <Hiato> lol, yip sure
22:59:07 <Hiato> well, unfortunately
22:59:09 <Hiato> pretty soon
22:59:13 <oklopol> thought so
22:59:19 <Hiato> as it is nearing 1 am where I am
22:59:19 <oklopol> it's 23 there or what?
22:59:22 <oklopol> oh
22:59:22 <oerjan> now on the other hand consider the loop command. it will call parse recursively, and _it_ will expect the remainder to start with ]
22:59:30 <oklopol> right, gmt+2
22:59:33 <oklopol> same as mine
22:59:34 <Hiato> yip
22:59:37 <Hiato> lol :)
22:59:44 <oerjan> if it doesn't, then you've got an unmatched [
23:00:08 <Hiato> well, you could email me, or seeing as we are both gmt+2, I will be on tomorrow afternoon
23:00:43 <oklopol> nah, i'll just show it when i see you, it's just if you're leaving, i'm gonna implement a few features first, otherwise i'll start with the tutorial
23:00:55 <ehird`_> in a case expression, oerjan
23:00:55 <Hiato> yeah, it's cool
23:00:57 <ehird`_> can you do a guard?
23:00:59 <ehird`_> i need
23:01:01 <Hiato> implement the features
23:01:02 <oerjan> yes you can
23:01:09 <Hiato> and I'll see tomorrow then
23:01:12 <ehird`_> (program, rest, _, _) | rest starts with ]
23:01:14 <Hiato> ok, time to pack it in
23:01:14 <ehird`_> or something
23:01:17 <ehird`_> or rest is ""
23:01:17 <Hiato> cheers everyone
23:01:25 <oklopol> i will not be here tomorrow, for i need to go drink alcohol with my friends... kinda impossible to prevent on new years' :<
23:01:37 <oklopol> yeah, cya
23:01:37 <Hiato> and the wiki is up (against my best instincts)
23:01:44 <oerjan> (program, rest@('}
23:01:45 <Hiato> but tomorrow=31 no?
23:01:48 <oerjan> arh
23:01:57 <oklopol> Hiato: that's when the party is, here.
23:02:02 <oerjan> (program, rest@(']':_)) ->
23:02:05 <ehird`_> parseCmdList (']':s) l c = ([], ']':s, l, c)
23:02:08 <Hiato> oh yaeh, duh
23:02:09 <Hiato> woops
23:02:10 <ehird`_> oerjan: do i need to advance l or c there?
23:02:11 <Hiato> sorry
23:02:18 <Hiato> im a day behind at 1am
23:02:19 <Hiato> ok
23:02:20 <oklopol> to be specific, it's 31. already
23:02:20 <Hiato> cheers
23:02:30 <oklopol> bye
23:02:31 <oerjan> yes
23:02:32 <Hiato> Hppy New Year to ye all
23:02:35 <Hiato> in the futire
23:02:41 -!- Hiato has quit ("Leaving.").
23:02:41 <oklopol> years all around!
23:03:30 <ehird`_> oerjan: parseCmd ('[':s) l c must change correct?
23:03:34 <ehird`_> wait, i'll dump my current code
23:04:24 <ehird`_> http://hpaste.org/4724
23:06:48 <oerjan> there is a problem there, parseCmd could run off the end
23:07:43 <oerjan> if there is an unmatched [ and the file ends with non-commands
23:08:24 <ehird`_> *Main> parseCmdList ",[xxx" 1 1 (,[*** Exception: /Users/ehird/Code/Frainbuck/Frainbuck.hs:(32,0)-(41,40): Non-exhaustive patterns in function parseCmd
23:08:25 <ehird`_> ghasp
23:08:27 <ehird`_> sheesh
23:08:31 <ehird`_> all of this and i'm not even compiling bf code yet
23:08:38 <ehird`_> this is a 20-liner in scheme, everything i have :-)
23:11:39 <oerjan> btw this is why ReadS wraps its result in a list: to be able to signal that nothing was parsed, with an empty list
23:12:26 <ehird`_> Scheme interlude.
23:12:35 <ehird`_> > (define x (delay (force x)))
23:12:37 <ehird`_> #<unspecified>
23:12:41 <ehird`_> > (force x)
23:12:45 <ehird`_> ............................................
23:12:50 <ehird`_> Ok, back to Haskell
23:13:03 <ehird`_> So, oerjan -- what do I do? :P Maybe if you gave me an example I'd understand better
23:14:09 * oerjan is getting too tired
23:14:37 <ehird`_> :(
23:14:44 <oerjan> i'll be going to bed i think
23:14:53 <ehird`_> aww
23:15:46 <oklopol> Main = Test [1 2 3 4 5]
23:15:46 <oklopol> Test x:xs :: l
23:15:46 <oklopol> <-> xs
23:15:58 <oklopol> lol, i didn't even have to do anything for that to work :P
23:16:13 <oklopol> whoops
23:16:17 <oklopol> l should be x there
23:16:21 -!- oerjan has quit ("Good night").
23:16:21 <ehird`_> what's that, oklopol? haskell? :P
23:16:26 <oklopol> nope, graphica
23:16:29 <oklopol> : is just cons
23:16:53 <oklopol> that's all i needed to do to make pattern matching like that work
23:23:19 <ehird`_> show me an example graphica program
23:23:57 <oklopol> http://www.vjn.fi/pb/p123363511.txt
23:24:00 <oklopol> there's three
23:24:19 <oklopol> quite trivial ones, now that it has lists, you can easily get much more complicated stuff
23:24:40 <oklopol> ...i think
23:24:48 <oklopol> i haven't actually *tried* anything :P
23:25:10 <oklopol> ehird`_: the examples are at the bottom
23:25:22 <ehird`_> hello world plz
23:25:40 <oklopol> lol, a graphica program cannot do anything but specify a graph.
23:25:51 <oklopol> you need to decide a representation of a string first.
23:26:28 <oklopol> it can of course create a node that is connected to itself, and whose tag is the characters of "hello world" as a list or smth
23:26:40 <oklopol> where characters are their ascii values.
23:27:28 <oklopol> main = [...] <-> main
23:28:02 <oklopol> umm sorry
23:28:05 <oklopol> main :: [...] <-> main
23:28:06 <oklopol> lol
23:31:14 <ehird`_> H connected to e ... connected to d
23:31:32 <oklopol> oh, right.
23:31:42 <oklopol> that'll be easier with the shorthands, but i can write it
23:31:44 <oklopol> wait
23:32:07 <ehird`_> and then a main that takes that and does something with it, i don't know :P
23:34:31 -!- dak has quit (Remote closed the connection).
23:34:54 <Slereah> Finally the tape machine has come back to its root!
23:35:00 <Slereah> It can now play the piano!
23:35:06 <Slereah> Although quite slowly apparently.
23:35:27 <oklopol> ehird`_: this may take a while, there seems to be another bug.
23:38:37 <Slereah> [a[cr:F#57DIF#58DINO1DID55DIF#55DIG55DIA55DINO1DIG55DIF#55DIE55DINO2DIF57DINO1DIF55DIE55DIF55DIE55DID55DID59DIHA:a]][0=#;ims=a;nd;nh;etFecF;t1]
23:38:52 <Slereah> Finally, a Turing machine can play the Monkey Island theme!
23:39:09 <Slereah> Heh.
23:46:16 <ehird`_> Oh god really??!?!
23:47:22 <Slereah> http://paste-it.net/5502/
23:47:30 <Slereah> There's a little nothing for mankind.
23:47:38 <Slereah> [a[cr:F#57RIF#58RINO1RID55RIF#55RIG55RIA55RINO1RIG55RIF#55RIE55RINO2RIF57RINO1RIF55RIE55RIF55RIE55RID55RID59:b]|b[#:RI:c;cr:LE:b]|c[#:HA:c;cr:DIRI:c]][0=#;ims=a;nd;nh;etFecF;t1]
23:47:48 <Slereah> I'm no musician, but it's recognizable.
23:48:31 <oklopol> finally
23:48:32 <oklopol> Main = String [72 101 108 108 111 44 32 119 111 114 108 100 33]
23:48:33 <oklopol> String s = String s 0
23:48:33 <oklopol> String [] i :: []
23:48:33 <oklopol> String x:xs i :: [x i]
23:48:33 <oklopol> -> String xs i+1
23:48:45 <Slereah> I can probably load the truckload of strange ASCII chars with musical notes and make some close to ASCII Brainfuck
23:48:56 <oklopol> hello world, represented by a graph in form of a linked list, basically
23:49:00 <Slereah> With the hope that no one will be foolish enough to use them!
23:49:30 <oklopol> a list will be a normal graph once i make graphs first class, so in the future that'd just be Main = "Hello, world!"
23:49:49 <ehird`_> elif prog=="":
23:49:50 <ehird`_> print "This programmer does not support empty programs as quine"
23:49:57 <ehird`_> Slereah: are you just stuffing random stuff into this? :P
23:50:07 <Slereah> Maybe a little.
23:50:11 <ehird`_> oklopol: But can you actually have "H" in there?
23:50:13 <ehird`_> "e"?
23:50:16 <ehird`_> etc
23:50:16 <ehird`_> :D
23:50:21 <oklopol> there are no chars.
23:50:26 <Slereah> But well, it is fun!
23:50:28 <oklopol> there's ints, lists and graphs
23:50:33 <oklopol> and atoms
23:50:36 <Slereah> And possibly useful.
23:50:38 <ehird`_> oklopol: atoms
23:50:42 <ehird`_> oklopol: use atoms for chars
23:50:45 <oklopol> i'll make atoms be datatype tags, yes
23:50:45 <ehird`_> like, in String
23:50:50 <oklopol> hmm?
23:50:55 <ehird`_> if String sees an atom it looks up the ascii code for it
23:50:58 <ehird`_> otherwise it uses the code
23:51:01 <ehird`_> so
23:51:04 <oklopol> oh, no
23:51:14 <ehird`_> String [H e l l o 44 32 W o r l d]
23:51:15 <ehird`_> or whatever
23:52:57 <oklopol> i'll just make "..." be syntactic sugar for #string:[...], where ... have been replaced by their ascii values
23:53:13 <oklopol> althoug... i now realize that's a bad way to do type, and already came up with a good way
23:53:17 <oklopol> *although
23:53:23 <oklopol> *Types
23:53:25 <oklopol> *types
23:54:27 <oklopol> later, the nodes can actually have values; values are different from tags, in that two nodes can share a value, and a value can be changed
23:54:57 <oklopol> so... the that'll make typing trivial without being explicit
23:55:02 <oklopol> *-the
23:55:32 <oklopol> oh, right, the n-dimensional hypercube
23:55:35 * oklopol gets on it
←2007-12-29 2007-12-30 2007-12-31→ ↑2007 ↑all