You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(feature request)
It would be nice to have a way to seperate code into files.
For example, i would make a subfolder in the BF-it folder with my code's name (let's say the name is calculator), and put multiple *.code files inside, with one called main.code
If a *.code file required another file, it would have a line that'll be like this: #import calculation.code (using .code in the line could be optional)
When it will import another file, every variable and function that is inside the file will be copied, for example:
inside calculation.code:
int square(int a){
return a*a;
}
inside main.code:
#import calculation.code
int sqresult=0;
int num=0;
void main(){
print("Enter a number...");
num = readint();
sqresult = calculation.square(num);
print("The number ");
printint(num);
print(" squared is equal to ");
printint(sqresult);
print(".\n");
}
What would be also nice is to be able to insert BrainF code at compile time, for example:
int res = 0;
void main(){
res = insert("++++[>++++++++<-]>[<+>-]<");
if(res==32){
print("BrainF insert success")
} else {
print("Error, res = ");
printint(res);
print(" and not 32.")
}
}
(if you ever implement this, is it possible that you don't make it remove comments? thanks!)
The text was updated successfully, but these errors were encountered:
(feature request)
It would be nice to have a way to seperate code into files.
For example, i would make a subfolder in the BF-it folder with my code's name (let's say the name is
calculator
), and put multiple *.code files inside, with one calledmain.code
If a *.code file required another file, it would have a line that'll be like this:
#import calculation.code
(using.code
in the line could be optional)When it will import another file, every variable and function that is inside the file will be copied, for example:
inside
calculation.code
:inside
main.code
:What would be also nice is to be able to insert BrainF code at compile time, for example:
(if you ever implement this, is it possible that you don't make it remove comments? thanks!)
The text was updated successfully, but these errors were encountered: