3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-05-11 09:44:43 +00:00

Added braces

Lack of braces on multi-line statements is considered very scary in
Java.
This commit is contained in:
George Karpenkov 2016-01-06 11:14:53 +01:00
parent ccd88a63a5
commit c435bc379b
8 changed files with 84 additions and 68 deletions

View file

@ -53,15 +53,10 @@ public class AST extends Z3Object implements Comparable<AST>
@Override
public int compareTo(AST other)
{
if (other == null)
if (other == null) {
return 1;
if (getId() < other.getId())
return -1;
else if (getId() > other.getId())
return +1;
else
return 0;
}
return Integer.compare(getId(), other.getId());
}
/**
@ -94,11 +89,12 @@ public class AST extends Z3Object implements Comparable<AST>
public AST translate(Context ctx)
{
if (getContext() == ctx)
if (getContext() == ctx) {
return this;
else
} else {
return new AST(ctx, Native.translate(getContext().nCtx(),
getNativeObject(), ctx.nCtx()));
getNativeObject(), ctx.nCtx()));
}
}
/**