←2008-03-28 2008-03-29 2008-03-30→ ↑2008 ↑all
00:02:04 -!- RedDak has quit (Remote closed the connection).
00:19:50 <ehird> marshmallows: how short is your prolog again?
00:20:20 <marshmallows> the core is about 300 lines but I'm adding lots of primitives now
00:20:30 <ehird> marshmallows: does it use amb
00:20:31 <marshmallows> this is in Scheme
00:20:34 <ehird> cool
00:20:36 <marshmallows> no, just streasm
00:20:39 <ehird> i'm working on an embedding in scheme now
00:20:39 <ehird> :D
00:20:45 <ehird> (~ (cons X Y (X . Y)))
00:20:50 <olsner> marshmallows: eh, so it's *growing* now? that can't be right! :P
00:21:04 <marshmallows> heheh, olsner I'm not that good yet
00:21:29 <marshmallows> ehirid: Have you seen Reasoned Schemer by the way?
00:21:33 <marshmallows> >_<
00:21:35 <marshmallows> Ehird*
00:22:05 <ehird> nope
00:22:09 <ehird> read little schemer though
00:24:00 <marshmallows> syntax-rules is so great
00:24:54 <ehird> (define (all? f l) (cond ((null? l) #t) ((f (car l)) (all? f (cdr l))) (else #f)))
00:24:58 <ehird> marshmallows: what srfi is that ^^?
00:25:12 <marshmallows> all? is renamed every in SRFI-1
00:26:26 -!- bsmntbombdood has quit ("leaving").
00:26:32 <marshmallows> This is one of my utilites
00:26:33 <ehird> marshmallows: I wish strings were lists
00:26:33 <marshmallows> (define (cons/fail car cdr) (if cdr (cons car cdr) cdr))
00:26:36 <ehird> I have to do:
00:26:45 <ehird> (string->list (symbol->string var))
00:26:58 <ehird> (define (prolog-variable? x)
00:26:59 <ehird> (every (lambda (x) (char= x (char-upcase x)))
00:26:59 <ehird> (string->list (symbol->string x))))
00:27:32 <marshmallows> just (define (symbol->list symbol) (string->list (symbol->string var)))
00:27:33 <lament> marshmallows: why did you have to implement read?
00:27:35 <marshmallows> er
00:27:38 <marshmallows> just (define (symbol->list symbol) (string->list (symbol->string symbol)))
00:27:56 <ehird> marshmallows: oh, and after:
00:27:58 <ehird> (~ (human socrates))
00:27:59 <ehird> (~ (human john))
00:27:59 <ehird> (~ (mortal X) (human X))
00:28:01 <ehird> you can just do:
00:28:05 <marshmallows> you are using a case sensitive Scheme O_o
00:28:06 <ehird> (mortal 'socrates) => #t
00:28:16 <ehird> marshmallows: chicken's the name.
00:28:51 <marshmallows> atm I have lone symbols are variables and anything else is a 0 arity compound
00:29:08 <ehird> (mortal 'socrates) is (prolog-query '(mortal socrates))
00:30:31 <ehird> hmm
00:30:39 <ehird> (mortal 'socrates) => (), #t actually
00:30:42 <ehird> (multiple values)
00:30:52 <ehird> (mortal 'X) => (socrates john), #t
00:30:53 <ehird> or #f
00:30:54 <ehird> unsure
00:31:48 <marshmallows> I was planning on (later, making a new language), which has () and []
00:31:51 <ehird> marshmallows: ah, wait
00:32:01 <ehird> shouldn't (moratl 'X) => ((X . socrates)), #t
00:32:02 <ehird> OR
00:32:06 <ehird> ((X . john)), #t
00:32:15 <ehird> i.e. the multiple X thing is just an artifact of the repl
00:32:40 <marshmallows> one solution
00:32:42 <marshmallows> i
00:32:42 <marshmallows> s
00:33:11 <marshmallows> (mortal 'X) ;=> (((X . socrates)) . #<redo>)
00:33:27 <marshmallows> ((cdr)) gives you more solutions
00:33:28 <ehird> marshmallows: Isn't that just:
00:33:36 <ehird> (mortal 'X) (fail)
00:34:29 <marshmallows> don't think so
00:34:55 <ehird> marshmallows: well, i still need a truth value, surely
00:34:57 <ehird> so:
00:35:07 <ehird> ((X . socrates)), #t, #<procedure redo>
00:36:11 <marshmallows> what would
00:36:20 <ehird> marshmallows: well, the repl
00:36:22 <marshmallows> (human ehird)
00:36:24 <marshmallows> give?
00:36:24 <ehird> it says 'yes' or 'no'
00:36:37 <ehird> ?- human(ehird).
00:36:37 <ehird> No
00:36:40 <ehird> thank you, swi prolog.
00:36:44 <ehird> it would probably give:
00:36:44 <marshmallows> in your thing lol
00:36:48 <ehird> (), #f, #f
00:36:53 <ehird> what in yours?
00:37:09 <marshmallows> ?- (human ehird)
00:37:10 <marshmallows> no
00:37:36 <marshmallows> in mine also
00:37:39 <marshmallows> ?- 0
00:37:39 <marshmallows> no
00:37:41 <marshmallows> ?- 1
00:37:44 <marshmallows> yes ; no
00:37:46 <marshmallows> ?- 2
00:37:50 <marshmallows> yes ; yes ; no
00:37:55 <marshmallows> n succeeds n times
00:38:37 <ehird> marshmallows: I meant in your return desuture
00:39:04 <marshmallows> empty-stream = '()
00:39:14 <marshmallows> and failure = empty-stream
00:39:44 <ehird> (human 'ehird) ;=> ?
00:40:01 <marshmallows> A success is (stream-cons '() empty-stream), I don't actually have any useful values though anymore.. since variable bindings are in mutable vectors (much more efficient than term copying I had before)
00:40:07 <ehird> (human 'ehird) ;=> ?
00:40:28 <ehird> also: for scheme i value elegance over practicality & speed ;)
00:40:40 <marshmallows> (prove (make-declarationbase) (human (ehird))) ;=> empty-stream
00:40:58 <marshmallows> yeah it's much more elegant than my previous too :P
00:41:09 <marshmallows> since I was doing huge amounts of ridiculous computation
00:41:26 <ehird> (human 'ehird) ;=> ?
00:41:30 <ehird> if (mortal 'X) ;=> (((X . socrates)) . #<redo>),
00:41:35 <ehird> then (human 'ehird) ;=> ?
00:42:13 <marshmallows> (mortal 'X) ;=> (((X . socrates)) . #<redo>)
00:42:27 <marshmallows> (#<redo>) ;=> (((X . john)) . #<redo>),
00:42:31 <marshmallows> (#<redo>) ;=> '()
00:42:44 <ehird> (human 'ehird) ;=> ?
00:42:44 <marshmallows> that's how I did it before
00:42:48 <marshmallows> '()
00:42:49 <lament> heh, somebody was recently asking in scheme about some algorithm he had, where everything was ugly and optimized
00:42:59 <marshmallows> empty-stream = '() = failure
00:43:05 <ehird> marshmallows: sounds like CL
00:43:06 <ehird> :p
00:43:09 <ehird> lament: haha
00:43:14 <marshmallows> (null? '())
00:43:24 <ehird> lament: i can't wait for scheme with loads of !x and #a#
00:43:27 <ehird> and ByteString
00:43:30 <ehird> and unsafe io
00:43:32 <lament> ehird: consider, though: r5rs is really small. It pretty much doesn't have anything. And yet, it has vectors (efficiency)
00:43:40 <marshmallows> (cdr '(x)) ;=> '()
00:43:47 <marshmallows> not really CL..
00:43:55 <ehird> Scheme: Now just like Haskell, but with a pretty lame type system! It's about 30% fast, too.
00:44:00 <ehird> marshmallows: :-)
00:44:23 <ehird> marshmallows: You know, though (cdr '()) is obviously nonsense, it occurs to me that (rest '()) and (tail '()) are '()
00:44:24 -!- Deformative has quit (Read error: 110 (Connection timed out)).
00:44:37 <marshmallows> (I am always worrying about that though because I've done much more CL than Scheme)
00:44:41 <ehird> So the operations on conses and lists are different, even the most fundamental ones.
00:44:57 <ehird> lament: Well, vectors have a conceptual elegance to them.
00:45:06 <ehird> Observe that you can't have conses without vectors of length 2.
00:45:14 <ehird> So really the vectors are *above* the lists.
00:45:23 <marshmallows> (define (make-variable) (unbind! (make-vector 1)))
00:45:24 <marshmallows> (define (unbind! variable) (vector-set! variable 0 variable) variable)
00:45:28 <marshmallows> I think this is great :P
00:45:30 <lament> i think vectors are horrendously ugly, at least if you actually use them.
00:45:35 <marshmallows> void *x; x = &x;
00:45:55 -!- GreaseMonkey has joined.
00:45:56 <ehird> marshmallows: Make the failure stream #f
00:46:03 <ehird> lament: The interface leaves much to be desired, I agree.
00:46:06 <marshmallows> you can bind variables into equivalence classes.. unbind on backtracking, deref etc
00:46:16 <marshmallows> ehird: That makes absolutely no sense :P
00:46:19 <ehird> marshmallows: Since your thing is a cons, not a list
00:46:21 <ehird> (X . redo)
00:46:26 <marshmallows> (a b c . #f)
00:46:35 <ehird> Well, you don't haev that.
00:46:39 <ehird> You have (list . func)
00:47:05 <marshmallows> (a b c d) = (a . (b . (c . (d . ()))))
00:47:23 <ehird> marshmallows:
00:47:23 <ehird> [23:42] <marshmallows> (mortal 'X) ;=> (((X . socrates)) . #<redo>)
00:47:23 <ehird> [23:42] <marshmallows> (#<redo>) ;=> (((X . john)) . #<redo>),
00:47:23 <ehird> [23:42] <marshmallows> (#<redo>) ;=> '()
00:47:26 <ehird> I see a cons there
00:47:26 <ehird> not a list
00:47:36 <ehird> Oh, and look at my cute type declaration syntax:
00:47:39 <ehird> ;; prolog-query : form -> (env <prolog-query>) or #f
00:47:48 <ehird> a b c -> d == function
00:47:57 <ehird> a or b == self-explaining
00:48:01 <ehird> x : y == x is of type y
00:48:07 <ehird> <x> = the type of x
00:48:18 <ehird> So amusingly, I have type recursion with a base case.
00:49:15 <ehird> marshmallows: What's the function for 'Nth char in string'?
00:49:17 <marshmallows> (a . (lambda () (b (lambda () (c (lambda () (d . ()))))))) = (stream a b c d)
00:49:30 <marshmallows> in Scheme or Prolog?
00:49:37 <ehird> marshmallows: and aha, but what you haev there is:
00:49:39 <marshmallows> string-ref or nth/elt
00:49:40 <ehird> (a lambda () ...)
00:49:45 <ehird> face it, you don't have a list
00:49:49 <ehird> #f shoudl be your termination
00:49:50 <marshmallows> It's a list
00:49:57 <marshmallows> no it's not a list
00:50:04 <ehird> exactly!
00:50:06 <marshmallows> it's a stream
00:50:09 <ehird> exactly
00:50:11 <marshmallows> Look:
00:50:12 <ehird> and () is the empty LIST
00:50:15 <ehird> not the empty STREAM
00:50:46 <marshmallows> <list(a)> ::= (a . <list(a)>) | ()
00:50:54 <marshmallows> <stream(a)> ::= (a . <stream(a)>) | ()
00:51:05 <marshmallows> <stream(a)> ::= (a . <stream(a)>) | #f -- this makes no sense!
00:52:11 <marshmallows> anyway I don't even use streams
00:52:29 <marshmallows> I built cuttable streams so I can implement !/0
00:53:08 <ehird> ;; prolog : form . form -> unspecified
00:53:08 <ehird> (define (prolog form . conds))
00:53:22 <ehird> my awesome type info extends to varargs!
00:55:40 <marshmallows> reading files with R5RS is nice
00:55:53 <ehird> marshmallows: not reading a whole file
00:56:16 <ehird> (define (slurp-file fn) (call-with-input-file fn read-file))
00:56:29 <marshmallows> check it out http://rafb.net/p/KBesvn31.txt
00:56:38 <marshmallows> reads a s-exp prolog file
00:56:41 <ehird> (define (read-file f) (let ((c (read-char f))) (if (eof-object? c) '() (cons c (read-file f)))))
00:56:51 <ehird> (define (read-whole-file f) (list->string (read-file f))
00:56:56 <ehird> (define (slurp-file fn) (call-with-input-file fn read-whole-file)) ;; fixed
00:57:08 <marshmallows> oh I wrote a R5RS reader the other day
00:57:37 <marshmallows> so you just pass in a dispatch table with options
00:58:04 <marshmallows> that way it takes 3 lines to define the syntax of my other language (changing quoting a bit and adding new parens)
00:58:26 <ehird> marshmallows: is storing continuations in a global enough for backtracking?
00:58:27 <ehird> i think yes
00:58:41 <marshmallows> should be yeah, a stack of them
00:58:50 <ehird> ;; backtracks : (continuation)
00:58:50 <ehird> OR
00:58:54 <ehird> ;; backtracks : list of continuation
00:58:58 <ehird> the latter looks nicer, really
00:59:05 <marshmallows> perhaps you can make a single continuation if you join them in a clever way hm
00:59:11 <ehird> marshmallows: oo, i just realised something
00:59:13 <marshmallows> dunno how to do cut with that though
00:59:19 <ehird> i could write a type-checker for these type decls
00:59:23 <ehird> because they're very mechanical
00:59:26 <ehird> and the syntax is simple yet readable
00:59:33 <marshmallows> hehehe
00:59:33 <ehird> ;; prolog-query : form -> (env <prolog-query>) or #f <-- really easy to test
00:59:45 <ehird> it would just hook in after the macro expansion process
00:59:52 <ehird> and would interact fine with dynamic functions
01:00:09 <ehird> if it had a few built in things like:
01:00:10 <ehird> ;; car : list of 'a -> 'a
01:00:13 <marshmallows> you should write the type checker in (or parts) in Prolog
01:00:15 <ehird> ;; cdr : list of 'a -> list of 'a
01:00:26 <ehird> ;; cons : 'a, list of 'a -> list of 'a
01:00:58 <ehird> ;; map : ('a -> 'b), list of 'a -> list of 'a
01:01:01 <ehird> it's just like ML
01:01:01 <ehird> :p
01:01:28 -!- Corun has quit ("This computer has gone to sleep").
01:01:46 <ehird> marshmallows: I can pop backtracks straight after using them, right?
01:01:51 <ehird> Since if needed the continuation will push a new one
01:02:17 <ehird> hahaha:
01:02:18 <ehird> ;; call-backtrack : ->
01:02:24 <ehird> where no type after the -> means 'doesn't return'
01:02:42 <ehird> marshmallows: Backtracks don't need arguments, do they?
01:04:55 <ehird> marshmallows: hmm. 'add-backtrack-here!' is a sucky name
01:05:08 <ehird> (define (add-backtrack-here!) (call/cc (lambda (k) (add-backtrack k))))
01:05:37 <marshmallows> choice!
01:05:42 <ehird> marshmallows: naw
01:06:04 <marshmallows> maybe you could do something giving backtracking args
01:06:33 <marshmallows> thing is it's like.. "If you had gone down that path you could have seen <x>"
01:06:43 <ehird> marshmallows: hmm, SHOULD i end it with ! ?
01:06:45 <marshmallows> but it's only for the paths before not all
01:06:51 <ehird> internally they do mutate a global list of backtrack points
01:06:56 <ehird> but it's declarative as far as the user can tell
01:07:46 <marshmallows> I don't know
01:07:50 <marshmallows> I would
01:08:13 <marshmallows> you can only pop it after using them up
01:08:20 <ehird> (define (amb . args)
01:08:20 <ehird> (call/cc
01:08:20 <ehird> (lambda (k)
01:08:20 <ehird> (cond ((null? args) (backtrack))
01:08:20 <ehird> (else (call/backtrack (lambda () (k (car args))))
01:08:20 <ehird> (apply amb (cdr args)))))))
01:08:26 <marshmallows> like a branch can have more than two choices
01:08:28 <ehird> would that really be nicer with scattered !s?
01:08:51 -!- Deformative has joined.
01:08:56 <marshmallows> :o
01:09:26 <marshmallows> if that works.. you should replace the one on http://rosettacode.org/wiki/Amb since that's *much* nicer
01:10:15 <ehird> marshmallows: only with my lib ;)
01:10:21 <ehird> i have one without a lib around here
01:10:27 <ehird> it's basically that, withh 1 or 2 support functions
01:10:34 <marshmallows> but
01:10:50 <marshmallows> I do not encourage the abbreviation of call-with-current-continuation
01:11:05 <ehird> marshmallows: tough. I use call/cc over the time and value my fingers.
01:11:13 <ehird> I'm not going to risk rsi for the sake of a goddamn stupid identifier
01:11:20 <ehird> PLT, Chicken, ... support it.
01:11:25 <ehird> If your impl doesn't, I don't care
01:11:26 <marshmallows> I always type it out in full :P
01:11:43 <marshmallows> (undefine call/cc call-with-current-continuation)
01:11:45 <marshmallows> lol
01:11:55 <marshmallows> rm
01:12:46 <ehird> marshmallows: But yeah, I would have to change (backtrack) to (backtrack!)
01:12:54 <ehird> and (call/backtrack ...) to (call/backtrack! ...)
01:13:10 <ehird> To me, that is not elegant. It just shows that the declarative layer was built on top of imperative primitives.
01:13:17 <ehird> And exposing implementation is not good.
01:13:32 <marshmallows> yeah good point
01:14:19 <marshmallows> hey
01:14:26 <marshmallows> how do you do bag-of with amb?
01:14:32 <ehird> marshmallows: dunno
01:14:33 <ehird> show me bag-of
01:14:43 <marshmallows> I saw the Scheme in Fixnum days one, it's pretty nastly
01:15:04 <ehird> marshmallows: Btw, I write an amb in Haskell explicitly: custom monad etc. I even made an AmbT monad transformer! http://www.haskell.org/haskellwiki/Amb
01:15:10 <ehird> Amb is the list monad, interestingly.
01:15:13 <ehird> And AmbT is NOT ListT.
01:15:21 <ehird> AmbT is ListT done right since ListT is broken
01:15:30 <marshmallows> (bag-of (let ((x (amb 1 2 3 4 5))) (if (odd? x) (amb) x))) ;=> '(2 4)
01:15:41 <ehird> marshmallows: It's even polymorphhic
01:15:46 <ehird> do a <- [1,2,3]; b <- ["hello","world"]
01:15:49 <ehird> works inside the same monad
01:15:50 <ehird> err
01:15:52 <ehird> add an amb there
01:16:12 <ehird> marshmallows: hm that would be hard
01:16:15 <ehird> you'd need to stop the call/cc
01:16:20 <ehird> dynamic-wind would be involved.
01:17:23 <marshmallows> cool!
01:17:27 <marshmallows> (AmbT)
01:17:47 <ehird> marshmallows: yeah
01:18:00 <ehird> marshmallows: that code even lets amb [] appear in any type context
01:18:14 <ehird> due to having a permanently uninstated type variable (r) and using that as a type for a function to do 'return undefined'
01:18:41 <ehird> (define (prolog form . conds)
01:18:41 <ehird> ...) ;; chicken scheme throws an *error* on this function, because it knows that ... can never be defined here. That is too damn clever, I love it.
01:20:54 <marshmallows> my code works on chicken :D
01:20:55 <ehird> marshmallows: for the backtrack continuations...
01:20:58 <ehird> (k #f) or (k (void))?
01:21:08 <ehird> I'm inclined to the former, because (void) should probably only be a return value.
01:21:19 <marshmallows> (k k)
01:21:27 <ehird> marshmallows: Chicken is great, it marries the UNIX scripting & batch compilation way with the Scheme/Lisp REPL way.
01:21:37 <ehird> It's also quite fast, and has excellent libraries and ffis
01:21:39 <lament> ehird: sounds like bash
01:21:43 <lament> :D
01:21:48 <ehird> also, the webserver it has is great
01:22:06 <ehird> lament: 'cept bash has no FFIs, barely any libraries, and is painful to code in :)
01:22:25 <marshmallows> ehird: Do you know how to make a really good REPL with it (for a sexp lang but not Scheme)
01:22:41 <ehird> marshmallows: Like readline and stuff?
01:22:47 <marshmallows> I guess
01:22:49 <marshmallows> I don't know
01:22:50 <ehird> Do you want commands at the REPL too?
01:22:51 <ehird> :p
01:22:58 <ehird> You could just expose special functions of course
01:23:41 <ehird> the example here: http://www.call-with-current-continuation.org/eggs/amb.html worked unmodified
01:23:45 <ehird> #;4> (solve-kalotan-puzzle)
01:23:45 <ehird> (f m f)
01:23:54 <ehird> amb-colelct is bag-of thouhgg
01:23:57 <marshmallows> actually I have this problem I need to solve in my code first but I can't figure how to do it in an elegant (e.g. not totally ugly) way
01:24:23 <marshmallows> or I could use an object system to write a single procedure :|
01:25:48 <marshmallows> hm
01:25:50 <ehird> marshmallows: (~ ...) is my defining
01:25:55 <ehird> (? ...) querying
01:25:56 <ehird> and hmm
01:25:58 <ehird> don't use an object system
01:26:00 <marshmallows> I use FACT and TO-DERIVE
01:26:02 <ehird> Chicken has really nice ones
01:26:03 <ehird> but still :)
01:26:07 <ehird> marshmallows: ah, but mine are macros
01:26:17 <ehird> (~ (a b) c d) -> (prolog '(a b) 'c 'd)
01:26:24 <ehird> (? (a b)) -> (prolog-query '(a b))
01:26:42 <marshmallows> you might wanna make the macro fold the body
01:26:54 <marshmallows> (~ (a b) c d) ~> (prolog '(a b) (and c d))
01:27:05 <ehird> marshmallows: No.. it uses its internal evaluation engine
01:27:11 <marshmallows> syntax-rules does that very naturally
01:27:19 <ehird> (~ (mortal X) (human X))
01:27:23 <ehird> that wouldn't work with yours
01:27:43 <marshmallows> you need 3 cases
01:27:56 <marshmallows> zero, one, one+
01:29:06 <ehird> marshmallows: what does (human 'ehird) result in yours?
01:29:20 <ehird> marshmallows: also, i only need one case
01:29:22 <marshmallows> no
01:29:24 <ehird> which does fold over the body
01:29:26 <ehird> but prolog body
01:29:32 <ehird> marshmallows: what is 'no' in scheme
01:29:39 <ehird> I mean actually (human 'ehird)
01:29:48 <marshmallows> (display "no")
01:29:53 <ehird> (mortal 'X) ;=> (((X . socrates)) . #<redo>)
01:29:56 <ehird> (human 'X) ;=> ?
01:29:59 <marshmallows> I don't think I get what you are asking....
01:30:06 <ehird> marshmallows: You quoted that mortal example before.
01:30:12 <ehird> The human one is supposedly similar.
01:30:14 <ehird> What about:
01:30:16 <ehird> (human 'ehird)
01:30:52 <marshmallows> ok #f
01:30:52 <marshmallows> :P
01:30:57 <marshmallows> you want me to say that right?
01:31:02 <ehird> marshmallows: No. Just wondering
01:31:07 <ehird> It's a simple question, wtf is hard about it
01:31:53 <marshmallows> (prove (make-declarationbase) ((make-term-converter) '(human 'ehird)) ;=> ()
01:31:55 -!- timotiis has quit ("leaving").
01:32:10 <ehird> ok, what if human(ehird).
01:32:54 <marshmallows> % ./prolog2
01:32:54 <marshmallows> ?- (human (ehird))
01:32:54 <marshmallows> no
01:33:18 <marshmallows> oh
01:33:21 <marshmallows> If I add that rule
01:33:53 <ehird> yea
01:34:45 <ehird> marshmallows: also, mine will support definition at the prompt
01:35:00 <marshmallows> echo "(fact (human (ehird)))" >> test.spl
01:35:02 <marshmallows> > (prove (consult "test.spl") ((make-term-converter) '(human (ehird))))
01:35:02 <marshmallows> ((() . #f) . #<procedure>)
01:35:13 <ehird> (() . #f)?! WTF
01:35:41 <marshmallows> http://rafb.net/p/7AKTK053.txt
01:36:06 <marshmallows> do you want my entire code to look at ? (353 lines)
01:36:30 * marshmallows is sort of also hoping suggestions to improve
01:36:59 <ehird> marshmallows: don't you bind () to #f in that thing?
01:37:07 <ehird> if so, doesn't that make no damn sense whatsoever
01:38:08 <marshmallows> in my previous one I returned a stream of substitutions
01:38:17 <ehird> marshmallows: my cut is very easy
01:38:20 <ehird> (set! backtracks '())
01:40:59 <marshmallows> so calling the cdr computed the next substitution.. now though, I have variables as mutable vectors (instead of term copying), so I don't return any substitution, but backtracking unbinds variables now
01:41:20 <ehird> marshmallows: is variables as mutable vectors better?
01:41:22 <ehird> it seems less elegant
01:41:25 <marshmallows> I could have (#f . #<procedure>) infact.. the () is reduntand
01:41:30 <marshmallows> It's more elegant and efficient
01:42:10 <ehird> what is #f
01:42:34 <marshmallows> it means a cut was not applied in proving this goal
01:42:58 <ehird> marshmallows: don't you use continuations?
01:43:05 <marshmallows> cuttable-stream-append-tail chops of choice points if it sees that
01:43:22 <marshmallows> I don't use call-with-current-continuation just streams to delay computation
01:45:00 <marshmallows> one thing is with term-copying you can use EQUAL?
01:45:05 <ehird> marshmallows: Doesn't cut just remove all the backtrack continuations?
01:45:25 <marshmallows> but with mutable variables you need to write a TERMS-EQUAL?
01:46:00 <marshmallows> cut just says, "The previous choice was the right one"
01:46:14 <marshmallows> so you can still have choices above and below it
01:47:12 <marshmallows> did that make sense? :S
01:47:25 <ehird> uhh
01:47:33 <ehird> cut just means 'no backtracking before me, beyond this point'
01:47:38 <ehird> so:
01:47:43 <ehird> (define (cut) (set! backtracks '())
01:48:37 <ehird> marshmallows: right?
01:49:32 <marshmallows> not exactly
01:49:41 <marshmallows> for example,
01:49:41 <marshmallows> foo(X) :- !, member(X, [a,b,c,d]).
01:49:42 <marshmallows> foo(bar).
01:49:53 <marshmallows> so now if you did this query:
01:49:54 <marshmallows> ?- member(A, [1,2]), foo(X).
01:50:04 <ehird> marshmallows: when using amb cut is (set! backtracks '())
01:50:08 <ehird> is it different for full prolog
01:50:28 <marshmallows> um if you aren't implement Prolog then you can choose any semantics you like
01:50:32 <marshmallows> but that's not cut
01:50:59 <ehird> marshmallows: it's amb's cut
01:51:01 <ehird> no?
01:51:18 <marshmallows> because you could A = 1, X = a; A = 1, X = b; A = 1, X = c; A = 1, X = d; A = 2, X = a; A = 2, X = b; ...
01:51:50 <marshmallows> the cut just says the choice between foo(X) and foo(bar) was the right one.. but in that query you can still backtrack
01:53:03 <ehird> marshmallows: so do i need to handle cut in the other parts?
01:53:05 <ehird> or can it be standalone
01:53:08 <ehird> and the other parts not know about it
01:54:07 <ehird> marshmallows: ?
01:54:13 <marshmallows> ASCII ART
01:54:20 <marshmallows> http://rafb.net/p/7NyUa343.txt
01:54:25 <marshmallows> does that help?
01:55:17 <ehird> no
01:55:21 <ehird> my question was simple, an implementation one
01:55:22 <marshmallows> :(
01:55:27 <ehird> if i implement cut do i have to design the rest of my system
01:55:29 <ehird> to accomodate for it?
01:55:36 <ehird> or can i add it later with no pain
01:55:46 <marshmallows> I added it later with no paint
01:55:48 <marshmallows> I added it later with no pain*
01:56:14 <marshmallows> Just replaced streams with cuttable streams
01:56:31 <marshmallows> Actually
01:56:45 <marshmallows> How does dynamic scope interact with calling a continuation?
01:57:05 <marshmallows> because you might be able to just have a box with #t or #f in it denoting whether or not a cut occured
01:58:16 <ehird> marshmallows: what has dynamic scope got to do with it?
01:58:20 <ehird> in prolog, everything is pretty much global
01:58:24 <ehird> or lexical.
01:58:51 <marshmallows> It's very interesting how Prolog handles binding actually
02:00:07 <ehird> marshmallows: ?
02:01:23 <marshmallows> Prolog is implicit ∃, rather than λ
02:01:44 <Slereah> Is there a tarpit based on logical languages?
02:01:54 <Slereah> Like using the Schönfinkel stroke.
02:02:07 <Slereah> Or something.
02:02:52 <marshmallows> what is the Schönfinkel stroke?
02:03:49 <ehird> marshmallows: what is []
02:03:50 <ehird> p
02:03:52 <ehird> :p
02:03:53 <Slereah> In PN, |x ab = for allx (a | b)
02:04:08 <marshmallows> in Prolog [] is empty list
02:04:25 <Slereah> You can define all predicate logic with it, so it is said.
02:05:16 <ehird> marshmallows: prolog is implicit []
02:05:18 <ehird> i.e. what is that char
02:05:31 <marshmallows> oh
02:05:36 <marshmallows> Backwards E
02:08:17 -!- ehird has quit ("Konversation terminated!").
02:26:09 -!- sebbu has quit (Read error: 60 (Operation timed out)).
03:16:40 -!- Slereah has quit (Read error: 104 (Connection reset by peer)).
03:18:55 -!- slereah_ has joined.
03:23:14 -!- slereah_ has changed nick to Slereah.
03:39:34 -!- Slereah has quit ("Konversation terminated!").
03:42:06 -!- Slereah has joined.
03:54:40 -!- Slereah has quit (Read error: 104 (Connection reset by peer)).
04:36:46 -!- RodgerTheGreat has quit.
04:54:04 -!- Slereah has joined.
06:18:22 -!- slereah_ has joined.
06:21:43 -!- Slereah has quit (Read error: 104 (Connection reset by peer)).
06:23:35 -!- GreaseMonkey has quit ("Read error: 110 (Connection chickened out)").
06:51:46 -!- slereah_ has quit (Read error: 110 (Connection timed out)).
07:59:59 -!- clog has quit (ended).
08:00:00 -!- clog has joined.
08:08:32 -!- Judofyr has quit (Remote closed the connection).
08:09:12 -!- Judofyr has joined.
08:17:13 -!- sebbu has joined.
09:32:19 -!- okopol has joined.
09:53:05 -!- okopol has quit (No route to host).
10:00:13 -!- Judofyr_ has joined.
10:00:13 -!- Judofyr has quit (Read error: 104 (Connection reset by peer)).
10:19:04 -!- okopol has joined.
10:38:34 -!- bsmntbombdood_ has quit (Read error: 113 (No route to host)).
10:38:58 -!- slereah_ has joined.
10:41:59 -!- slereah_ has quit (Read error: 104 (Connection reset by peer)).
10:42:51 -!- slereah_ has joined.
10:49:16 -!- slereah__ has joined.
10:50:37 -!- slereah_ has quit (Read error: 104 (Connection reset by peer)).
10:53:25 <AnMaster> Deewiant,
10:53:32 <AnMaster> GOOD: 3DDD is zero doesn't have a matching BAD
10:53:37 <AnMaster> you just get an empty line then
10:54:11 <Deewiant> looks like a misalignment on line 340
10:55:03 <Deewiant> there's a ;>:#,_ on the right end of that line, move the ;> one space to the left so it ends up as ;> :#,_
10:55:08 <Deewiant> that should do it
10:56:25 -!- marshmallows has quit ("Leaving").
10:57:47 <AnMaster> k
10:57:57 <AnMaster> Deewiant, can't test as I fixed my D now
10:57:57 <AnMaster> heh
10:59:31 <GregorR> It was a P, had to stretch and re-block the curve.
11:00:37 <AnMaster> hah
11:00:57 <AnMaster> Deewiant, btw just looked at ccbi for F in TOYS
11:01:00 <AnMaster> for (auto y = ty; y < ty + j; ++y)
11:01:02 <AnMaster> err?
11:01:15 <AnMaster> what is it trying to do exactly hm?
11:02:05 <Deewiant> looks like it's looping from ty to ty + j
11:02:08 <Deewiant> :-P
11:02:20 <AnMaster> ok that auto confuse me
11:02:25 <AnMaster> Deewiant, what does auto does in D?
11:02:26 <Deewiant> type inference
11:02:30 <AnMaster> ah
11:04:26 <AnMaster> BAD: G doesn't work
11:04:30 <AnMaster> in what way I wonder
11:20:54 <AnMaster> áa=BAD: V doesn't move correctly
11:20:54 <AnMaster> áa=GOOD: overlapping copy with C works
11:20:58 <AnMaster> Deewiant, that werid
11:21:00 <AnMaster> weird*
11:21:07 <AnMaster> yes I know why it doesn't work
11:21:16 <AnMaster> because I haven't writte the code for those two yet
11:21:20 <AnMaster> but the odd chars
11:26:27 <AnMaster> case 2: space[ip.x, ip.y] = '^'; goSouth(); break;
11:26:27 <AnMaster> case 3: space[ip.x, ip.y] = 'v'; goNorth(); break;
11:26:30 <AnMaster> Deewiant, that is from ccbi
11:26:42 <AnMaster> shouldn't those ^ and v be the other way around?
11:27:26 <Deewiant> probably, yes :-)
11:27:38 <AnMaster> from U in TOYS
11:36:19 <AnMaster> Deewiant, any idea what cause those áa= btw?
11:36:47 <Deewiant> nope
11:36:50 <AnMaster> BAD: 01T goes up <-- hm?
11:37:17 <Deewiant> 1T is supposed to be |
11:37:49 <AnMaster> yes it is indeed
11:37:56 <AnMaster> so up or down seem correct?
11:38:16 <AnMaster> point is, I made it just call the function used for normal |
11:38:19 <AnMaster> and normal | works
11:38:21 <Deewiant> and what is 0| supposed to do
11:38:30 <Deewiant> it's supposed to go down
11:38:33 <Deewiant> so 01T should go down
11:38:35 <AnMaster> 0| goes down, I tested it
11:38:41 <AnMaster> so why would 01T go up
11:38:47 <Deewiant> it's your code, I don't know
11:38:57 <AnMaster> sound like a bug elsewhere as the same code is used in both cases
11:40:22 <AnMaster> Deewiant, wait a sec
11:40:24 <AnMaster> BAD: 01T goes up
11:40:28 <AnMaster> I set a breakpoint on T
11:40:32 <AnMaster> it didn't hit
11:40:36 <AnMaster> so T is not even called there
11:40:37 <AnMaster> wtf
11:47:34 <AnMaster> Deewiant, when I fixed K that I had before not yet implemented, T suddenly starts to work
11:47:42 <AnMaster> Deewiant, so looks like a mycology bug?
11:48:16 <Deewiant> doesn't make sense to me
11:48:22 <Deewiant> looking at the code for testing T
11:50:11 <AnMaster> Deewiant, where is it? hm?
11:50:17 <Deewiant> end of line 422
11:50:32 <AnMaster> oh that is a HUGE area for TOYS then
11:50:58 <Deewiant> yup, TOYS is over 100 lines of testing
11:51:09 <AnMaster> Deewiant, btw, implementing V removed the odd char in front of M, but not the odd char in front of V itself
11:51:24 <Deewiant> yeah, there's probably a missing 'n' somewhere which means there's some crap on the stack
11:52:13 <AnMaster> implementing M fixed char in front of V btw
11:52:14 <AnMaster> heh
11:52:40 <AnMaster> I guess mycology didn't like that I did the simple ones first, instead of "in order of testing"
11:52:55 <Deewiant> shrug
11:52:56 <AnMaster> BAD: L gets right-hand
11:52:56 <AnMaster> BAD: R gets left-hand
11:52:59 <AnMaster> and those are wrong
11:53:04 <AnMaster> currently they do nothing
11:53:10 <AnMaster> heh
11:54:04 <Deewiant> hm
11:54:27 <Deewiant> that should be "L doesn't work at all" then
11:55:26 <Deewiant> AnMaster: can you replace line 416, col 25, 'A', with 'n'
11:55:51 <AnMaster> Deewiant, hm a sec
11:56:34 <AnMaster> Deewiant, no change
11:59:02 <Deewiant> AnMaster: do you have mercurial installed?
11:59:24 <AnMaster> Deewiant, yes I got most distributed version control systems apart from darcs
11:59:27 <AnMaster> and git
11:59:29 * AnMaster hates git
11:59:42 <Deewiant> AnMaster: pull mycology from http://tar.us.to:8000/
11:59:52 <AnMaster> Deewiant, however, I would need some help if you want me to use mercurial, it was like half a year ago I used it
12:00:03 <AnMaster> my memory is kind of rusty there
12:00:15 <Deewiant> one sec
12:00:28 <AnMaster> hg somecommand I guess?
12:02:25 <Deewiant> AnMaster: hg clone http://tar.us.to:8000/
12:02:29 <Deewiant> I hope
12:02:44 <AnMaster> destination directory: tar.us.to:8000
12:02:46 * AnMaster waits
12:02:58 <AnMaster> Deewiant, seems like nothing happens?
12:02:58 <Deewiant> er
12:03:57 <AnMaster> PORT STATE SERVICE
12:03:57 <AnMaster> 8000/tcp filtered http-alt
12:04:00 <AnMaster> is what nmap says
12:04:05 <AnMaster> so that won't work indeed
12:04:08 <Deewiant> yeah, I killed it now
12:04:16 <AnMaster> Deewiant, why?
12:04:18 <Deewiant> I think the hostname doesn't work, I only just updated DNS :-)
12:04:29 <AnMaster> 88.114.235.101
12:04:33 <AnMaster> is what it resolves to here
12:04:35 <Deewiant> 88.114.224.242
12:04:37 <Deewiant> is what you want
12:04:51 <AnMaster> hm, dns update time ETA?
12:05:06 * AnMaster do not want to run rndc flush because that slows down everything else
12:05:30 <AnMaster> destination directory: 88.114.224.242:8000
12:05:31 <AnMaster> ok
12:05:39 <Deewiant> seems to have worked now
12:05:54 <AnMaster> ok what now?
12:06:04 <Deewiant> now you should have a new mycology there, see if that works
12:06:08 <AnMaster> BAD: L doesn't work at all
12:06:08 <AnMaster> BAD: R gets left-hand
12:06:09 <AnMaster> indeed
12:06:10 <Deewiant> yay
12:06:18 -!- Corun has joined.
12:06:45 <AnMaster> GOOD:GOOD: 000p000W goes seog W000p000 :DOOG 000p000W goes through
12:06:45 <AnMaster> °¥@BAD: 00p100W goes through
12:06:45 <AnMaster> ³?@BAD 000p01-00W goes through
12:06:45 <AnMaster> ³@GOOD: X works
12:06:54 <Deewiant> :-P
12:06:55 <AnMaster> somehow, I don't think that count as GOOD?
12:07:06 <Deewiant> no, I don't think so :-)
12:07:10 <AnMaster> but that got more GOOD than BAD in it ;P
12:07:57 <Deewiant> AnMaster: pull again, "hg pull" should be enough
12:08:06 <Deewiant> just to see if it works for R now as well
12:08:16 <AnMaster> (run 'hg update' to get a working copy)
12:08:23 <Deewiant> that too
12:08:27 <AnMaster> now that is a reason why I selected bzr :)
12:08:42 <AnMaster> BAD: R gets left-hand
12:08:44 <AnMaster> Deewiant, still that
12:09:18 <AnMaster> (wouldn't it be easier just to comment out the relevant line in ccbi for a moment and experiment with that btw?)
12:09:39 <Deewiant> nah :-P
12:10:03 <Deewiant> alright, one more time
12:11:27 <AnMaster> BAD: R doesn't work at all
12:11:29 <AnMaster> indeed
12:11:31 <Deewiant> yeh
12:11:37 <Deewiant> cheers
12:24:07 -!- okopol has quit (Read error: 113 (No route to host)).
12:59:48 <AnMaster> Deewiant,
12:59:50 <AnMaster> GOOD:GOOD: 000p000W goes seog W000p000 :DOOG 000p000W goes through
12:59:50 <AnMaster> °¥@BAD: 00p100W goes through
12:59:50 <AnMaster> ³?@BAD 000p01-00W goes through
12:59:50 <AnMaster> ³@GOOD: X works
12:59:58 <AnMaster> all but W is now complete on TOYS
13:00:03 <AnMaster> W does nothing atm
13:00:19 <AnMaster> so why such weird output
13:00:29 <AnMaster> doing nothing should be quite basic thing shouldn't it?
13:31:45 <Deewiant> shrug
13:32:14 -!- timotiis has joined.
13:33:57 <AnMaster> ok now TOYS are implemented fully
13:34:40 <Deewiant> AnMaster: and BTW, it says clearly in mycology's readme (I think) that if you see an unimpl instruction you should reflect
13:34:53 <AnMaster> hm
13:34:59 <Deewiant> and the behaviour is your fault if you don't
13:35:14 <AnMaster> Deewiant, however most tests does detect such cases
13:35:26 <AnMaster> the threading ones seems a bit more "brittle" though
13:35:33 <Deewiant> doesn't matter, because it's undefined
13:35:52 <Deewiant> the fact that some tests detect it is incidental
13:36:38 <AnMaster> ^D^C^B^AGOOD: : on empty stack makes stack size 2 according to y$
13:36:44 <AnMaster> hm cat -e is interesting
13:36:52 * AnMaster wonders why it print some control codes there
13:37:09 <Deewiant> bugs
13:37:43 <AnMaster> yeah but I wonder what the bug is and where
13:39:07 <AnMaster> Deewiant, btw I have an early draft for debugging protocol, your feedback would be valuable, I can put it up somewhere in one of these formats: lyx. latex, dvi or pdf
13:39:10 <AnMaster> you select
13:41:42 <AnMaster> Deewiant, http://rage.kuonet.org/~anmaster/tmp/frontend-prococol.pdf is the pdf version, it is just a draft
13:46:26 <AnMaster> GOOD: 000p000W goes thrugh
13:46:30 <AnMaster> that's not right hmmm
13:49:48 <AnMaster> Deewiant, request: add something like the trace mode that my interpreter got and make a binary, so I can compare and see where I go wrong :/
13:49:58 <AnMaster> I can't figure out some bugs
13:50:12 <AnMaster> :(
13:50:25 <AnMaster> please :)
13:55:57 -!- atsampso1 has joined.
13:56:49 -!- atsampson has quit (Read error: 104 (Connection reset by peer)).
14:13:13 <Deewiant> AnMaster: what's wrong with the debugger
14:18:39 -!- Judofyr_ has changed nick to Judofyr.
14:20:04 -!- Corun has quit ("This computer has gone to sleep").
14:21:32 -!- Judofyr has quit.
14:22:50 -!- lifthras1ir has joined.
14:22:50 -!- lifthras1ir has quit (Client Quit).
14:23:55 -!- lifthras1ir has joined.
14:24:29 -!- lifthras1ir has quit (Remote closed the connection).
14:24:29 -!- lifthrasiir has quit (Read error: 104 (Connection reset by peer)).
14:24:37 -!- lifthrasiir has joined.
14:25:06 <AnMaster> Deewiant, because I can't easily get a list of all instructions executed
14:25:23 <Deewiant> why do you need that
14:25:54 <AnMaster> Deewiant, I'm unable to track down a bug in my interpreter, so I think the best way would be to compare the instructions exected with one that does it right
14:26:01 <AnMaster> to see what went wrong where
14:26:10 <Deewiant> you probably know the coordinates where you want to compare
14:26:29 <Deewiant> so just use the debugger, set a break point there, and then go step by step and see what happens
14:27:15 <AnMaster> Deewiant, tried that, something goes wrong earlier I think and doesn't show up until later
14:27:50 <Deewiant> so set the breakpoint earlier :-P
14:29:16 -!- lifthrasiir has quit (Client Quit).
14:29:40 -!- lifthrasiir has joined.
14:30:01 -!- lifthrasiir has quit (Client Quit).
14:30:07 -!- lifthrasiir has joined.
14:59:42 <AnMaster> Deewiant, no I'm unable to find out the cause
15:02:13 <Deewiant> can't you follow what's on your stack and what's on CCBI's
15:02:24 <AnMaster> hm yeah
15:02:31 <Deewiant> and if/when they differ go back to see where the differing value(s) came from
15:02:53 <AnMaster> hrrm
15:03:04 <AnMaster> Deewiant, well did you look at http://rage.kuonet.org/~anmaster/tmp/frontend-prococol.pdf
15:03:16 * AnMaster ponders implementing it first to be able to find this bug
15:03:18 <Deewiant> yeah I looked it over quickly
15:03:26 <AnMaster> any comments on it?
15:03:42 <Deewiant> nothing particular
15:04:00 <AnMaster> anything ccbi will ever support if I do it and make a good debugger frontend?
15:04:04 <Deewiant> I didn't read it word for word so there might be omissions or something but the general idea looks fine
15:04:22 <AnMaster> ok
15:04:51 <Deewiant> does the interpreter ever send messages? or only respond to questions from the client?
15:09:23 <AnMaster> Deewiant, it does send trace messages
15:09:40 <AnMaster> oh and BRK for breakpoint hit and such
15:10:06 <AnMaster> Deewiant, the table at the end describes that
15:10:11 <AnMaster> appendix a
15:10:13 <Deewiant> ah, tracing
15:10:19 <Deewiant> is that always enabled?
15:10:31 <AnMaster> Deewiant, yes, do you have an objection to that?
15:10:36 <Deewiant> if it is, it should be disablable IMO
15:10:45 <AnMaster> ok
15:10:50 <AnMaster> but why?
15:10:54 <AnMaster> performance?
15:10:58 <Deewiant> because if you don't need it it's pointless
15:11:11 <AnMaster> hm ok
15:11:13 <Deewiant> you could be debugging over the net, right
15:11:28 <AnMaster> Deewiant, you could but I can't imagine why anyone would want to heh
15:11:31 <Deewiant> so sending a lot of lines like that over a slow connection can be annoying
15:11:40 <AnMaster> hm
15:11:49 <Deewiant> AnMaster: user runs a script on his machine, developer debugs remotely
15:12:01 <Deewiant> admittedly this /is/ Funge we're talking about, but you never know ;-)
15:12:07 <AnMaster> heh, well that user got to trust the developer, as you can set funge space cells
15:12:20 <Deewiant> well, of course
15:12:32 <AnMaster> so "drowssap/cte/" o
15:12:33 <AnMaster> ;P
15:12:47 <AnMaster> or i
15:13:08 <Deewiant> in general, in that situation, the user will do whatever they're asked anyway
15:13:15 <AnMaster> oh?
15:13:37 <Deewiant> well, because such users aren't necessarily very tech-savvy
15:13:58 <AnMaster> I don't think non-computer literate ppl would *use* funge
15:14:08 <Deewiant> which is why I said "admittedly" above :-P
15:14:11 <AnMaster> yeah
15:15:01 <Deewiant> okay, so... you've only got a windows debugger but you need to debug a funge script running on a *nix
15:15:04 <Deewiant> or vice versa
15:15:47 <AnMaster> Deewiant, hm ok a point
15:15:58 <AnMaster> most likely done over LAN though but I see your point
15:16:11 <AnMaster> something like a TRACEOPT enabled:b ?
15:16:16 <AnMaster> where b is a boolean
15:16:27 <Deewiant> or just TRACETOGGLE or something
15:16:31 <AnMaster> or maybe, as I indented other ways of tracing
15:16:33 <AnMaster> a bit mask
15:16:52 <AnMaster> for example just trace when new ips were created, but possible that is better as change notification
15:18:28 <AnMaster> Deewiant, should trace initially be on or off?
15:19:07 <Deewiant> no default, needs negotiation?
15:19:24 <Deewiant> so that the client can set its own default
15:19:59 <AnMaster> hm
15:20:07 <AnMaster> Deewiant, it is easy to set in pre-run state
15:20:13 <AnMaster> ie just before program starts running
15:21:22 <AnMaster> Deewiant, also it is unclear to me how some things should work, ie tracing of space
15:21:35 <AnMaster> or in k
15:21:48 <AnMaster> one trace each time k runs the instruction?
15:22:22 <Deewiant> hmm
15:22:34 <Deewiant> if it's kp or something it might change the instruction being run, so yes I guess
15:23:56 <AnMaster> Deewiant, also I got no idea what extra stuff TRDS would need, if you have any interest in seeing it supported I need info on that
15:24:22 <AnMaster> I did add a ip mode in the bitmask on trace for it after looking into CCBI's debugger
15:24:41 <Deewiant> for debugging it's a bit tricky
15:25:13 <Deewiant> just for tracing, it's easy since you can just send "space changed to <new funge-space data>" or "space changed by" and similarly for IPs moving around and being created/dying
15:25:14 <AnMaster> also should it be possible to change IP mode, ie, string mode and such from inside the debugger?
15:25:46 <Deewiant> for full functionality, sure, but I wonder if it's really necessary
15:25:46 <AnMaster> uhu?
15:25:59 <Deewiant> I mean, tracing anything is easy
15:26:09 <Deewiant> since the debugger doesn't have to know anything about semantics
15:26:12 <AnMaster> yes, and this one allows several breakpoints heh
15:26:43 <AnMaster> Deewiant, well depends, for example if you want the debugger to draw a "live" version of funge space as the programs execute it would have to
15:26:44 <Deewiant> the interpreter can just tell, when time jump happens, "funge-space changed to ...", "IP 0 moved to ...", "IP 1 is now in mode X", etc.
15:26:53 <Deewiant> AnMaster: no, it wouldn't
15:27:03 <Deewiant> AnMaster: since the interpreter only has to communicate the current funge-space
15:27:05 <AnMaster> that is one thing I wanted recently, when trying one of the <mad domain name> programs
15:27:08 <AnMaster> called a roller
15:27:09 <Deewiant> and the debugger can draw that
15:27:17 <AnMaster> hm
15:27:25 <Deewiant> it shouldn't be the way that interpreter says "executed p" and then debugger executes p locally
15:27:40 <AnMaster> true
15:27:41 <Deewiant> it should be that interpreter says "executed p; space[0, 0] is now a"
15:27:47 <AnMaster> Deewiant, so you want change notification
15:27:49 <AnMaster> see that section
15:27:50 <Deewiant> and then debugger can draw a at (0,0)
15:27:56 <AnMaster> EVCHGANYCELL
15:27:59 <AnMaster> is the one you want
15:28:01 <AnMaster> for that
15:28:30 <Deewiant> aye
15:28:47 <AnMaster> anyway what is needed for stack-stack
15:28:56 <AnMaster> I don't know there, the stack-stack section is just todo atm
15:29:12 <Deewiant> more events needed, though
15:29:20 <AnMaster> Deewiant, agreed
15:29:27 <Deewiant> and hmm
15:29:33 <Deewiant> how does this position stuff work
15:29:37 <Deewiant> in events
15:29:45 <AnMaster> you mean dimensions?
15:29:50 <Deewiant> "this is the position to monitor"
15:30:16 <AnMaster> Deewiant, yes? not sure I got your question?
15:30:29 <Deewiant> so what is that, exactly
15:30:33 <Deewiant> funge-space coordinates?
15:30:34 <Deewiant> for one point?
15:30:35 <Deewiant> for a range?
15:30:44 <AnMaster> hm see section 5.1
15:30:56 <AnMaster> but one cell yes
15:31:12 <Deewiant> okay
15:31:15 <AnMaster> but range may indeed be a good idea I guess
15:31:16 <Deewiant> so, something to consider
15:31:17 <Deewiant> ranges
15:31:20 <Deewiant> and also, unbounded ranges
15:31:27 <AnMaster> um?
15:31:30 <Deewiant> so you can say "anything with y-coordinate > 100"
15:31:37 <AnMaster> right I see
15:31:46 <Deewiant> because the funge-space can grow, so you don't have to send STOP, also check y-coordinate 101, CONTINUE
15:31:54 <Deewiant> and then again for y-coordinate 102, etc.
15:32:13 <AnMaster> well that is one issue with STOP, it may not stop exactly where you want
15:32:16 <AnMaster> for example, network lag
15:32:22 <Deewiant> yeap
15:32:23 <AnMaster> from the remote developer ;)
15:32:35 <Deewiant> well, even internally to the machine
15:32:39 <AnMaster> indeed
15:32:42 <Deewiant> the interpreter will probably go at least a few instructions forward
15:32:59 <Deewiant> also, btw: IP change events
15:33:00 <AnMaster> in even the best case at least one instruction forward the way I plan to implement it
15:33:08 <AnMaster> Deewiant, hm? as in?
15:33:17 <AnMaster> "ip split happened"?
15:33:19 <Deewiant> "IP 1 moved to (x,y)"
15:33:23 <Deewiant> "IP 2 created at (x,y)"
15:33:30 <Deewiant> (+ with mode foo)
15:33:31 <Deewiant> etc.
15:33:34 <AnMaster> moved well, that trace would show
15:33:43 <AnMaster> create and destroy yes
15:34:35 * AnMaster is copying this down into a text file
15:34:50 <Deewiant> :-)
15:36:07 <Deewiant> for stack stack: push stack, pop stack, at least
15:36:28 <AnMaster> it can do that
15:36:32 <AnMaster> oh wait
15:36:36 <AnMaster> push a stack you mean?
15:36:38 <AnMaster> right
15:36:39 <Deewiant> yes
15:37:09 <Deewiant> tracing or events for when stack is changed
15:37:13 <AnMaster> Deewiant, brb, phone sorry
15:37:22 <Deewiant> in general, I'm a bit leery about the tracing+events relationship
15:37:39 <Deewiant> tracing currently just looks like an event that always fires
15:37:56 <Deewiant> so maybe remove the whole tracing section and do the whole thing in terms of events
15:38:29 <Deewiant> there doesn't seem to be any way of getting info on the current stack state
15:39:18 <Deewiant> SSGET for getting a whole stack at once, maybe
15:39:35 <Deewiant> and an SSGETALL for getting the whole stack stack
15:41:49 <AnMaster> Deewiant, yeah it should probably be an event
15:42:15 <AnMaster> and I agree with the other two
15:42:21 <AnMaster> Deewiant, is there anything un-needed?
15:42:42 <AnMaster> because the protocol is starting to look more complex than needed :/
15:43:54 <Deewiant> well I'm not sure about all the "get info" stuff
15:44:09 <Deewiant> if tracing is always on, it's not needed
15:44:22 <Deewiant> but then, having full tracing is a bit bloaty
15:44:45 <AnMaster> yes I'm changing it into an even
15:44:47 <AnMaster> event'
15:44:48 <AnMaster> *
15:45:15 <Deewiant> what I mean is, the only cases where you would need IPINFO, for instance, are if you don't have IP tracing on
15:45:36 <Deewiant> because if you have tracing on, then the interpreter has already told you where the IPs are, what their deltas are, etc.
15:46:16 <Deewiant> but it's true that if you don't have it on, you do need it, and this way you can minimize network traffic: send a breakpoint, then request all info when stopped and get nothing in between.
15:46:41 <Deewiant> so strictly speaking I don't think there's anything major that's unnecessary
15:46:57 <Deewiant> similarly for FSPACEGET and FSPACEBOUNDS and FSPACEDUMP
15:47:21 <Deewiant> if you have the event notification for that on, you don't need it, otherwise you do and that way is more optimal in some cases.
15:47:42 <AnMaster> Deewiant, you do need it in one case always
15:47:45 <AnMaster> to get initial state
15:47:53 <AnMaster> and then turn on the notification
15:48:09 <Deewiant> you don't necessarily need the initial state
15:48:14 <AnMaster> hm?
15:48:22 <Deewiant> for instance, FSPACEDUMP
15:48:29 <AnMaster> yes?
15:48:43 <Deewiant> if you know that all you want to do is set a breakpoint at (x,y) and then see what's up, you don't need to download a dump of the whole space at the start
15:48:52 <AnMaster> true
15:49:07 <AnMaster> but why on earth would you want to trace writes to funge space then?
15:49:19 <Deewiant> well, this is a case where you wouldn't.
15:49:25 <AnMaster> indeed
15:49:28 <Deewiant> you'd set all events off
15:49:32 <Deewiant> set the breakpoint
15:49:39 <Deewiant> and then get no traffic until the interpreter's at the breakpoint.
15:50:40 <AnMaster> indeed
15:50:48 <AnMaster> Deewiant, well that made me think...
15:50:55 <Deewiant> but it's up to you whether you consider that use case relevant.
15:50:58 <AnMaster> with tcp you need to keep the connection alive
15:50:59 <AnMaster> so
15:51:10 <Deewiant> if you don't want to make a big spec.
15:51:16 <AnMaster> how do you do that then? some "keep alive" instruction needed maybe?
15:51:26 <AnMaster> Deewiant, I want something that won't take a year to implement
15:51:30 <Deewiant> hmm, isn't that builtin to TCP?
15:52:00 <AnMaster> Deewiant, I think connections times out, otherwise why is there an option for ssh keepalive for example
15:52:01 <Deewiant> http://tldp.org/HOWTO/TCP-Keepalive-HOWTO/overview.html
15:52:11 <AnMaster> Deewiant, you said "<Deewiant> and then get no traffic until the interpreter's at the breakpoint."
15:52:13 <AnMaster> that is the issue
15:52:16 <AnMaster> no traffic
15:52:38 <Deewiant> but isn't that rather an issue with the SSH daemon killing the connection
15:52:45 <AnMaster> not sure
15:52:46 <Deewiant> not with the OS
15:52:49 <Deewiant> neither am I
15:53:08 <Deewiant> but I do think it'd make more sense if it were
15:53:12 <Deewiant> so it probably is ;-)
15:54:09 <AnMaster> Deewiant, um, I think connection tracking in firewall will time out after a while with no traffic
15:54:14 <AnMaster> I'm pretty sure that is the case
15:55:08 <AnMaster> because I remember that back when I ran windows, I ran colinux for a while, I didn't need ssh keepalive to make a connection stay alive to colinux, UNTIL I enabled iptables in colinux
15:55:16 <AnMaster> then suddenly it was needed
15:55:19 <Deewiant> hm, possible
15:55:32 <Deewiant> alright, so enablable keepalives
15:55:41 <AnMaster> of the tcp type? yeah good idea
15:56:38 -!- ehird has joined.
15:56:49 <AnMaster> Deewiant, wait, the application doesn't do tcp keepalive?
15:56:52 <AnMaster> but the OS does?
15:56:54 <ehird> boop
15:56:58 <ehird> AnMaster: umm yeah
15:56:59 <AnMaster> ok then we need some protocol level one
15:57:08 <ehird> obviously the os' tcp layer handles that
15:57:09 <ehird> :)
15:57:10 <Deewiant> I honestly don't know whether you need app-level keepalives
15:57:16 <Deewiant> I don't think so, but I don't know
15:57:24 <AnMaster> Deewiant, irc uses it too
15:57:28 <AnMaster> PING/PONG
15:57:29 <ehird> it is kinda weird though, most raw-feeling socket stuff has a lot of bunk behind it in tcp
15:57:32 <Deewiant> yeah, but IRC is /old/
15:57:33 <ehird> it's really quite comfy
15:57:34 <ehird> :)
15:57:37 <ehird> and yeah
15:57:42 <ehird> IRC is an old dead machine
15:57:47 <ehird> ping/pong is pretty much useless
15:57:48 <AnMaster> agreed
15:57:55 <AnMaster> ehird, however ssh keepalive then
15:57:56 <ehird> & annoying to have to code into stuff
15:57:57 <AnMaster> it is useful
15:58:08 <ehird> AnMaster: ssh has to do all kinds of tricks to fit into the protocol it works on
15:58:13 <ehird> kind of like stack smashing in c
15:58:17 <AnMaster> <AnMaster> Deewiant, um, I think connection tracking in firewall will time out after a while with no traffic
15:58:17 <AnMaster> <AnMaster> I'm pretty sure that is the case
15:58:17 <AnMaster> <AnMaster> because I remember that back when I ran windows, I ran colinux for a while, I didn't need ssh keepalive to make a connection stay alive to colinux, UNTIL I enabled iptables in colinux
15:58:17 <AnMaster> <AnMaster> then suddenly it was needed
15:58:22 <AnMaster> ehird, hm ^
15:58:25 <Deewiant> yeah, SSH doesn't necessarily run over TCP
15:58:32 <ehird> maybe iptables moderates it
15:58:39 <Deewiant> maybe SSH keepalive just means enabling TCP keepalive, when on TCP
15:59:22 <AnMaster> hm
15:59:44 <Deewiant> once again, I have no clue.
16:00:01 -!- Judofyr has joined.
16:00:05 <ehird> i think ssh does its own keepalive
16:00:11 <ehird> so that it can be protocol-agnostic
16:00:18 <AnMaster> yeah
16:00:18 <ehird> however, protocol-agnostic programs are... uncommon :)
16:00:32 <AnMaster> ehird, well I need this to run over two kind of sockets
16:00:42 <AnMaster> TCP/TCP6 and Unix domain
16:01:46 <ehird> AnMaster: you should really give git a try
16:01:50 <ehird> not like
16:01:54 <ehird> try and use it for everything
16:01:58 <ehird> but just use some projects using it
16:02:03 <ehird> its not that bad once you get used to it. nice
16:02:08 <AnMaster> ehird, I have tried it
16:02:13 <ehird> AnMaster: presumably not recently
16:02:18 <ehird> yes, until recently, it was painful
16:02:20 <ehird> it's not any more
16:02:20 <AnMaster> ehird, about two months ago
16:02:27 <AnMaster> it changed since then?
16:03:02 <ehird> AnMaster: a litle bit. but you obviously didn't try it very well
16:03:15 <AnMaster> "obviously"?
16:03:16 <ehird> its kinda like lisp. you learn about it, laugh at it, hate it ferociously, then maybe try it and gradually 'get it' :)
16:03:33 <ehird> (also, darcs is pretty impressive for its theoretical basis. but mostly its used by lisp/haskellers)
16:03:45 <AnMaster> ehird, while I find lisp quite annoying I do see it have points, and I even coded some small bits of elisp
16:04:19 <AnMaster> ehird, and yes darcs indeed, didn't seem to be able to install haskell on my PPC based computer where I tried it
16:04:40 <slereah__> "We are a triune being - BODY, SOUL, and SPIRIT. Speaking computerese, we have Body - computer casing; Soul - Hard Drive/Hard Copy; Spirit - Software."
16:04:41 <slereah__> Lulz
16:04:52 -!- sebbu has quit (brown.freenode.net irc.freenode.net).
16:04:52 <ehird> 'uld help making Funge a more attractive language. In this'
16:04:57 <ehird> because funge should be an attractive language.
16:05:02 -!- sebbu has joined.
16:05:14 <ehird> AnMaster: find it quite annoying -- yeah your state with git is like yours with lisp :)
16:05:27 <ehird> i'm not patronising you, because i felt exactly the same way about git and lisp :p
16:05:32 <AnMaster> ehird, no I find git bloody stupid
16:05:35 <AnMaster> quite a difference
16:05:40 <ehird> AnMaster: still the same basic thing
16:05:46 <ehird> you don't "get it" yet
16:05:59 <AnMaster> ehird, also it is harder to learn for others
16:06:09 <AnMaster> I don't want to have to hand hold users once I get it
16:06:13 <AnMaster> as you said
16:06:18 <Deewiant> ehird: I don't like Darcs's patch-based model
16:06:32 <ehird> Deewiant: It does do a good job of sorting out stuff, though
16:06:34 <AnMaster> ehird, bzr is close enough to svn that you can easily change really
16:06:41 <ehird> Though its automatic hunking sometimes gets it wrong
16:06:51 <ehird> AnMaster: being close to svn is a flaw
16:06:53 <AnMaster> Deewiant, that is one thing I want from darcs
16:06:58 <AnMaster> the ability to juggle changesets
16:07:03 <ehird> svn is broken by design, and theoretically bullcrap
16:07:06 <AnMaster> and be able to track from where they came
16:07:11 <AnMaster> ehird, well cvs is worse
16:07:22 <ehird> AnMaster: cvs is probably better than svn.
16:07:25 <AnMaster> ehird, point is svn got a nice user interface
16:07:29 <ehird> I say that unsarcastically
16:07:34 <AnMaster> I'm not talking about internals
16:07:39 <AnMaster> but they way a user see it
16:07:41 <ehird> and if you think svn's user interface is nice I don't know what kind of monster you are
16:07:51 <AnMaster> ehird, compared to cvs at least
16:08:04 <AnMaster> ehird, err the one with two heads and three arms
16:08:07 <AnMaster> ;P
16:09:45 <ehird> really the ideal solution is plan9's versioned FS
16:09:50 <ehird> it's terribly advanced &nice to use
16:10:09 <ehird> unfortunately plan9, though infinitely better than any system i've come across, is totally useless for practical work :)
16:10:20 <AnMaster> ehird, exactly
16:10:33 <AnMaster> it's a research os
16:10:38 <AnMaster> that is now more or less dead
16:10:41 <ehird> AnMaster: not dead
16:10:45 <ehird> new snapshots are made daily
16:10:58 <AnMaster> ehird, so is the community growing?
16:11:10 <AnMaster> when will it have support for accelerated 3D?
16:11:11 <ehird> AnMaster: in little trickles
16:11:15 <ehird> AnMaster: it is a research os.
16:11:22 <ehird> why would it have support for that?
16:11:26 <AnMaster> when will it work on something as simple as a SATA disk?
16:11:32 <ehird> it does
16:11:33 <AnMaster> last I checked it didn't handle that
16:11:37 <AnMaster> hm ok
16:11:43 <ehird> iirc
16:12:04 <Deewiant> daily? http://plan9.bell-labs.com/sources/plan9/sys/src/ looks a bit older
16:12:09 <AnMaster> ehird, point is, it is not useful for practical work
16:12:27 <AnMaster> Deewiant, well for bell it *is* dead
16:13:55 <ehird> Deewiant: that's not a snapshot
16:13:59 <ehird> AnMaster: i already said that
16:14:05 <ehird> [15:10] <AnMaster> ehird, exactly
16:14:06 <ehird> [15:10] <AnMaster> it's a research os
16:14:06 <ehird> [15:10] <AnMaster> that is now more or less dead
16:14:08 <ehird> everything but the last line, i agree with
16:14:30 <Deewiant> ehird: where're the snapshots
16:14:36 <AnMaster> ehird, yes I was agreeing with you
16:14:43 <ehird> Deewiant: don't rememberr offhand
16:14:57 <ehird> AnMaster: ok, but it is NOT more or less dead
16:15:06 <ehird> it's alive, and interesting fromm a research POV
16:15:14 <ehird> hopefully the OSs of the future will resemble it in some way
16:15:26 <ehird> i really like it's refreshing approach to the mouse, actually
16:15:32 <ehird> the tests etc. they did and all
16:15:39 <ehird> and they developed an interface combining the keyboard and the mouse efficiently
16:15:41 <ehird> it's really nice
16:15:59 <ehird> i've always been a mouse fan, though. it's just that a lot of apps are designed suckily for one
16:16:09 <ehird> (I love acme.)
16:18:21 <AnMaster> hm?
16:18:32 <AnMaster> I prefer working with my hand on the keyboard
16:18:36 <AnMaster> avoiding mouse
16:18:55 <AnMaster> ergonomics
16:19:45 <ehird> AnMaster: the mouse is very effiient with the right interface
16:19:55 <ehird> and enough practice, a lot of mouse-haters just don't even try the mouse properly
16:19:59 <ehird> so they're simply not proficient with it
16:20:10 <AnMaster> ehird, I can use it well enough
16:20:26 <AnMaster> I use it a lot, but it make my hand hurt in the long run
16:20:57 <AnMaster> a track ball seems much better
16:21:03 <ehird> trackballs are interesting
16:21:12 <ehird> i am not sure they are superior to a well-calibrated mosue though
16:21:14 <AnMaster> ehird, of course there are tasks where you can't avoid mouse, for example image editing
16:21:20 <ehird> anyway, my whole computer interaction system is warped
16:21:31 <ehird> my hands are very efficient at jumping keyboard/mouse
16:21:36 <ehird> so the context switch is almost none
16:21:37 <AnMaster> where mouse or pen on touch surface are the only sane options
16:21:44 <ehird> also, my typing is really weird
16:21:51 <AnMaster> ehird, oh?
16:21:57 <ehird> my hands are predictive, they know which area they will be tapping the most before they actually tap
16:22:15 <ehird> so they kind of float about to a weird place and then a second later i realise that they were being really clever and going to the right place
16:22:40 <AnMaster> heh?
16:22:56 <AnMaster> yes of course I know where I will type
16:23:34 <ehird> no
16:23:35 <ehird> I mean
16:23:40 <ehird> my hands generally don't rset on the home row
16:23:54 <ehird> they type a bit then drift somewhere else (not conciously, they do it automatically)
16:24:04 <ehird> and then it ends up that where they drifted was where they'll be typing the most until the next drift
16:24:10 <ehird> it's strangely automatic
16:24:11 <AnMaster> so I move while the previous char is typed with the other hand. anyway I'm right-handed but I seem to type faster and use more of my fingers with left hand
16:24:18 <ehird> I just kind of wobble my hands and tap down
16:24:20 <ehird> and it all moves for me
16:24:26 <Deewiant> I never use the home row anyway
16:24:35 <AnMaster> Deewiant, nor do I
16:24:36 <Deewiant> my fingers are where they need to be, not on some default location :-P
16:24:43 <AnMaster> exactly
16:24:51 <AnMaster> that comes from not using vi IMO
16:24:51 <ehird> my idiosyncratic style has developed over quite a few years
16:25:00 <Deewiant> maybe, but I use vim :-P
16:25:07 <AnMaster> Deewiant, ah but I use emacs
16:25:37 <ehird> i use vi or emacs
16:25:43 <ehird> i quite like textmate on os x
16:25:58 -!- marshmallows has joined.
16:26:01 <AnMaster> mhm
16:26:02 <ehird> esp. for xml
16:26:06 <ehird> its really nice
16:26:13 <AnMaster> ehird, I tend to xml in kate
16:26:18 <AnMaster> C in emacs or kdevelop
16:26:34 <AnMaster> the problem is when finding out you used both for same file
16:26:36 <AnMaster> heh
16:26:37 <ehird> AnMaster: hmm, just tried xml'ing in kate
16:26:38 <AnMaster> at the same time
16:26:40 <ehird> not that hot
16:26:45 <ehird> but still hotter than anything emacs has, oddly
16:26:51 <AnMaster> ehird, I don't really do a lot of xml really
16:26:55 <ehird> emacs' xml support sucks more than anything else emacs can do
16:26:56 <AnMaster> so kate is enough for me
16:26:57 <ehird> it's just terrible
16:27:13 <ehird> i don't care if nxml has a validating xml parser written in emacs, it's crap
16:27:14 <AnMaster> ehird, agreed, it fails at indention in xml for example
16:27:50 <AnMaster> ehird, but the solution is very simple
16:27:55 <AnMaster> just use S-Expressions
16:28:03 <AnMaster> emacs got a very good support for that
16:29:21 <ehird> AnMaster: s-expressions can get really ugly for some types of data you know
16:29:37 <AnMaster> indeed, but much less overhead than xml in most cases
16:29:47 <ehird> also
16:29:51 <ehird> emacs has no S-Expr mode
16:29:52 <ehird> just lisp mode s:)
16:29:58 <ehird> Paredit on its own: nope. won't indent.
16:30:49 <AnMaster> hm?
16:30:59 <AnMaster> ehird, just open a html file or xml file in emacs
16:31:04 <AnMaster> it won't indent where you want
16:31:44 <AnMaster> while kate won't find the right indention level automatically either, it won't prevent you from doing it yourself
16:31:58 <Deewiant> emacs does? O_o
16:32:09 <AnMaster> Deewiant, yes for C it does
16:32:25 <Deewiant> I mean, "prevent you from doing it yourself"
16:32:35 <AnMaster> Deewiant, in xml mode it does yes oddly
16:34:19 <ehird> AnMaster: kate autoindents
16:34:22 <ehird> you must have it broken
16:34:41 <AnMaster> ehird, what version?
16:35:16 <AnMaster> ?
16:36:12 <AnMaster> ehird, =
16:36:13 <AnMaster> ?
16:36:27 <ehird> AnMaster: ubuntu
16:36:29 <AnMaster> ......
16:36:32 <AnMaster> what kate version
16:36:33 <AnMaster> ...
16:36:40 <ehird> ubuntu's kate.
16:36:43 <AnMaster> and kde version
16:36:43 <ehird> go in your config
16:36:47 <ehird> change the indent settings
16:36:48 <AnMaster> ehird, and that is 4.what?
16:36:51 <AnMaster> or 3.what?
16:36:52 <ehird> 4?
16:36:52 <ehird> no
16:36:53 <ehird> 3
16:37:04 <ehird> kate has ALWAYS indented xml
16:37:06 <ehird> its a config options
16:37:07 <ehird> sheesh
16:37:16 <AnMaster> help -> about kate
16:37:18 <ehird> change indent mode to 'c style'
16:37:19 <ehird> jesus
16:37:20 <AnMaster> what version?
16:37:23 <ehird> change indent mode to 'c style'
16:37:23 <ehird> change indent mode to 'c style'
16:37:23 <ehird> change indent mode to 'c style'
16:37:23 <ehird> change indent mode to 'c style'
16:37:30 <AnMaster> ehird, there is no such thing here
16:37:32 <AnMaster> odd
16:37:36 <ehird> AnMaster: settings
16:37:38 <ehird> configuration
16:37:39 <ehird> indentation
16:37:41 <ehird> -> c style
16:37:54 <AnMaster> you mean: Inställningar -> Anpassa kate?
16:38:06 <ehird> whatever, you dirty swede :)
16:38:08 <slereah__> If you use C style, Al Qaeda wins.
16:38:13 <AnMaster> slereah__, err?
16:38:23 <AnMaster> ehird, anyway emacs rocks for C
16:38:26 <ehird> real programmers use computers in english! ;)
16:38:29 <ehird> AnMaster: yes but C style indents xml
16:38:37 <AnMaster> ehird, perfect CScope integration for example
16:38:43 <olsner> I find most swedish translations of software disgusting
16:39:03 <AnMaster> olsner, the KDE one is unusally good
16:39:03 <AnMaster> not common
16:39:09 <AnMaster> but KDE one is actually really high quality
16:39:23 <olsner> oh, good for KDE
16:39:35 * olsner uses no KDE software
16:39:40 <AnMaster> olsner, gnome?
16:39:51 <AnMaster> they have very shitty Swedish translation iirc
16:40:00 <AnMaster> but I haven't used it for long
16:40:07 <AnMaster> so can't really say anything about current state
16:40:07 <olsner> nah, I use X11, with some software from the gnome project ;-)
16:40:24 <AnMaster> olsner, what window manager?
16:40:52 <ehird> oh god i'm pretentious
16:40:59 <ehird> i just responded to a post on reddit saying 'JWZ' with 'it's jwz'
16:41:13 <AnMaster> jwz?
16:44:31 <ehird> jamie zawinski
16:44:33 <olsner> AnMaster: xfce, so I guess I'm half-gnome
16:44:44 <AnMaster> ehird, doesn't mean anything to me
16:44:48 <ehird> Jamie W. Zawinski (born November 3, 1968[1] in Pittsburgh, Pennsylvania), commonly known as jwz, is an American computer programmer responsible for significant contributions to the free software projects Mozilla and XEmacs, and early versions of the proprietary Netscape Navigator web browser. He still actively maintains the XScreenSaver project, used by most Unix-like computer operating systems for screenblanking.
16:45:14 <ehird> (also: 'Zawinski is currently the proprietor of the DNA Lounge, a nightclub in San Francisco.')
16:45:44 <ehird> if you've ever heard: 'Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems.' then that's a jwz quote. it's also horribly incorrect
16:46:15 <AnMaster> ah
16:46:20 <Deewiant> that's often paraphrased as "I know, I'll use XML." ;-)
16:46:26 <AnMaster> ehird, I know someone who like to quote that yes
16:46:30 <AnMaster> one of the #bash regulars
16:46:34 <AnMaster> called greycat
16:46:53 <AnMaster> and well some ppl try to use regex where regex does not really fit
16:47:29 <olsner> hmm, has someone produced a turing complete regexp dialect yet?
16:47:36 <AnMaster> olsner, was just about to ask
16:47:45 <AnMaster> if not, someone should
16:48:37 <ehird> olsner: perl5 regexps
16:48:42 <ehird> also ais523 is working on one
16:48:46 <ehird> which is actually convenient for parsing
16:48:52 <ehird> AnMaster: aah, greycat. that moron :)
16:49:03 <AnMaster> ehird, oh? he is smart
16:49:06 <AnMaster> just very unusal
16:49:11 <olsner> doesn't perl5 regexpes rely on embedding perl code for TC:ness?
16:49:39 <AnMaster> ehird, I respect his knowledge, but I don't agree with his opinions
16:49:41 <ehird> AnMaster: smart but elitist and unhelpful
16:49:46 <ehird> & plain wrong on most things
16:49:53 <AnMaster> ehird, opinons indeed
16:49:55 <ehird> so a lot of smart going to waste
16:50:03 <ehird> olsner: nope
16:50:09 <ehird> you can have recursive regexps and some other stuff
16:50:10 <ehird> it is tc
16:50:23 <ehird> Speaking of jwz, this has to be the craziest lisp code i've ever seen: http://jwz.livejournal.com/854482.html
16:50:31 <AnMaster> ehird, and he knows more than anyone else on #bash about HP-UX ;)
16:50:40 <AnMaster> or whatever it was he ran
16:52:56 <olsner> heh, just the lisp equivalent of a bit of unsafePerformIO and unsafeCoerce :P
16:53:28 <ehird> AnMaster: knowledge about HP-UX, how useful and practical
16:53:44 <AnMaster> ehird, hehe exactly ;P
16:53:47 <ehird> olsner: except that those functions will be actively used in the code for: 1. efficient programs 2. OS-level code
16:53:49 <AnMaster> it was ironic
16:53:52 <ehird> since they were just low-level primitives
16:54:07 <ehird> #<massively-positive-bignum> is a hilarious printout though
16:54:34 <ehird> http://www.unlambda.com/nevermore/ ooo
16:55:46 <ehird> http://www.unlambda.com/lisp/meroko.page a different one, same site. odd
17:17:13 <AnMaster> Deewiant, where is the string GOOD: : on empty stack makes stack size 2 according to y stored
17:17:16 <AnMaster> I can't find it
17:18:23 <AnMaster> oh wait just found it
17:18:25 <AnMaster> but wtf
17:29:24 <ehird> is SISC's startup unbearably slow for anyone else?
17:29:51 <AnMaster> ehird, SISC?
17:32:17 <slereah__> Second Interpreter Scheme Something
17:32:22 <ehird> seecond interpreter of scheme code
17:32:24 <ehird> a java scheme interp
17:32:26 <ehird> main interest:
17:32:33 <ehird> it has full continuations while still interacting with java, and
17:32:36 <ehird> everything is serializable in it
17:32:44 <ehird> you can serialize functions, continuations, everything except obviously things like sockets
17:37:06 <AnMaster> Deewiant, so far it seems to be crap on after the newline in "GOOD: ] turns flying IP right"
17:37:32 <AnMaster> stack have 1 2 3 4 at that point
17:37:34 <AnMaster> wtf
17:42:49 <AnMaster> Deewiant, the code in that area is very confusing
17:43:51 <ehird> hmm
17:43:55 <ehird> i wonder how hard implementing a basic smalltalk is
17:45:14 -!- Corun has joined.
17:45:45 <AnMaster> "GOOD: \ on empty stack makes"$"x stack size 2 accord"<
17:45:53 <AnMaster> Deewiant, what is the $ there for?
17:45:59 <AnMaster> it tests something else at once?
17:46:22 <AnMaster> oh wait
17:46:32 <AnMaster> it is code running through the string
17:46:36 <AnMaster> oh my
17:50:25 <ehird> hmm
17:50:28 <ehird> anyone a smalltalker?
17:50:39 <ehird> do messages have built-in arity, i.e. can I respond_to with an argc?
17:50:41 <ehird> i think no
17:51:50 <AnMaster> <small>well depends on how you define smalltalker</small>
17:52:07 * AnMaster runs
17:53:01 <ehird> for (i = argc; i--;) { /* cute c hack *.
17:59:37 <AnMaster> ehird, if you want to parse your command line arguments backwards it does indeed seem like the right way
17:59:45 <AnMaster> why on earth you would want that I don't know
17:59:52 -!- slereah_ has joined.
18:03:30 <ehird> AnMaster: yeah, oops :)
18:03:32 <ehird> anyway
18:03:42 <ehird> http://rafb.net/p/x7YYOH94.html skeleton of message sending for my imaginary smalltalk
18:04:08 <AnMaster> ehird, I think objc does message based object orientation too?
18:04:09 <AnMaster> iirc
18:04:17 <ehird> AnMaster: yep
18:04:20 <ehird> objc is smalltalk+c
18:04:25 <ehird> [...] = smalltalk-land!
18:04:30 <ehird> and some bits with @ and - (abc)
18:04:31 <ehird> but yeah
18:04:50 <AnMaster> bbiab food
18:04:53 -!- Tritonio_ has joined.
18:07:11 <ehird> http://jwz.livejournal.com/843296.html hahahahahah
18:14:34 <AnMaster> ehird, that dialog in mosaic was optional and not the default
18:14:56 <ehird> AnMaster: i know that
18:15:07 * AnMaster has been working on mosaic code recently
18:15:12 <ehird> AnMaster: it was added because of corporate bureaucracy
18:15:18 <AnMaster> oh?
18:15:41 <ehird> yeah
18:15:48 <ehird> a corporate customer wanted some kind of warning or similar
18:15:50 <ehird> so they added that
18:15:56 <ehird> (config key: protectmefrommyself, iirc)
18:15:56 <AnMaster> hah
18:16:01 <ehird> i read up on mosaic aaages ago :)
18:16:12 <AnMaster> ehird, yes I think it is, prefsdefs.h iirc
18:16:14 <AnMaster> ;P
18:16:25 <AnMaster> not totally sure about what header file
18:19:14 -!- slereah_ has quit (Read error: 104 (Connection reset by peer)).
18:20:10 -!- slereah_ has joined.
18:27:37 -!- Sle has joined.
18:27:53 -!- Sle has changed nick to Slereah.
18:28:59 -!- slereah_ has quit (Read error: 104 (Connection reset by peer)).
18:30:49 -!- slereah__ has quit (Read error: 110 (Connection timed out)).
18:49:00 -!- okopol has joined.
19:05:26 <AnMaster> Deewiant, so far I found whatever causes it happens somewhere before ] turning flying IP test
19:05:40 <AnMaster> and *probably* after "GOOD: y acts as pick instruction if given large enough argument"
19:06:25 <AnMaster> actually happens before it
19:06:26 <AnMaster> sigh
19:07:01 <Deewiant> what's your stack at (140,163)
19:07:15 <AnMaster> um can't break like that yet *looks*
19:07:27 <Deewiant> and hence debuggers are handier than tracing ;-)
19:07:48 <AnMaster> agreed that is why I'm working on the protocol
19:09:30 <AnMaster> (gdb) break ExecuteInstruction if (ip->position.x == 140) && (ip->position.y == 163)
19:09:33 <AnMaster> Deewiant, :P
19:09:46 <AnMaster> tix=0 tid=1 x=140 y=163: f (102)
19:09:47 <Deewiant> :-P
19:09:58 <AnMaster> (gdb) call StackDump(ip->stack)
19:09:58 <AnMaster> 5 elements:
19:09:58 <AnMaster> 1 2 3 4 0
19:10:07 <AnMaster> Deewiant, yes indeed it is wrong even at that point
19:10:17 <AnMaster> those 1 2 3 4 is what is messing up below
19:10:31 <Deewiant> hm
19:10:49 <Deewiant> your y isn't working as a pick instruction correctly
19:10:58 <AnMaster> Deewiant, hm, it says it is
19:11:00 <AnMaster> :/
19:11:05 <Deewiant> the test isn't sufficient
19:11:06 <AnMaster> "GOOD: y acts as pick instruction if given large enough argument"
19:11:11 <Deewiant> or rather, it is, in a way
19:11:14 <AnMaster> oh?
19:11:16 <Deewiant> you can't ever be sure the stack is really empty
19:11:18 <Deewiant> but one sec
19:11:24 <Deewiant> I can make it a bit better easily
19:11:27 <AnMaster> Deewiant, you can after n really, right?
19:11:48 <Deewiant> yes, but you can't be sure whether n deleted anything or not
19:11:51 <Deewiant> that's what I meant
19:11:57 <Deewiant> i.e. in this case, after the y, the stack should have only a 2
19:12:04 <Deewiant> and that's all that's being tested for
19:12:07 <AnMaster> hm
19:12:09 <Deewiant> I'll make it check for 2 and then 0
19:12:18 <AnMaster> what would cause the 3 and 4?
19:12:20 <Deewiant> ideally it'd check for 2 and then empty, but that's basically impossible
19:12:24 <AnMaster> ie, where do they come from
19:12:42 <Deewiant> 1234 is put on the stack
19:12:49 <Deewiant> from which 2 is meant to be piciked
19:12:54 <Deewiant> s/picik/pick/
19:13:03 <AnMaster> ok, y as pick should not pop any item right?
19:13:13 <AnMaster> but just push the given item?
19:13:18 <AnMaster> or did I get that wrong?
19:13:19 <Deewiant> according to the spec surely it should :-P
19:13:25 <AnMaster> aha
19:14:09 <AnMaster> Deewiant, so it should pop until that point?
19:14:35 <AnMaster> then how does it differ from say 4k$ ?
19:14:46 <Deewiant> it also clears the stack below
19:15:01 <AnMaster> Deewiant, so the stack is empty except that item, huh
19:15:02 <Deewiant> so it's more like 4k$00pn00g
19:15:06 <Deewiant> yep
19:15:11 <AnMaster> but y doesn't always clear the stack does it?
19:15:22 <Deewiant> if you want to pull from tar.us.to:8000 go ahead
19:15:44 <Deewiant> with luck the test works
19:16:08 <Deewiant> and with luck the DNS resolves correctly this time :-P
19:16:15 <AnMaster> FUNGEDATATYPE tmp = ip->stack->entries[ip->stack->top - (request - tmp->top)];
19:16:15 <AnMaster> StackClear(ip->stack);
19:16:15 <AnMaster> StackPush(tmp, ip->stack);
19:16:26 <AnMaster> is that correct then for the case of y going pick?
19:16:37 <Deewiant> something like that
19:16:48 <Deewiant> just pull the myco and test it
19:17:47 <AnMaster> ok that works now
19:17:58 <AnMaster> Deewiant, however, should y clear stack in other cases too?
19:18:05 <Deewiant> no, no
19:18:08 <Deewiant> read the spec
19:18:34 <AnMaster> If y is given a positive argument, all these cells are pushed onto the stack as if the argument was non-positive. However, y then goes on to copy the argumentth stack cell (counting from the top) into a temporary location, subsequently removing all the cells it pushed onto the stack. It then pushes the temporary cell onto the stack. For example, 3y will act as if only the handprint was pushed onto the
19:18:34 <AnMaster> stack.
19:18:40 <AnMaster> yes, that *it* pushed
19:18:47 -!- poiuy_qwert has joined.
19:18:52 <AnMaster> don't seem to be like it pushed the first 1 did it?
19:18:59 <AnMaster> Deewiant, ?
19:19:02 <Deewiant> An interesting side-effect of this behaviour is that if y is given an argument that exceeds the number of cells it pushes onto the stack, it can act as a 'pick' instruction on data that was on the stack before y was even executed.
19:19:11 <AnMaster> yes indeed
19:19:12 <Deewiant> hmm
19:19:19 <Deewiant> you may be right
19:19:22 <Deewiant> let's see
19:19:22 <AnMaster> but where does it say it should clear the stack?
19:19:35 <AnMaster> at most it is an undef
19:20:31 <AnMaster> and probably it is a BAD to clear the stack
19:20:50 <Deewiant> augh, I can't test this because 0y doesn't work in other interpreters :-P
19:21:07 <AnMaster> Deewiant, err 0y must work on some to push stuff?
19:21:17 <Deewiant> ?
19:21:31 <AnMaster> Deewiant, what do you mean 0y doesn't work?
19:21:37 <Deewiant> I mean, 0y doesn't work.
19:21:46 <AnMaster> hm
19:21:49 <Deewiant> it gives the wrong stack size.
19:21:52 <AnMaster> ok
19:21:59 <AnMaster> Deewiant, try gdb
19:22:05 <AnMaster> and a breakpoint and then examine stack
19:22:25 <AnMaster> Deewiant, btw I think my gdb breakpoint was quite nifty
19:22:26 <AnMaster> ;)
19:22:58 <AnMaster> and is actually more useful to me to debug the interpreter itself but to debug a script it is less useful
19:23:03 <AnMaster> err program
19:24:22 <Deewiant> hmm, this may actually be a CCBI bug
19:24:31 <Deewiant> pop(size - oldStackSize);
19:24:34 <AnMaster> Deewiant, XD
19:24:46 <Deewiant> I wonder what's up with that
19:25:13 <AnMaster> Deewiant, well hurry up or rename it to NCCBI ;)
19:25:27 <AnMaster> Deewiant, in any case looks like I'm right and mycology wrong or?
19:25:27 <Deewiant> bugs happen
19:25:40 <AnMaster> I want to know what way I should do it
19:27:34 <Deewiant> at this point I'm not sure where the bug is
19:27:36 <Deewiant> gimme a few secs
19:27:49 <AnMaster> just want to know if I need to change cfunge or you change mycology
19:28:00 <Deewiant> wondering what on earth "aa 2++k$" is doing in myco
19:28:10 <Deewiant> I think it's getting the stack size
19:28:14 <Deewiant> but it might be messing it up too
19:28:22 <AnMaster> I don't want to have to use a #define MYCOLOGY_COMPATIBLE vs #define STANDARD_COMPATIBLE ;)
19:32:45 <Deewiant> hmm
19:32:54 <Deewiant> it does seem to be a CCBI bug
19:33:04 <Deewiant> and of course Mycology as well
19:33:09 <AnMaster> ok
19:33:22 <AnMaster> hope you can fix it soon in mycology so I can look at the next bug
19:33:23 <Deewiant> but I'm wondering what the right way of resolving this is
19:33:37 <Deewiant> if (size > oldSize) pop(size - oldSize); ??
19:33:44 <Deewiant> does that make any sense?
19:33:50 <AnMaster> err I have not read your sysinfo code at all
19:34:04 <AnMaster> mine is completely freestanding
19:34:07 <Deewiant> what it does is, like the spec says, it pushes everything
19:34:18 <Deewiant> then it pops up to the argumenth cell
19:34:25 <Deewiant> pops the cell to be picked
19:34:31 <Deewiant> and then does pop(size - oldSize);
19:34:34 <AnMaster> I push things to a temp stack
19:34:36 <AnMaster> and then do this
19:34:38 <AnMaster> if (tmp->top > (size_t)request)
19:34:38 <AnMaster> StackPush(tmp->entries[tmp->top - request], ip->stack);
19:34:38 <AnMaster> else
19:34:38 <AnMaster> StackPush(ip->stack->entries[ip->stack->top - (request - tmp->top)], ip->stack);
19:34:42 <AnMaster> tmp is the temp stack
19:34:54 <AnMaster> request is the thing y popped of the main stack
19:34:58 <Deewiant> stack->top is the stack size?
19:35:05 <Deewiant> or a pointer to the top?
19:35:07 <AnMaster> Deewiant, it is the top stack item yes
19:35:17 <Deewiant> yeah, so the size
19:35:20 <Deewiant> makes sense
19:35:28 <AnMaster> Deewiant, top->size however is the actual stack size, as it doesn't realloc to smaller stack
19:35:29 <Deewiant> so if size > arg...
19:35:37 <Deewiant> yeye, same difference
19:35:46 <Deewiant> I don't think I expose the "actual size" myself :-)
19:35:47 <AnMaster> argh getting dcc chat spam
19:36:04 <Deewiant> if size > arg, if oldSize <= size
19:36:52 -!- otesanek has joined.
19:37:40 <Deewiant> both appear to work
19:40:07 <Deewiant> AnMaster: you might still have it wrong, though :-P
19:40:21 <Deewiant> AnMaster: pull
19:40:25 -!- poiuy_qwert has quit.
19:40:32 <AnMaster> k
19:41:12 <AnMaster> BAD: y doesn't act as pick instruction if given large enough argument
19:41:13 <AnMaster> ok
19:41:18 <AnMaster> Deewiant, how would it be wrong now?
19:41:34 <Deewiant> pop up to the requested one, but leave everything below that untouched
19:41:38 <AnMaster> ah
19:41:40 <AnMaster> right
19:45:49 <AnMaster> Deewiant, ok pushed fixed cfunge :)
19:46:08 <AnMaster> GOOD: 000p000W goes thrugh
19:46:08 <AnMaster> GOOD: 000p100W waits indefinitelyGOOGOOD: X works
19:46:11 <AnMaster> still have to solve that
19:46:19 <AnMaster> Deewiant, any idea about wtf may be going on there?
19:46:46 <AnMaster> I copied the logic of TOYS' W from CCBI
19:46:51 <AnMaster> or or less
19:46:55 <Deewiant> not really, no
19:47:08 <AnMaster> Deewiant, ok, can you tell me where in the file that is?
19:47:12 <Deewiant> does that really print "thrugh" btw
19:47:18 <AnMaster> Deewiant, not for CCBI
19:47:19 <Deewiant> just grep for 000p000W
19:47:24 <Deewiant> AnMaster: good :-)
19:47:33 <AnMaster> Deewiant, problem is I don't know what direction to grep for it in
19:47:40 <Deewiant> grep it left to right
19:47:45 <Deewiant> if you can't find it, grep it right to left
19:47:52 <AnMaster> I mean it is probably either left to right or right to left
19:47:53 <AnMaster> but
19:47:55 <Deewiant> and if you still can't find it, use another part of the error message
19:47:56 <Deewiant> :-P
19:47:59 <AnMaster> it could be upwards or downwards
19:48:07 <AnMaster> someone need to invent a fungegrep
19:48:07 <Deewiant> in 99% of cases it isn't
19:48:10 <AnMaster> like there is xmlgrep
19:48:22 <Deewiant> or if it is, then look for the next or previous message
19:48:33 <AnMaster> v"U executes itself after transmuting"_v#! <g1<< >'<w;was <; 00g:3-!#v_1+00p'^48a*+3bd**p^ ^ < >v>;#"BAD: 000p000W reflects"ap$$$<;^
19:48:35 <AnMaster> right
19:55:51 <AnMaster> Deewiant, the problem is that it is concurrent
19:56:00 <AnMaster> so bloody hard to make sense of
19:56:01 <AnMaster> :/
19:56:41 <Deewiant> yep :-/
19:57:39 -!- bsmntbombdood has joined.
19:59:31 -!- marshmallows has quit ("Leaving").
20:01:00 -!- otesanek has quit (Read error: 113 (No route to host)).
20:06:16 <AnMaster> Deewiant, so the W is kind of like Compare and exchange?
20:06:19 <AnMaster> or?
20:06:49 <Deewiant> W ('television antenna') pops a vector off the stack, then a value. If the cell at that vector (plus the storage offset) in Funge-Space (a la g) is equal to that value, nothing happens. If the cell in space is less than the value, it pushes the value and the vector (inverted) back onto the stack, and backs up the IP (subtracts the IP's delta from it's position, sort of a 'wait to try again' condition, useful mainly in Concurrent Funge.) If the cell in s
20:07:33 <Deewiant> so it keeps retrying until the cell at the vector is >= the requested value
20:07:40 <Deewiant> if it's >, it reverses, if it's =, it does nothing
20:07:45 <Deewiant> (besides popping the vals, of course)
20:07:58 <AnMaster> hah
20:08:01 <AnMaster> aha*
20:08:15 <AnMaster> Deewiant, is it reverses and tries to execute again on next tick?
20:08:26 <AnMaster> ie a kind of semaphore?
20:08:33 <Deewiant> yeah, kinda
20:08:43 <Deewiant> like it says, "sort of a 'wait to try again' condition"
20:10:31 <AnMaster> Deewiant, but why doesn't it print BAD
20:10:45 <AnMaster> why does it print some weird GOODGOOD and missing char stuff?
20:10:53 <AnMaster> Deewiant, and is the error really in W?
20:10:56 <Deewiant> because it's concurrent and complicated :-P
20:10:58 <Deewiant> I can't be sure
20:10:59 <AnMaster> or does W use something not tested before?
20:11:04 <Deewiant> I hope not
20:11:21 <Deewiant> once again, compare stacks (and, since concurrent, IP positions) with CCBI
20:12:12 <AnMaster> tix=0 tid=1 x=172 y=430: g (103)
20:12:12 <AnMaster> tix=1 tid=2 x=164 y=432: n (110)
20:12:12 <AnMaster> tix=0 tid=1 x=173 y=430: u (117)
20:12:12 <AnMaster> tix=1 tid=2 x=165 y=432: @ (64)
20:12:12 <AnMaster> tix=0 tid=1 x=175 y=430: r (114)
20:12:13 <AnMaster> tix=0 tid=1 x=176 y=430: h (104)
20:12:15 <AnMaster> tix=0 tid=1 x=177 y=430: t (116)
20:12:17 <AnMaster> um
20:12:19 <AnMaster> ??
20:12:27 <AnMaster> is that supposed to happen
20:12:37 <AnMaster> it is where the through string is messed up I think
20:12:39 <Deewiant> possibly, I can't remember
20:14:41 -!- oerjan has joined.
20:14:50 <AnMaster> hguorht
20:14:59 <AnMaster> Deewiant, to me it seems something overwritten wrong place
20:15:10 <Deewiant> so what are your storage offsets like
20:15:14 <AnMaster> because the code does not contain any @ in that place
20:15:36 <AnMaster> hm
20:15:56 <AnMaster> c = space[x, y];
20:16:02 <AnMaster> Deewiant, that is from your code
20:16:12 <AnMaster> no storage offset is used when accessing ?
20:16:17 <AnMaster> but only when writing it back?
20:16:26 <AnMaster> pushVector(x - ip.offsetX, y - ip.offsetY);
20:16:29 <AnMaster> from your code too
20:16:32 <Deewiant> 165 432 is meant to be @
20:17:04 <AnMaster> err *looks*
20:17:09 <Deewiant> AnMaster: but isn't that a concurrency bug, right there
20:17:20 <Deewiant> AnMaster: why does your other IP skip over the 'o' when the other hits '@'
20:17:39 <AnMaster> hm
20:17:41 <AnMaster> right
20:17:46 <AnMaster> I was reading on the wrong line
20:18:20 <AnMaster> Deewiant, um
20:18:22 <AnMaster> *looks*
20:18:59 <AnMaster> http://rafb.net/p/pYLvrJ74.html
20:19:07 <Deewiant> the @ is put there by the p at (168,430)
20:19:16 <AnMaster> Deewiant, if I just had such a output from ccbi too so I could compare
20:19:23 <AnMaster> but maybe time for a funge space dump
20:19:31 <Deewiant> I'd start with figuring out why the 'o' isn't output
20:20:13 <AnMaster> v"U executes itself after transmuting"_v#! <g1<< >'<w;was <; 00g:3-!#v_1+00p'^48a*+3bd**p^ ^ < >v>;#"BAD: 000p000W reflects"ap$$$<;^
20:20:14 <AnMaster> >"" >" :FEDNU">:#,_a,$111p > > > ^ > ;BAD;^ >na"v^<> fo lla otni detumsnart U :DOOG">:#,_1y2%!#v_p'@faf*+689**000#vt#^Wpa"hguorht"v
20:20:14 <AnMaster> v>"nseod U"^ > ^ v<< < >
20:20:14 <AnMaster> " stiaw W000p000 :DABvv"deb*+25ef*+*p83a*+689**p@ v "Cannot test W without Concurrent Funge-98 support."a< >>>n@"yletinifedni"
20:20:16 <AnMaster> " v$$$< >$$$pna"stcelfer W001p000 :DAB" v >$$$pa"stcelfer W00-10p000 :DOOG" v
20:20:19 <AnMaster> is how it looks
20:20:21 <AnMaster> in the dump
20:20:53 <AnMaster> '^48a*+3bd**p^ ^ < >v>;#"BAD: 000p000W reflects"ap$$$<;^
20:20:53 <AnMaster> > fo lla otni detumsnart U :DOOG">:#,_1y2%!#v_p'@faf*+689**000#vt#^Wpa"hguorht"v
20:20:53 <AnMaster> ^ v<< < >
20:20:53 <AnMaster> est W without Concurrent Funge-98 support."a< >>>n@"yletinifedni"
20:20:53 <AnMaster> v >$$$pa"stcelfer W00-10p000 :DOOG" v
20:20:56 <AnMaster> >;#$$$$$< ;>:#,_'@6bc*+f92a*+*01-00#vt#^Wpa"hguorht seog W00-10p000 :DAB" v
20:20:58 <AnMaster> ^v"d5*27ef*+*pc9*f92a*+*p@ > #< #<na#<"yletinifedni stiaw W00-10p000 :DABvv";
20:21:00 <AnMaster> <
20:21:02 <AnMaster> is more relevant
20:21:04 <AnMaster> sorry for spam
20:21:08 <Deewiant> pasting huge bunches of Befunge here isn't exactly useful :-P
20:21:24 <AnMaster> Deewiant, problem is I can't make head or tail out of the code at all
20:21:53 <Deewiant> like said, I wouldn't worry about reading Mycology
20:21:58 <Deewiant> you have a bug: the 'o' isn't output
20:21:59 <Deewiant> why not
20:22:10 <Deewiant> you don't need mycology for that other than running through it with gdb
20:22:27 <AnMaster> yes I realize it isn't there
20:22:35 <AnMaster> but I don't understand it
20:22:44 <Deewiant> the o /is/ there, in the code
20:22:53 <Deewiant> the problem is that Cfunge is skipping over it
20:23:01 <Deewiant> I'd wager the problem is in how you handle @
20:23:08 <AnMaster> hm
20:23:17 <AnMaster> Deewiant, so why doesn't mycology test it before? heh
20:23:44 <AnMaster> I mean I only found out because of this fingerprint
20:23:58 <Deewiant> I can't test everything, as I've said many times before
20:24:02 <AnMaster> hm
20:24:05 <Deewiant> trust me, writing code for testing 2 threads was bad enough
20:24:08 <Deewiant> let alone 3 or more
20:24:14 <AnMaster> I agree
20:24:23 <Deewiant> because the point is that even if space or z don't work as regards ticks, the code has to work
20:24:25 <AnMaster> I have coded some simple concurrent
20:24:38 <Deewiant> so I had to rerun it over and over again with CCBI's space mapped to z and vice versa
20:24:42 <Deewiant> and make sure it worked in all cases
20:24:53 <AnMaster> yeah
20:25:29 <AnMaster> tix=0 tid=1 x=173 y=430: u (117)
20:25:29 <AnMaster> tix=1 tid=2 x=165 y=432: @ (64)
20:25:29 <AnMaster> tix=0 tid=1 x=175 y=430: r (114)
20:25:35 <AnMaster> indeed it skips one simply
20:25:43 * AnMaster ponders
20:26:28 <AnMaster> that means one of two files really, interpreter.c or ip.c
20:35:31 <AnMaster> Deewiant, fixed it
20:35:40 <Deewiant> what was the problem
20:35:43 <AnMaster> just needed to set a NeedMove to false
20:35:54 <Deewiant> right
20:36:04 <AnMaster> Deewiant, I'm not sure how this will work out of there are more than two IPs though
20:36:10 <AnMaster> it may break in the other way then
20:36:17 <Deewiant> I think there are 3 where that's tested
20:36:20 <Deewiant> though I'm not sure
20:36:30 <Deewiant> no, more likely it's 2
20:36:39 <Deewiant> no more than 2 are alive at once
20:36:42 <Deewiant> but more are created
20:36:55 <AnMaster> also the new IP must be index 0 in the array
20:36:59 <AnMaster> and a few other things
20:37:19 <AnMaster> 1) the remaining ip must now have index 0 before, the killed one index 1
20:37:24 <AnMaster> there must be no third IP
20:37:33 <Deewiant> O_o
20:37:34 <AnMaster> only then does the bug show up and is fixed this way
20:37:39 <Deewiant> heh
20:37:46 <AnMaster> I don't know if it will break in other cases
20:37:53 <AnMaster> no idea whatsoever
20:38:09 <AnMaster> it might
20:38:41 <AnMaster> so I'll write a few small test cases
20:49:34 -!- Corun has quit ("This computer has gone to sleep").
20:51:20 -!- Tritonio_ has quit (Remote closed the connection).
20:52:00 -!- Tritonio_ has joined.
20:53:14 -!- oerjan has quit ("leaving").
20:53:14 <AnMaster> wow
20:53:17 -!- Tritonio_ has quit (Remote closed the connection).
20:53:18 <AnMaster> cfunge: /home/arvid/src/cfunge/trunk/src/stack.c:313: StackStackDuplicate: Assertion `old != ((void *)0)' failed.
20:53:19 <AnMaster> Deewiant, ^
20:53:34 <Deewiant> :-D
20:53:35 <AnMaster> > #vt zzzzzzzzzzzzz v
20:53:36 <AnMaster> >#vtzzz@
20:53:36 <AnMaster> >a"DOOG :4">:#,_@
20:53:36 <AnMaster> v <
20:53:38 <Deewiant> how'd you get that
20:53:38 <AnMaster> on that code
20:53:48 <AnMaster> no brainfucking clue how
20:53:49 <Deewiant> on the second t?
20:54:00 <AnMaster> Deewiant, on;
20:54:02 <AnMaster> tix=1 tid=6 x=11 y=18: @ (64)
20:54:02 <AnMaster> tix=2 tid=0 x=5 y=3: t (116)
20:54:18 <AnMaster> wait a sec
20:54:20 <AnMaster> that makes no sense
20:54:24 <Deewiant> y=3?
20:54:55 <AnMaster> yes indeed makes no sense
20:55:00 * AnMaster gets out valgrind
20:55:01 <Deewiant> :-P
20:55:22 <AnMaster> ==16089== Conditional jump or move depends on uninitialised value(s)
20:55:23 <AnMaster> as I expected
20:55:35 <AnMaster> wth
20:56:28 <Deewiant> of course, valgrind is something you should run on your code before complaining about mycology tests ;-)
20:56:28 <AnMaster> Deewiant, if you want to experiment:
20:56:29 <AnMaster> http://rafb.net/p/tSF4nt31.html
20:56:44 <AnMaster> Deewiant, well valgrind gives no issues when running mycology
20:57:00 <AnMaster> a few memory leaks in funge space as you can't use gc + valgrind at same time
20:57:02 <AnMaster> but that's all
20:57:03 <Deewiant> uh? shouldn't that conditional be entered always?
20:57:15 <Deewiant> in t or @ or wherever that is
20:57:31 <AnMaster> in hash function
20:57:33 <ehird> sill scheme interpreter name: Isch Creme
20:57:35 <AnMaster> not sure
20:57:41 <ehird> or ischcreme
20:58:01 <AnMaster> Deewiant, ==16254== ERROR SUMMARY: 0 errors from 0 contexts
20:58:07 <AnMaster> when running on mycology
20:58:10 <Deewiant> AnMaster: that needs more 'z', prints 3: G4O:O DG here :-)
20:58:18 <Deewiant> AnMaster: odd
20:58:29 <AnMaster> <Deewiant> AnMaster: that needs more 'z', prints 3: G4O:O DG here :-)
20:58:30 <AnMaster> ???
20:58:40 <AnMaster> it should print 3: GOOD
20:58:42 <AnMaster> ??
20:59:13 <Deewiant> 3 and 4 are interspersed here
20:59:20 <AnMaster> Deewiant, aha
20:59:36 <Deewiant> please don't tell me that CCBI on linux behaves differently :-D
21:00:50 <AnMaster> $ ~/funge/ccbi/ccbi_linux/ccbi tests/concurrent-quit.b98
21:00:51 <AnMaster> 1: GOOD
21:00:51 <AnMaster> 2: GOOD
21:00:51 <AnMaster> 3: GOOD
21:00:51 <AnMaster> 4: GOOD
21:00:53 <AnMaster> ?
21:00:58 <AnMaster> Deewiant, that is what happens here
21:01:05 <AnMaster> may not be last version
21:01:15 <AnMaster> oh wait this is a slightly different version
21:01:20 <AnMaster> than the one I pastebinned
21:01:21 <AnMaster> right
21:01:26 <Deewiant> heh
21:01:40 <AnMaster> Deewiant, ok, the first two splits are ok
21:01:44 <AnMaster> 1 and 2 in cfunge
21:01:47 <AnMaster> then issues start
21:01:58 <AnMaster> tix=0 tid=0 x=5 y=17: t (116)
21:02:20 <AnMaster> splitting after the third one in fact
21:08:29 <AnMaster> Deewiant, hm, now by adding a mutex it is "fixed", but now I need to reproduce the issue again
21:11:48 <AnMaster> >@
21:11:49 <AnMaster> >#^tzz@
21:11:49 <AnMaster> > #^tz#vt v
21:11:49 <AnMaster> >zzzz@
21:11:49 <AnMaster> v <
21:11:51 <AnMaster> Deewiant, that does it
21:11:57 <AnMaster> looking at minimizing it
21:12:34 <AnMaster> the upper split can be removed
21:15:20 -!- Corun has joined.
21:18:08 <AnMaster> actually wrong
21:18:13 <AnMaster> it still interacts with previous code
21:19:26 -!- okopol has changed nick to oklopol.
21:23:04 <AnMaster> Deewiant, ok this need a very specific split pattern to trigger
21:23:10 <AnMaster> 1) ip 0 split
21:23:27 <AnMaster> 2) ip 1 just goes on doing z or whatever
21:23:37 <AnMaster> 3) ip 0 split again
21:24:03 <AnMaster> result is that suddenly we got two ip entries but array length of 3
21:38:24 <AnMaster> Deewiant, ^
21:38:34 <AnMaster> Deewiant, I think I am beginning to solve it
21:59:05 -!- calamari has joined.
22:06:12 -!- nice_ka has joined.
22:19:45 -!- RedDak has joined.
22:44:29 -!- pikhq has joined.
22:47:33 -!- Deformative has quit ("Konversation terminated!").
22:48:52 -!- Deformative has joined.
22:50:02 -!- Deformative has quit (Remote closed the connection).
22:51:00 -!- Deformative has joined.
22:58:35 -!- Tritonio_ has joined.
23:13:23 * oklopol made a O(1)-space quicksort
23:13:26 <oklopol> i think...
23:13:38 <oklopol> so hard to know what counts as O(1)
23:14:27 <oklopol> i need to fiddle with the bitstring of len(l) where l is the sorted list, so basically it's O(lg n) space anyway... i'm fairly sure you can't actually manage O(1), although i've been told it exists
23:15:04 <oklopol> err no, i need numbers 0...len(n), so it's O(lg lg n) space, i guess, but still
23:16:54 <ehird> oklopol: O(1) - given any list, uses the asme space
23:16:58 <ehird> a 43593459345435 elm list == same space as 4
23:17:32 <ehird> oklopol: maybe you could use xrange insead of range
23:17:35 <ehird> that calculates it lazily
23:19:29 -!- Deformati has joined.
23:21:02 <oklopol> ...what?
23:21:08 <oklopol> asme?
23:21:43 <ehird> oklopol: thats O(1) space
23:21:54 <ehird> if sort() is O(1)
23:22:08 <oklopol> i use a few iterators where a retard might have used a strictly evaluated list, yes, but xrange doesn't really solve the whole thing
23:22:09 <ehird> sort([45,345,2,34,3]) takes same memory as sort([345345,345,35,24,12,3,7,34,5,7,4,6,7,345,,,67,345,7,,5,345,45])
23:22:16 <oklopol> really?
23:22:18 <oklopol> it does? :O
23:22:32 <ehird> if its O(1)
23:22:37 <oklopol> what do people usually do to get rid of the recursion stack?
23:22:39 <oklopol> oh, right
23:22:44 <oklopol> err not
23:22:46 <oklopol> *no
23:22:50 <oklopol> i specified *quicksort*
23:22:53 <oklopol> so...
23:22:55 <oklopol> enlighten me
23:23:00 <oklopol> my solution isn't all that trivial
23:24:04 <ehird> oklopol: get rid of recursion=manual stack
23:24:22 <oklopol> well, it's kinda trivial, just a certain pattern around the bits of len(l) + calculating in O(n) the median, pivotting perfectly
23:24:33 <oklopol> ehird: how's that O(1) space more than the recursion stack?
23:25:35 <AnMaster> oklopol, care to show the code?
23:25:39 <AnMaster> and in what language?
23:25:40 <oklopol> k
23:25:42 <oklopol> python
23:25:47 <AnMaster> forget it then
23:26:17 <oklopol> http://www.vjn.fi/pb/p531644464.txt
23:26:37 <oklopol> it's prolly like O(lg lg n), but it doesn't use any stack, just a few numbers
23:26:44 <oklopol> dunno
23:27:59 <ehird> oklopol: wow
23:28:38 <oklopol> ehird: now that i understood "asme" in fact means "same", i can answer: indeed, it's definitely not O(1) space then, i need bignums for the length of the list, and the length can be like a quasimagrillion.
23:28:56 <oklopol> ehird: wow as in, CAN PYTHON ACTUALLY BE RAPED THAT BADLY?!?!?
23:28:59 <oklopol> or what :P
23:29:19 <oklopol> skipiter was the hard part
23:30:23 <oklopol> uses O(lg n) space, for a few numbers that is, to get the sequence 0 -> 101 -> 2120212 -> 323132303231323, which i use to get jumps right when traversing the sublists when i've "recursed" onto another level
23:30:28 <oklopol> god i'm bad at explaining this
23:30:54 <oklopol> wish i owned at math, could just prove it, and tell ppl to fuck themselves if they asked for an explanation.
23:30:59 <oklopol> :P
23:34:35 <olsner> I would have attempted an analysis if it wasn't written in python
23:34:41 <oklopol> hmm
23:34:45 <oklopol> what language do you want?
23:34:51 <oklopol> i can rewrite
23:34:58 -!- Deformative has quit (Remote closed the connection).
23:35:27 <olsner> nah, don't bother
23:35:44 <oklopol> (just needs to support mutable lists of course)
23:36:19 <oklopol> (or it'll trivially be at least O(n) space)
23:36:48 <oklopol> olsner: so basically you don't want to, and this was just an excuse? :P
23:36:59 <olsner> something like that, yeah
23:36:59 <oklopol> my time is worthless!
23:37:04 <oklopol> :DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD
23:37:20 <AnMaster> oklopol, C
23:37:23 <AnMaster> rewrite it in C
23:37:36 <oklopol> the problem with C is, i actually need bignums.
23:37:39 <oklopol> well
23:37:39 <AnMaster> -std=c99 -pedantic -Wall -Wextra -Werror
23:37:43 <oklopol> not really
23:37:57 <AnMaster> actually I use more, too many to paste here
23:38:07 <oklopol> because if a list fits into memory, the pointer size is enough for me
23:38:24 <AnMaster> http://rafb.net/p/326SMd71.html
23:38:33 <AnMaster> that is from my cmake file for a project
23:38:51 <oklopol> i think i could do a fairly straightforward translation from python to C here, if it weren't for that one generator
23:39:18 <oklopol> but it's fairly simple, i now realize, to non-generatorize it
23:40:09 <oklopol> perhaps i'll do it tonight, after my daily south park session
23:40:21 <AnMaster> oklopol, size_t for memory
23:40:25 <AnMaster> I got 64-bit :)
23:40:54 <oklopol> i think the biggest problem will be to get a C compiler to work
23:41:21 <ehird> oklopol: lunix?
23:41:28 <ehird> debian/ewwbuntoo:
23:41:28 <oklopol> as many here already know, i'm the biggest retard in the world when it comes to installing software.
23:41:32 <oklopol> ehird: sadly, no
23:41:33 <ehird> sudo apt-get install build-essential
23:41:36 <olsner> wow, that's a crazy set of warning options! witness of the unsafe properties of C :P
23:41:38 <ehird> oh darn
23:41:39 <ehird> what then
23:41:44 <oklopol> guess ;)
23:41:51 <ehird> cygwin
23:41:53 <ehird> cygwin is yer friend
23:41:55 <ehird> it comes with gcc
23:42:12 <olsner> or mingw
23:42:13 <AnMaster> olsner, hah
23:42:49 <ehird> cygwinnnn
23:42:50 <AnMaster> olsner, don't forget the *need* for valgrind
23:42:53 <oklopol> ehird: perhaps
23:42:58 <AnMaster> ehird, cygfail?
23:43:13 <olsner> AnMaster: well, if you're on windows you can just compile, test and pray
23:43:35 <AnMaster> olsner, I'm not on windows
23:43:46 <AnMaster> I'm on Gentoo Linux x86_64
23:43:47 <AnMaster> :)
23:45:32 <AnMaster> olsner, so what do you use to detect memleaks in windows software?
23:45:39 <olsner> I'm also on linux at home; but not at work since certain of our target platforms have developer tools that are windows-only
23:46:16 <AnMaster> olsner, sure GCC can't compile to those platforms?
23:47:11 <pikhq> Here's a hint: GCC targets *everything*.
23:47:16 <olsner> it can, but produces bigger binaries and requires hacking linker scripts etc no-one's had time to perform
23:47:21 <AnMaster> pikhq, exactly
23:47:33 <pikhq> Hell, I can get GCC to target a fucking PDP-11.
23:47:35 <AnMaster> pikhq, apart from h8300, iirc that port is dead since about gcc 2.95
23:47:39 <AnMaster> or something like that
23:47:54 -!- nice_ka has left (?).
23:47:56 <AnMaster> I wanted to cross compile to it recently
23:47:59 <pikhq> AnMaster: Doesn't mean I can't get GCC to target one.
23:48:11 <pikhq> Granted, porting from 2.95 would be a royal pain.
23:48:20 <AnMaster> pikhq, 8 bit CPU
23:48:24 <pikhq> (did they even use RTL then?)
23:48:25 <ehird> pikhq: if you write a backend, it will compile!
23:48:27 <ehird> wowz
23:48:53 <AnMaster> pikhq, used in some products by Lego
23:48:59 <AnMaster> yeah in toys
23:54:46 -!- Deformati has quit (Remote closed the connection).
23:58:15 -!- Deformative has joined.
←2008-03-28 2008-03-29 2008-03-30→ ↑2008 ↑all