mirror of
https://github.com/Z3Prover/z3
synced 2025-12-15 08:48:58 +00:00
Logic simplifications
There is no point in writing "boolean ? true : false" instead of "boolean"
This commit is contained in:
parent
52fdf73178
commit
a816b4895c
7 changed files with 21 additions and 22 deletions
|
|
@ -36,7 +36,7 @@ public class IntNum extends IntExpr
|
|||
public int getInt()
|
||||
{
|
||||
Native.IntPtr res = new Native.IntPtr();
|
||||
if (Native.getNumeralInt(getContext().nCtx(), getNativeObject(), res) ^ true)
|
||||
if (!Native.getNumeralInt(getContext().nCtx(), getNativeObject(), res))
|
||||
throw new Z3Exception("Numeral is not an int");
|
||||
return res.value;
|
||||
}
|
||||
|
|
@ -47,7 +47,7 @@ public class IntNum extends IntExpr
|
|||
public long getInt64()
|
||||
{
|
||||
Native.LongPtr res = new Native.LongPtr();
|
||||
if (Native.getNumeralInt64(getContext().nCtx(), getNativeObject(), res) ^ true)
|
||||
if (!Native.getNumeralInt64(getContext().nCtx(), getNativeObject(), res))
|
||||
throw new Z3Exception("Numeral is not an int64");
|
||||
return res.value;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue