aboutsummaryrefslogtreecommitdiffstats
path: root/core/ambdec.cpp
diff options
context:
space:
mode:
authorSven Gothel <sgothel@jausoft.com>2023-11-28 12:51:46 +0100
committerSven Gothel <sgothel@jausoft.com>2023-11-28 12:51:46 +0100
commit1aaf4f070011490bcece50394b9b32dfa593fd9e (patch)
tree17d68284e401a35eea3d3a574d986d446a60763a /core/ambdec.cpp
parent6e7cee4fa9a8af03f28ca26cd89f8357390dfc90 (diff)
parent571b546f35eead77ce109f8d4dd6c3de3199d573 (diff)
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'core/ambdec.cpp')
-rw-r--r--core/ambdec.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/ambdec.cpp b/core/ambdec.cpp
index 8ca182c4..f98e1098 100644
--- a/core/ambdec.cpp
+++ b/core/ambdec.cpp
@@ -47,9 +47,9 @@ enum class ReaderScope {
#else
[[gnu::format(printf,2,3)]]
#endif
-al::optional<std::string> make_error(size_t linenum, const char *fmt, ...)
+std::optional<std::string> make_error(size_t linenum, const char *fmt, ...)
{
- al::optional<std::string> ret;
+ std::optional<std::string> ret;
auto &str = ret.emplace();
str.resize(256);
@@ -77,7 +77,7 @@ al::optional<std::string> make_error(size_t linenum, const char *fmt, ...)
AmbDecConf::~AmbDecConf() = default;
-al::optional<std::string> AmbDecConf::load(const char *fname) noexcept
+std::optional<std::string> AmbDecConf::load(const char *fname) noexcept
{
al::ifstream f{fname};
if(!f.is_open())
@@ -139,7 +139,7 @@ al::optional<std::string> AmbDecConf::load(const char *fname) noexcept
{
--toread;
istr >> value;
- if(curgain < al::size(gains))
+ if(curgain < std::size(gains))
gains[curgain++] = value;
}
}
@@ -291,7 +291,7 @@ al::optional<std::string> AmbDecConf::load(const char *fname) noexcept
if(CoeffScale == AmbDecScale::Unset)
return make_error(linenum, "No coefficient scaling defined");
- return al::nullopt;
+ return std::nullopt;
}
else
return make_error(linenum, "Unexpected command: %s", command.c_str());