« first day    last day (17 days later) » 

1:00 AM
you don't have to program python
@Downgoat you do not have to use python, as the python just interprets the bf code
@Downgoat I invited you, you do not have to program in python
click the link by the room name pls
 
1:29 AM
:D Joinied
 
@Downgoat I was thinking about adding a random command to bf
how do you make a random integer command into a random bits thing?
like if I wanted to make a randint function while only using random.randint(0,1) in the definition?
 
oh i see how this works
@DestructibleLemon yea i guess good idea otherwise won't be able to add later
 
yup. any other things that would be difficult to add later that is a good idea?
 
I think directly being able to interface memory would be good idea
 
what do you mean?
I don't want to over load this with a bunch of things. it doesn't need to be super functional
I don't think that adding super many features like file system is necessary
randomness is just fun in a lot of circumstances
 
 
1 hour later…
2:58 AM
@ATaco
also the InterBF spec is not made, but it is BF:
with interactive io as you suggested
and randomness works like this
take value of cell pointer is on
cell = random.randint(0, cellvalue)
so if the cell was 1, you get a random bit
@ATaco please talk to me in this chat
 
I have returned.
 
I'm not sure of which language to compile, but this next step will definitely take the longest.
 
You can come up with one yourself. it doesn't need to be particularly
 
I don't have to write the compiler in BF, correct?
 
3:11 AM
you do
oh right I probably should have considered how difficult that is :P
rip you
 
So I need to write an InterBF script, which compiles a higher level language, to InterBF.
 
mmhm. doesn't need to be higher level but it probably will be
 
Well this is going to take a long time
It would have probably been better to host this on ide.c9
 
yeah I kind of messed up huh?
@ATaco cloud 9 is bs
 
Ah, don't have a Debit card?
 
3:13 AM
mm
well, the first thing is deciding what you are going to have in the language
 
Well the first thing I'm going to do is make an entirely new method of data storage.
 
actually we should probably work together on the first one
 
If we can't code at the same time, this will be too difficult.
 
hmm, so it is a good idea to remember you don't have to use all the possible values in bf
I mean, you can use some of them as EOF
codeanywhere?
so, I'm thinking that we can use 255 as the leftmost cell
if you would want to
 
Do I have inifinite left-right memory?
 
3:16 AM
sorry, only infinite right
but you can split it
by using every second cell etc.
 
You sadden me with your pythonic norms.
 
hey
you stink
 
[TAG NIL]
[TAG BYTE][BYTE]
[TAG STRING]([RAIL][BYTE])*[FALSEY_RAIL]
[TAG ARRAY]([TAG VAR]...)*[TAG NIL]
 
ok, so I think we should stick with bf loops at this point
 
Theoretical memory storage of various variales.
 
3:18 AM
ok, but maybe you should make this later
we're bootstrapping here
 
Can't I make a language with more than just bytes as the next step?
The main issue with this memory system, is that it uses dynamically sized variables, so they can run out of space.
 
I think we should make the stack based thing first
because it can be rather difficult to change paradigm when using bf
I was also thinking of arbitrarily sized numbers
 
Yeah that's not happening.
 
ok. so we need to figure out what things we're having in this lang
 
Making a stack in BF doesn't lend too well to dynamically sized variables.
 
3:21 AM
hey, EOF values!
 
That's not the issue.
 
ok ok ok, we'll do arbitrary next step?
ok, so what features should this lang have: so far, I'm thinking bf like loops
and addition
and equality checks
 
You gotta think bigger.
 
yup
but you gotta think small steps
 
I'm just gonna work on my thing, think about the memory first....
 
3:24 AM
I think I'll work on this stack based thing then maybe?
I really should have gone for something more expressive, huh?
 
I'm gonna start by writing a compiler in something that isn't bf, it'll be generally easier on me.
 
you could do that
i messed up.
 
How so?
 
I picked bf
 
If we have a higher level language, it'll be easier to go from there
 
3:39 AM
I wouldn't mind as much if I didn't have to write the compiler in BF.
 
