diff --git a/CHANGELOG.md b/CHANGELOG.md index 7b62ac14c2..235542b9a6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,6 +26,8 @@ - [#464](http://github.com/Nelson-numerical-software/nelson/issues/464): simplify macos build (catalina & BigSur support only). +- [#499](http://github.com/Nelson-numerical-software/nelson/issues/499): rename `getContentAsUnsignedInt64Scalar` to `getContentAsUnsignedInteger64Scalar`. + - [#495](http://github.com/Nelson-numerical-software/nelson/issues/495): some mtimes call failed. # 0.5.7 (2021-07-24) diff --git a/modules/assert_functions/src/cpp/Assert_IsEqual.cpp b/modules/assert_functions/src/cpp/Assert_IsEqual.cpp index eed8d583c8..5baf4f21aa 100644 --- a/modules/assert_functions/src/cpp/Assert_IsEqual.cpp +++ b/modules/assert_functions/src/cpp/Assert_IsEqual.cpp @@ -84,8 +84,8 @@ formatMessage(const ArrayOf& computedArray, const ArrayOf& expectedArray) std::to_wstring(expected).c_str(), std::to_wstring(computed).c_str()); } break; case NLS_UINT64: { - uint64 computed = ArrayOf(computedArray).getContentAsUnsignedInt64Scalar(); - uint64 expected = ArrayOf(expectedArray).getContentAsUnsignedInt64Scalar(); + uint64 computed = ArrayOf(computedArray).getContentAsUnsignedInteger64Scalar(); + uint64 expected = ArrayOf(expectedArray).getContentAsUnsignedInteger64Scalar(); message = StringFormat(_W("Assertion failed: expected (%ls) and computed (%ls) " "values are different.") .c_str(), diff --git a/modules/com_engine/src/cpp/VariantConversionHelpers.cpp b/modules/com_engine/src/cpp/VariantConversionHelpers.cpp index 7d20418218..a26fb54310 100644 --- a/modules/com_engine/src/cpp/VariantConversionHelpers.cpp +++ b/modules/com_engine/src/cpp/VariantConversionHelpers.cpp @@ -494,7 +494,7 @@ NelsonToComVariant(ArrayOf A, VARIANT* variant, std::wstring& errorMessage) return true; } break; case NLS_UINT64: { - uint64 r = A.getContentAsUnsignedInt64Scalar(); + uint64 r = A.getContentAsUnsignedInteger64Scalar(); variant->vt = VT_UI8; variant->llVal = r; return true; diff --git a/modules/elementary_functions/builtin/cpp/repmatBuiltin.cpp b/modules/elementary_functions/builtin/cpp/repmatBuiltin.cpp index c0a68763d3..1d312d643a 100644 --- a/modules/elementary_functions/builtin/cpp/repmatBuiltin.cpp +++ b/modules/elementary_functions/builtin/cpp/repmatBuiltin.cpp @@ -64,8 +64,8 @@ Nelson::ElementaryFunctionsGateway::repmatBuiltin( case 2: { ArrayOf param2 = argIn[1]; if (param2.isScalar()) { - repcount[0] = (indexType)param2.getContentAsUnsignedInt64Scalar(); - repcount[1] = (indexType)param2.getContentAsUnsignedInt64Scalar(); + repcount[0] = (indexType)param2.getContentAsUnsignedInteger64Scalar(); + repcount[1] = (indexType)param2.getContentAsUnsignedInteger64Scalar(); } else { if (param2.isRowVector()) { param2.promoteType(NLS_UINT64); @@ -84,7 +84,7 @@ Nelson::ElementaryFunctionsGateway::repmatBuiltin( default: { for (size_t k = 1; k < argIn.size(); ++k) { ArrayOf paramK = argIn[k]; - repcount[k - 1] = (indexType)paramK.getContentAsUnsignedInt64Scalar(); + repcount[k - 1] = (indexType)paramK.getContentAsUnsignedInteger64Scalar(); } } break; } diff --git a/modules/hdf5/src/cpp/h5Create.cpp b/modules/hdf5/src/cpp/h5Create.cpp index a67a38d4f7..1eccce4ea4 100644 --- a/modules/hdf5/src/cpp/h5Create.cpp +++ b/modules/hdf5/src/cpp/h5Create.cpp @@ -93,7 +93,7 @@ setFillValue(ArrayOf fillvalue, Class dataType, hid_t dcpl) } break; case NLS_UINT64: { hid_t fillType = H5T_STD_U64LE; - uint64 value = fillvalue.getContentAsUnsignedInt64Scalar(); + uint64 value = fillvalue.getContentAsUnsignedInteger64Scalar(); status = H5Pset_fill_value(dcpl, fillType, &value); } break; case NLS_UINT32: { diff --git a/modules/operators/src/cpp/Colon.cpp b/modules/operators/src/cpp/Colon.cpp index 71e1a465eb..0b9c4789ec 100644 --- a/modules/operators/src/cpp/Colon.cpp +++ b/modules/operators/src/cpp/Colon.cpp @@ -456,15 +456,15 @@ Colon(const ArrayOf& J, const ArrayOf& I, const ArrayOf& K, bool& needToOverload low = static_cast(1); high = static_cast(0); } else { - step = _I.getContentAsUnsignedInt64Scalar(true); + step = _I.getContentAsUnsignedInteger64Scalar(true); if (!_I.isScalar()) { warningArrayAsScalar = true; } - low = _J.getContentAsUnsignedInt64Scalar(true); + low = _J.getContentAsUnsignedInteger64Scalar(true); if (!_J.isScalar()) { warningArrayAsScalar = true; } - high = _K.getContentAsUnsignedInt64Scalar(true); + high = _K.getContentAsUnsignedInteger64Scalar(true); if (!_K.isScalar()) { warningArrayAsScalar = true; } diff --git a/modules/qml_engine/src/cpp/QVariantArrayOf.cpp b/modules/qml_engine/src/cpp/QVariantArrayOf.cpp index 900da46ffc..4684d26642 100644 --- a/modules/qml_engine/src/cpp/QVariantArrayOf.cpp +++ b/modules/qml_engine/src/cpp/QVariantArrayOf.cpp @@ -614,7 +614,7 @@ ArrayOfToQVariant(ArrayOf A, int id) res = QVariant((long long)v); } break; case QMetaType::Type::ULongLong: { - uint64 v = A.getContentAsUnsignedInt64Scalar(); + uint64 v = A.getContentAsUnsignedInteger64Scalar(); res = QVariant((unsigned long long)v); } break; case QMetaType::Type::Double: { diff --git a/modules/stream_manager/src/cpp/FscanFunction.cpp b/modules/stream_manager/src/cpp/FscanFunction.cpp index 107b2e8acd..915966cf97 100644 --- a/modules/stream_manager/src/cpp/FscanFunction.cpp +++ b/modules/stream_manager/src/cpp/FscanFunction.cpp @@ -124,7 +124,7 @@ convertToArrayOf(ArrayOfVector& values, Class classDestination, bool haveThirdAr switch (classDestination) { case NLS_UINT64: { for (indexType k = 0; k < nbValues; k++) { - ptr[k] = (T)values[k].getContentAsUnsignedInt64Scalar(); + ptr[k] = (T)values[k].getContentAsUnsignedInteger64Scalar(); } } break; case NLS_INT64: { diff --git a/modules/time/builtin/cpp/calendarBuiltin.cpp b/modules/time/builtin/cpp/calendarBuiltin.cpp index 9b98e74b35..798dd969d3 100644 --- a/modules/time/builtin/cpp/calendarBuiltin.cpp +++ b/modules/time/builtin/cpp/calendarBuiltin.cpp @@ -49,7 +49,7 @@ Nelson::TimeGateway::calendarBuiltin(int nLhs, const ArrayOfVector& argIn) } break; case 2: { ArrayOf param1 = argIn[0]; - uint64 cyear = param1.getContentAsUnsignedInt64Scalar(); + uint64 cyear = param1.getContentAsUnsignedInteger64Scalar(); if (cyear < 1400 || cyear > 9999) { Error(ERROR_WRONG_ARGUMENT_1_VALUE); } diff --git a/modules/time/builtin/cpp/tocBuiltin.cpp b/modules/time/builtin/cpp/tocBuiltin.cpp index 8a54a72913..1e1b749aa2 100644 --- a/modules/time/builtin/cpp/tocBuiltin.cpp +++ b/modules/time/builtin/cpp/tocBuiltin.cpp @@ -38,7 +38,7 @@ Nelson::TimeGateway::tocBuiltin(Evaluator* eval, int nLhs, const ArrayOfVector& nargoutcheck(nLhs, 0, 1); if (argIn.size() == 1) { ArrayOf paramOne = argIn[0]; - uint64 t = paramOne.getContentAsUnsignedInt64Scalar(); + uint64 t = paramOne.getContentAsUnsignedInteger64Scalar(); double r = 0; if (Toc(t, r)) { ArrayOfVector retval(1); diff --git a/modules/types/src/cpp/ArrayOf_IntegersType.cpp b/modules/types/src/cpp/ArrayOf_IntegersType.cpp index a654f3f3b9..ebcacd503f 100644 --- a/modules/types/src/cpp/ArrayOf_IntegersType.cpp +++ b/modules/types/src/cpp/ArrayOf_IntegersType.cpp @@ -278,7 +278,7 @@ ArrayOf::getContentAsInteger64Scalar(bool arrayAsScalar) const } //============================================================================= uint64 -ArrayOf::getContentAsUnsignedInt64Scalar(bool arrayAsScalar) const +ArrayOf::getContentAsUnsignedInteger64Scalar(bool arrayAsScalar) const { return getContentAsScalar(*this, NLS_UINT64, arrayAsScalar); } diff --git a/modules/types/src/include/ArrayOf.hpp b/modules/types/src/include/ArrayOf.hpp index 80cab1860f..15c3909b26 100644 --- a/modules/types/src/include/ArrayOf.hpp +++ b/modules/types/src/include/ArrayOf.hpp @@ -1081,7 +1081,7 @@ class NLSTYPES_IMPEXP ArrayOf * Throws an exception if we are not a scalar integer type. */ uint64 - getContentAsUnsignedInt64Scalar(bool arrayAsScalar = false) const; + getContentAsUnsignedInteger64Scalar(bool arrayAsScalar = false) const; /** * Get our contents as an integer scalar 64. diff --git a/modules/validators/src/cpp/ValidatorsInternal.cpp b/modules/validators/src/cpp/ValidatorsInternal.cpp index 78194533e3..cd57c3451d 100644 --- a/modules/validators/src/cpp/ValidatorsInternal.cpp +++ b/modules/validators/src/cpp/ValidatorsInternal.cpp @@ -557,7 +557,7 @@ createPrintableScalar(const ArrayOf& c, const std::wstring& fmt, const std::wstr valueAsString = std::to_wstring(value); } break; case NLS_UINT64: { - uint64 value = ArrayOf(c).getContentAsUnsignedInt64Scalar(); + uint64 value = ArrayOf(c).getContentAsUnsignedInteger64Scalar(); valueAsString = std::to_wstring(value); } break; case NLS_INT64: { diff --git a/modules/webtools/src/cpp/WebREST.cpp b/modules/webtools/src/cpp/WebREST.cpp index e3b12fa8ac..59cad090c9 100644 --- a/modules/webtools/src/cpp/WebREST.cpp +++ b/modules/webtools/src/cpp/WebREST.cpp @@ -502,7 +502,7 @@ scalarValueToString(CURL* curlObject, ArrayOf& value) s = std::to_string(v); } break; case NLS_UINT64: { - uint64 v = value.getContentAsUnsignedInt64Scalar(); + uint64 v = value.getContentAsUnsignedInteger64Scalar(); s = std::to_string(v); } break; case NLS_INT64: {