aboutsummaryrefslogtreecommitdiffstats
path: root/examples/Kaleidoscope/Chapter3/toy.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/Kaleidoscope/Chapter3/toy.cpp')
-rw-r--r--examples/Kaleidoscope/Chapter3/toy.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/Kaleidoscope/Chapter3/toy.cpp b/examples/Kaleidoscope/Chapter3/toy.cpp
index 04a1e1a..c60f767 100644
--- a/examples/Kaleidoscope/Chapter3/toy.cpp
+++ b/examples/Kaleidoscope/Chapter3/toy.cpp
@@ -93,7 +93,7 @@ class NumberExprAST : public ExprAST {
double Val;
public:
NumberExprAST(double val) : Val(val) {}
- virtual Value *Codegen();
+ Value *Codegen() override;
};
/// VariableExprAST - Expression class for referencing a variable, like "a".
@@ -101,7 +101,7 @@ class VariableExprAST : public ExprAST {
std::string Name;
public:
VariableExprAST(const std::string &name) : Name(name) {}
- virtual Value *Codegen();
+ Value *Codegen() override;
};
/// BinaryExprAST - Expression class for a binary operator.
@@ -111,7 +111,7 @@ class BinaryExprAST : public ExprAST {
public:
BinaryExprAST(char op, ExprAST *lhs, ExprAST *rhs)
: Op(op), LHS(lhs), RHS(rhs) {}
- virtual Value *Codegen();
+ Value *Codegen() override;
};
/// CallExprAST - Expression class for function calls.
@@ -121,7 +121,7 @@ class CallExprAST : public ExprAST {
public:
CallExprAST(const std::string &callee, std::vector<ExprAST*> &args)
: Callee(callee), Args(args) {}
- virtual Value *Codegen();
+ Value *Codegen() override;
};
/// PrototypeAST - This class represents the "prototype" for a function,