3:51 AM
I've almost got stack based memory working!
@DestructibleLemon now I Actually have stack based memory working. Horrah.
And I still have an excuse to use my rails!
The cat script, "READ WHILE WRITE READ END" (WIP tokens) compiles to +>>+<>>>+>,[.>>>+>,]
Who needs optimization anyway?
@DestructibleLemon I hope you weren't expecting programs to stay compact.
8 - 3 is "3 FLIP 8 SUB", which compiles to the nice and small +>>+<>>>+>+++>[>>>>]-[+<<<<-]+>>>>+>++++++++>[>>>>]-[+<<<<-]+>[->>>+>+<<<<]>>>[‌​-<<<+>>>]+>>[>>>>]-[+<<<<-]+>>>>+>>[>>>>]-[+<<<<-]+><->[->[>>>>]-[+<<<<-]+>+>[>>>‌​>]-[+<<<<-]+>>>>>]>[>>>>]-[+<<<<-]+>[-<<<<->>>>]<-<<<.
 
4:22 AM
I definitely was not
the good thing is, I optimise things where they have a bunch of ><+-s in a row
@ATaco are you still here?
 
Yeah
 
ok cool
so, you put it on the github yet?
Also I need to know how it works maybe
 
Yeah, not just yet.
I need to finish it, and besides, it's not written in BF yet.
 
so, WIP tokens?
maybe use single characters I guess
 
Yeah, that's probably for the best.
 
4:26 AM
ok, this is good work you have done I think
also I'm not incredibly confident my bf interpreter works
so if you get any bugs from it, tell me
@ATaco this sounds like you were making a pun
also i need you to explain the process in this to me maybe
 
Maybe.
 
yeah, I do get the feeling that the end product in bf is going to be super inefficient when we get an actually long chain going
 
Oh it will be.
One must suffer for art.
The compiler itself is rather simple.
It's just converting tokens to predefined strings.
 
wait, I just realised numbers might be annoying for single character tokens
 
Annoying, but not impossible.
 
4:30 AM
oh I guess numbers are one digit only?
or something?
 
1 digit then do some math
or use the token N and read the next byte.
 
mhm
both those work nicely
remember to implement randomness
you need to be able to generate at least one random bit at a time
optionally you can generate a random number between any bounds
 
What is the random number command in our BF?
 
And how does it work?
 
4:34 AM
scroll to the top of this chat pls
 
The amount of content loaded is clientside
 
2 hours ago, by Destructible Lemon
@ATaco
click that 2 hours ago link
 
Well, I can work with that.
 
what does flip do?
 
Switches stack.
 
4:40 AM
o ok
@ATaco Remember that a bunch of +s in a row is actually really efficient in my interpreter
 
That's great.
 
of course, a bunch of pluses is likely to be more efficient than a loop in most interpreters
except a bf interpreter
but it is actually efficient because it groups all the pluses together
you will probably get a very large compiler doing it that way but that matters little I think
Also you probably need to give your lang a name
like, (S)Taco
or something
 
So the way this compiler works most importantly is how it handles memory. Memory is split into two stacks with arbitray polarity, each stack is defined by groups of rail bits, then it's data byte, then a gap of two for the other stack to sit on. The rail bits exist to find the end of the stack again, this is important when switching stack.
 
good
so, do we know this is TC @ATaco
 
4:56 AM
To my knowledge yes.
You could probably transpile BF fairly easily.
 
am gonna have to ask that you prove that
 
, = READ
. = WRITE
+ = INC
- = DEC
[ = WHILE
] = END
> = MOVE FLIP
< = FLIP MOVE
Assuming I fix the fact that you can't pop an empty stack...
What happens if you do < when the cell pointer is already at 0?
 
error probably
it is undefined behaviour
however, if you immediately move back on without doing anything it won't error
 
Eh, I'm a smart taco, I know a way around it.
 
5:12 AM
Isn't there a push to stack command?
also I want an explanation of how it works pls
like all the commands
 
Yeah how about I write it first?
 
I'm also trying to do the job that I get paid to do here, cut me some slack.
 
6:01 AM
Alright, I fixed pop and thus made it turing complete.
 
6:16 AM
Alright, it's definitely turing complete.
^That's a cat program compiled, then the compiled code is transpiled to the language, and compiled again. @DestructibleLemon
 
nice
btw I'm back now but I won't be for long
good work taco
 
Fun fact, interpreting brainfuck this way gives you infinite cells in both directions.
 
also I'm gonna post that cat program in tnb
 
Thanks to the simple fact that 2inf = inf
 
@ATaco wait, so you made two languages already?
:P
 
6:28 AM
Only technically.
I still haven't compiled the compiler to BF.
 
ok then. again, you can use a bunch of pluses and minuses etc. you don't need to keep values on cells for efficiency, because it won't be much of a speed boost
@ATaco I forgot, you have to end the interbf program with !
just because of the way I made the interpreter
actually wait nvm, not necessarily
but do it anyway
 
