Fixed exception and removed scripts
This commit is contained in:
6
make.sh
6
make.sh
@@ -1,6 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
IFLAGS="-I/usr/local/opt/llvm/include -I/opt/homebrew/opt/llvm/include"
|
|
||||||
LDFLAGS="-L/usr/local/opt/llvm/lib -L/opt/homebrew/opt/llvm/lib"
|
|
||||||
|
|
||||||
cc -g -std=c++17 -lc++ -lllvm -DLLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING=1 ${LDFLAGS} ${IFLAGS} src/*.cpp -o brb
|
|
||||||
@@ -149,10 +149,13 @@ string StatementReturn::toString(int indent) {
|
|||||||
string value;
|
string value;
|
||||||
for (int ind=0; ind<indent; ind++)
|
for (int ind=0; ind<indent; ind++)
|
||||||
value += " ";
|
value += " ";
|
||||||
value += "RETURN:\n";
|
value += "RETURN";
|
||||||
|
if (expression != nullptr) {
|
||||||
|
value += ":\n";
|
||||||
for (int ind=0; ind<indent+1; ind++)
|
for (int ind=0; ind<indent+1; ind++)
|
||||||
value += " ";
|
value += " ";
|
||||||
value += expression->toString(indent+1);
|
value += expression->toString(indent+1);
|
||||||
|
}
|
||||||
value += "\n";
|
value += "\n";
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -80,8 +80,8 @@ int main(int argc, char **argv) {
|
|||||||
module->print(llvm::outs(), nullptr);
|
module->print(llvm::outs(), nullptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
//CodeGenerator codeGenerator(module);
|
CodeGenerator codeGenerator(module);
|
||||||
//codeGenerator.generateObjectFile(outputKind);
|
codeGenerator.generateObjectFile(outputKind);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user