Compare commits
No commits in common. "b84ad2ef6baed378d4437a11a3508e16bc86f164" and "ed2f64eff906af670edc1e7a9d26fb6138c95ee0" have entirely different histories.
b84ad2ef6b
...
ed2f64eff9
@ -15,8 +15,8 @@ import java.util.Objects;
|
||||
|
||||
public class UnaryExpression extends AbstractType implements IExpression{
|
||||
public String operator;
|
||||
public IExpression operand;
|
||||
public UnaryExpression(String operator, IExpression operand){
|
||||
public IDatatype operand;
|
||||
public UnaryExpression(String operator, IDatatype operand){
|
||||
this.operator = operator;
|
||||
this.operand = operand;
|
||||
}
|
||||
|
@ -271,8 +271,7 @@ public class ASTGenerator extends DecafBaseVisitor<Node> {
|
||||
} else if (ctx.value() != null) {
|
||||
return visitValue(ctx.value());
|
||||
} else if (ctx.binaryExpr() != null) {
|
||||
IExpression expression = (IExpression) visit(ctx.binaryExpr());
|
||||
return new UnaryExpression("!", expression);
|
||||
//todo
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user