Why?!
 
well
it makes the programs more surprising
also so you can do multiline programs
 
Trust me, I'm surprised.
 
but when you import the interpreter, you don't need to do that
but it would be better if you did it anyway
 
6:34 AM
No no, this is definitely an issue with the implementation
I'm not appending a ! because of dodgy implementation
 
hey now
there is no need to be rude
ok so, if you made a program that outputs a program, right?
you wouldn't want to put it into a file each time, you would want to copy and paste it?
 
"It should be simple to append a !"
 
but if you copy and paste it, you need eof
@ATaco it should be!
 
Why does it need an EOF?!
 
because of support for multiline programs!
and EOF byte is annoying to do for some peoplr
 
6:37 AM
Needing an EOF does not in anyway break support for multiline programs.
 
I know. ! is eof
 
Or, not needing, rather
 
I have to separate the input program and the input to the program
 
Oh no...
You're reading the code from STDIN... Aren't you...
 
yes
because it fits with the way that you copy and paste stuff
it made more sense to me than copy and pasting into a bunch of different files I guess
also consistency
 
6:40 AM
I do not like this implementation, Sam I am.
 
All the other things read from stdin, so the last layer probably should as well
 
A compiler and an interpreter are very different for this very reason.
 
I guess I would cede and change the implementation. but I still haven't quite figured out command line arguments tbh
anyway, I have the sadflak interpreter I can use, because dennis made a thing for that so it works with command line arguments
will change later, because my mum is bugging me about this
and going on a walk
 
We wouldn't have problems if we wrote this in JS
 
jeez
how would my mum be more receptive to programming in JS?
:P
 
6:45 AM
If front end developers can do it!
 
ok done
I think
will push
are ya happy?
 
Technically.
 
7:11 AM
@DestructibleLemon I don't have commit privledges on the Git.
 
wah
how make it
 
I have no idea
 
done
you have commit priviliges
but I want to see a bf compiler!
shouldn't be too difficult to make an autogenerator?
 
7:20 AM
It shouldn't, but I need to do some thinking as to how to handle strings in BF, because strings.
 
also what if one stack is longer than the other when you try to do flip for example? or is there something I am missing
@ATaco what is the problem with strings?
 
7:35 AM
@DestructibleLemon flip detects the end of the other stack and moves to it, it's why compiled code becomes as large as it does. That and pop checking if it's reached the end of the stack
Also, comparing two characters and acting acordingly is the bane of my existence
 
8:16 AM
@ATaco Character1 - Character 2: is it 0?
 
8:57 AM
although TBH I don't really know bf well enough to know how to do something iff a cell is 0
actually, just refer to this article
it is pretty cool
 
9:41 AM
no offence but your lua and bf code does not lend itself to readability, so I will probably need an explanation of it
 
10:35 AM
ok, I may or may not attempt this? IDK
 
10:46 AM
I was thinking I would just use whatever symbols
 
11:06 AM
I have begun work!
@TwiNight how much of a lurker are you?
659 days is a long time to go without talking
 
Nah I just followed a link to this chat room
Haven't done codegolfing for quite a while
 
ok. well, I'm remembering why bf is difficult at the moment
 
11:33 AM
@totallyhuman are you interested?
 
 
3 hours later…
2:11 PM
I programmed the compiler but it doesn't work
so ehh
I will finish it soon maybe?
 
> Wot u do:
such spelling, much wow
 
 
9 hours later…
11:43 PM
I BELIEVE THAT THE GOAL HAS BEEN REACHED
,[-1]
+++++ +++++ +++++ +++++ +++++ +++++
+++++ +++++ +++++ +++++ +++++ +++++ ++
....
----- ----- ----- ----
.
+++++ +++++ +++++ ++++
..
----- ----- ----- ----
.
+++++ +++++ +++++ ++++
.
>[we just printed ">>>>+>>+>"]<
commands (ask ataco what these commands do; I have little clue about the less obvious ones):
pop: !
flip: "
peek: #
while: (
end: )
write: <period>
rand: <question mark>
dec: <minus>
inc: <plus>
zero: *
stackadd: $
stacksub: '
move: /
copy: &
read: <comma>
0123456789: push that number on to the stack
IT IS VERY LARGE
I AM VERY PROUD OF MYSELF RIGHT NOW
 
Your uh, Brainfuck doesn't seem to work.
@DestructibleLemon
 

« first day    last day (17 days later) »