Skip to content

Commit

Permalink
Setprecision
Browse files Browse the repository at this point in the history
  • Loading branch information
SingularityT3 committed Nov 4, 2023
1 parent a81f8b1 commit 5fb48a7
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/psc/types/numeric.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#include "pch.h"

#include <math.h>
#include <format>
#include "psc/types/types.h"

using namespace PSC;
Expand Down Expand Up @@ -414,7 +413,7 @@ std::unique_ptr<String> Real::toString() const {
}

void Real::dump(std::ostream &out) const {
out << "REAL " << std::format("{}", value);
out << "REAL " << std::setprecision(std::numeric_limits<real_t>::digits10+2) << value;
}

bool Real::load(std::istream &in, Context&) {
Expand Down

0 comments on commit 5fb48a7

Please sign in to comment.