Skip to content

Commit

Permalink
code hygiene
Browse files Browse the repository at this point in the history
  • Loading branch information
Ravenwater committed Aug 13, 2024
1 parent db552b7 commit 8f88710
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion include/universal/number/dd/dd_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1058,7 +1058,7 @@ inline dd pown(dd const& a, int n) {
switch (N) {
case 0:
if (a.iszero()) {
// error("(dd_real::pown): Invalid argument.");
std::cerr << "pown: invalid argument\n";
errno = EDOM;
return dd(SpecificValue::qnan);
}
Expand Down
4 changes: 2 additions & 2 deletions include/universal/traits/dd_traits.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#pragma once
// lns_traits.hpp : traits for doubledouble (dd) arithmetic type
// dd_traits.hpp : traits for double-double (dd) arithmetic type
//
// Copyright (C) 2017 Stillwater Supercomputing, Inc.
// SPDX-License-Identifier: MIT
Expand All @@ -9,7 +9,7 @@

namespace sw { namespace universal {

// define a trait for doubledouble (dd) types
// define a trait for double-double (dd) type
template<typename _Ty>
struct is_dd_trait
: false_type
Expand Down
3 changes: 2 additions & 1 deletion include/universal/traits/metaprogramming.hpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#pragma once
// metaprogramming.hpp : meta-programming patterns
//
// Copyright (C) 2017-2021 Stillwater Supercomputing, Inc.
// Copyright (C) 2017 Stillwater Supercomputing, Inc.
// SPDX-License-Identifier: MIT
//
// This file is part of the universal numbers project, which is released under an MIT Open Source license.
#include <limits>
Expand Down
4 changes: 2 additions & 2 deletions static/dd/api/api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -285,8 +285,8 @@ try {
std::cout << "sw::universal::nextafter(dd(0), -std::numeric_limits<dd>::infinity()) : " << sw::universal::nextafter(dd(0), -std::numeric_limits<dd>::infinity()) << "\n";
std::cout << "std::nextafter(float(0), -std::numeric_limits<float>::infinity()) : " << std::nextafter(float(0), -std::numeric_limits<float>::infinity()) << "\n";

std::cout << "cfloat(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_QUIET) : " << dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_QUIET) << "\n";
std::cout << "cfloat(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_SIGNALLING) : " << dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_SIGNALLING) << "\n";
std::cout << "dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_QUIET) : " << dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_QUIET) << "\n";
std::cout << "dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_SIGNALLING) : " << dd(std::numeric_limits<float>::signaling_NaN()).isnan(sw::universal::NAN_TYPE_SIGNALLING) << "\n";
}

ReportTestSuiteResults(test_suite, nrOfFailedTestCases);
Expand Down

0 comments on commit 8f88710

Please sign in to comment.