From b4a8005a31b8c0bf496d580888cce86cc8247911 Mon Sep 17 00:00:00 2001 From: rakomw Date: Tue, 27 Jul 2021 01:51:14 -0400 Subject: [PATCH] Use toPlainString() instead of toString() for decimals Prevents low-magnitude numbers from being converted to scientific notation --- SMT/src/org/smtlib/sexpr/Printer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SMT/src/org/smtlib/sexpr/Printer.java b/SMT/src/org/smtlib/sexpr/Printer.java index 1e11c57..61d7248 100644 --- a/SMT/src/org/smtlib/sexpr/Printer.java +++ b/SMT/src/org/smtlib/sexpr/Printer.java @@ -131,7 +131,7 @@ public Void visit(ISymbol e) throws IVisitor.VisitorException { // FIX - need s- /*@Nullable*/ @Override public Void visit(IDecimal e) throws IVisitor.VisitorException { - try { w.append(e.value().toString()); } catch (IOException ex) { throw new IVisitor.VisitorException(ex); } + try { w.append(e.value().toPlainString()); } catch (IOException ex) { throw new IVisitor.VisitorException(ex); } return null; }