attila_lendvai has quit [Ping timeout: 272 seconds]
random-nick has quit [Ping timeout: 252 seconds]
brokkoli_origin has quit [Ping timeout: 252 seconds]
brokkoli_origin has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
decweb has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
decweb has quit [Ping timeout: 260 seconds]
kevingal has quit [Ping timeout: 248 seconds]
kiyafirs has joined #commonlisp
fe[nl]ix has quit [Remote host closed the connection]
decweb has joined #commonlisp
fe[nl]ix has joined #commonlisp
anticomputer has quit [Remote host closed the connection]
bjorkintosh has joined #commonlisp
bjorkintosh has joined #commonlisp
chops_ has quit [Ping timeout: 246 seconds]
decweb has quit [Ping timeout: 252 seconds]
anticomputer has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
vardhan_ has joined #commonlisp
chops_ has quit [Ping timeout: 248 seconds]
decweb has joined #commonlisp
decweb has quit [Ping timeout: 276 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
rkazak has quit [Changing host]
rkazak has joined #commonlisp
chops_ has quit [Ping timeout: 276 seconds]
amb007 has joined #commonlisp
amb007 has quit [Ping timeout: 265 seconds]
Pixel_Outlaw has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
decweb has joined #commonlisp
chops_ has quit [Ping timeout: 252 seconds]
jon_atack has joined #commonlisp
jonatack has quit [Ping timeout: 244 seconds]
decweb has quit [Ping timeout: 252 seconds]
chops_ has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
brokkoli_origin has quit [Ping timeout: 265 seconds]
brokkoli_originl has joined #commonlisp
chops_ has quit [Ping timeout: 246 seconds]
triffid has quit [Quit: triffid]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
shmorg83 has joined #commonlisp
chops_ has quit [Ping timeout: 252 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
shmorg83 has quit [Ping timeout: 265 seconds]
chops_ has quit [Ping timeout: 276 seconds]
gorignak has quit [Quit: quit]
gorignak has joined #commonlisp
decweb has joined #commonlisp
bjorkintosh has quit [Ping timeout: 260 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 252 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
rkazak has quit [Ping timeout: 252 seconds]
chops_ has quit [Ping timeout: 260 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
decweb has quit [Ping timeout: 276 seconds]
rkazak has joined #commonlisp
<beach>
srji: This mechanism also simplifies the code when you might otherwise evaluate some code twice. Consider (push 234 (car (f x))).
<beach>
Without this mechanism, you might write (set-car (f x) (cons 234 (f x))), but then you would evaluate (f x) twice which is not desirable. So you would have to write (let ((mumble (f x))) (set-car mumble (cons 234 mumble))).
<beach>
With this mechanism, you can write (push 234 (car (f x))) and the system takes care of evaluating (f x) just once.
rkazak has quit [Ping timeout: 265 seconds]
<beach>
srji: You can check this by looking at the macro expansion of the expression above: ,(macroexpand-1 '(push 234 (car (f x))))
<Pixel_Outlaw>
I wonder if most any Lisp program could be reduced to a single horrific PROG. :D
<Pixel_Outlaw>
That's be one hell of a compiler to write. :P
rkazak has quit [Ping timeout: 252 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
rkazak has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 246 seconds]
wacki has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
mange has quit [Remote host closed the connection]
chomwitt has joined #commonlisp
rkazak has quit [Ping timeout: 260 seconds]
amb007 has quit [Ping timeout: 245 seconds]
pve has joined #commonlisp
bendersteed has joined #commonlisp
treflip has joined #commonlisp
rkazak has joined #commonlisp
amb007 has joined #commonlisp
<shawnw>
I wrote a brainfuck to common lisp compiler that turned programs into a single horrific tagbody. Does that count?
<shawnw>
(sbcl would die horribly when trying to compile anything non-trivial)
shka has joined #commonlisp
rkazak has quit [Ping timeout: 260 seconds]
<Pixel_Outlaw>
shawnw, I think that's on PAR. :)
<aeth>
tagbody? odd... brainfuck really isn't a language with GOTOs, which is one of the reasons why it's so difficult (probably best to turn it into a stack or register machine by bringing the whole world with you as you move down the tape, but it's not free)
<aeth>
seems to more naturaly map to AREFs and storing a current index into that AREF
<aeth>
s/the whole world/the whole stack or register set/
rkazak has joined #commonlisp
Th30n has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
drbdf has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
King_julian has joined #commonlisp
rkazak has quit [Ping timeout: 245 seconds]
mishoo has joined #commonlisp
pkal has quit [Read error: Connection reset by peer]
pkal has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
mgl has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
akoana has quit [Ping timeout: 276 seconds]
<shawnw>
bf totally has gotos - all the jumps forward and backward.
chops_ has quit [Ping timeout: 260 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
<aeth>
no, those are positions on the mutable tape, which are probably best seen as INCF/DECF in CL
<aeth>
typically with a MOD wraparound so not quite as simple (you'd really want an e.g. INCF-MOD)
<aeth>
and so don't really map cleanly to a tagbody because you never have an absolute address like a GOTO, including a GO in CL
chops_ has quit [Ping timeout: 260 seconds]
<aeth>
>>>> isn't (go 3) or (go 4) depending on 0-based or not... it's advance 4 from your relative position, whose absolute position you'll never know unless you find a way to track it (and you have to store it somehow! and bring it with you since you can only move relatively!)... and even if it was a goto, how do you mutate the contents that that goto returns? Recompile the form? That really would count as a
<aeth>
horrible compilation, but CL lets you do it, I guess
<Pixel_Outlaw>
I'm having a bit of trouble modularizing part of my code. I think it has something do do with LOOP's expansion.
treflip` has joined #commonlisp
<Pixel_Outlaw>
I'll post on pastebin if anyone can give me a second set of eyes.
treflip has quit [Ping timeout: 252 seconds]
treflip` has quit [Remote host closed the connection]
<Pixel_Outlaw>
I don't like my monolithic infix-to-RPN function so I was trying to break out sections 101 and 114. However when I abstract them into accessory functions they act different.
<ixelp>
;;;; shunting.lisp(in-package #:shunting);; wikipedia https://en.wikiped - Pastebin.com
<Pixel_Outlaw>
I get extra operators which is odd.
treflip` has joined #commonlisp
<Pixel_Outlaw>
I wonder if it's due to the way LOOP expands...
<Alfr>
aeth, but the program isn't mutable.
<Alfr>
So, if you keep the data pointer, you could translate [ and ] to branch to corresponding tag if 0.
<Alfr>
... that is, assigning tags to each [ and ].
<Alfr>
Oh, this isn't the cafe. Sorry.
<aeth>
Alfr: oh, GOTOs on the []s... well, yes, that's trivial from the fact that CL (probably; I don't think it's mandated) implements iteration that way, whether you do it directly or not
<aeth>
although you could do tail recursion
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
treflip` has quit [Changing host]
treflip` has joined #commonlisp
Pixel_Outlaw has quit [Quit: Leaving]
rkazak has joined #commonlisp
chops_ has quit [Ping timeout: 276 seconds]
King_julian has quit [Ping timeout: 260 seconds]
rkazak has quit [Ping timeout: 246 seconds]
szkl has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
mishoo has quit [Ping timeout: 260 seconds]
treflip` has left #commonlisp [ERC 5.5.0.29.1 (IRC client for GNU Emacs 29.4)]
<shawnw>
Oh, it had lots of incf/decf calls too.
chops_ has quit [Ping timeout: 260 seconds]
rkazak has joined #commonlisp
chiselfuse has quit [Ping timeout: 264 seconds]
<shawnw>
You can work out the locations of all jumps in bf ahead of time. They're absolutely absolute.
<shawnw>
It's not a self-modifying language and doesn't have computed jumps, just conditional ones.
rainthree33 has joined #commonlisp
King_julian has joined #commonlisp
rkazak has quit [Ping timeout: 245 seconds]
<shawnw>
(Never did get around to optimizing runs of +/- into a single addition/subtraction. That would shrink the size of a compiled program considerably)
<aeth>
the problem with implementing Brainfuck is that you could optimize it all day, and then write clever programs on top of it, especially with extensions, etc,. etc., and yet at the end of the day, it is very time consuming time that probably should be spent on more useful CL libraries
<aeth>
at least, that's why I stopped dabbling in it
<shawnw>
Eh, it's fun.
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
kamafam has quit [Ping timeout: 252 seconds]
<aeth>
same reason I avoid programming puzzles e.g. Advent of Code and Project Euler
<shawnw>
Those are also fun. Until they're not.
mishoo has joined #commonlisp
chops_ has quit [Ping timeout: 276 seconds]
<aeth>
usually winds up with writing a library to solve particular types of problems faster
rkazak has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
prokhor_ has joined #commonlisp
prokhor has quit [Ping timeout: 244 seconds]
mooseball has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
dino_tutter has joined #commonlisp
rainthree33 has quit [Ping timeout: 265 seconds]
rkazak has quit [Ping timeout: 246 seconds]
chops_ has quit [Ping timeout: 276 seconds]
kamafam has joined #commonlisp
King_julian has quit [Ping timeout: 245 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
rainthree33 has joined #commonlisp
trocado has quit [Ping timeout: 246 seconds]
chops_ has quit [Ping timeout: 252 seconds]
edgar-rft_ has quit [Quit: don't waste your life by reading this]
alternateved has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
rkazak has joined #commonlisp
chops_ has quit [Remote host closed the connection]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
JuanDaugherty has joined #commonlisp
chops_ has quit [Ping timeout: 252 seconds]
chomwitt has quit [Ping timeout: 265 seconds]
Guest89 has joined #commonlisp
rkazak has quit [Ping timeout: 245 seconds]
Guest89 has quit [Client Quit]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
King_julian has joined #commonlisp
rkazak has joined #commonlisp
mgl has quit [Ping timeout: 244 seconds]
rkazak has quit [Ping timeout: 260 seconds]
cage has joined #commonlisp
cage has quit [Excess Flood]
cage has joined #commonlisp
varjag has joined #commonlisp
mgl has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
rkazak has joined #commonlisp
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 248 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Ping timeout: 260 seconds]
mooseball has quit [Read error: Connection reset by peer]
rkazak has quit [Ping timeout: 244 seconds]
chops_ has joined #commonlisp
chops_ has quit [Changing host]
chops_ has joined #commonlisp
chops_ has quit [Remote host closed the connection]