ipmid: replace std::experimental::optional with std::optional
Now that the project is using c++17, std::optional can be used directly
instead of via the std::experimental way.
Signed-off-by: Vernon Mauery <vernon.mauery@linux.intel.com>
Change-Id: I7087f58bd3d9fd90b8b31e6902554351a3db2d0f
diff --git a/utils.cpp b/utils.cpp
index f6a840a..4aaf9c0 100644
--- a/utils.cpp
+++ b/utils.cpp
@@ -227,15 +227,14 @@
}
ServiceCache::ServiceCache(const std::string& intf, const std::string& path) :
- intf(intf), path(path), cachedService(std::experimental::nullopt),
- cachedBusName(std::experimental::nullopt)
+ intf(intf), path(path), cachedService(std::nullopt),
+ cachedBusName(std::nullopt)
{
}
ServiceCache::ServiceCache(std::string&& intf, std::string&& path) :
- intf(std::move(intf)), path(std::move(path)),
- cachedService(std::experimental::nullopt),
- cachedBusName(std::experimental::nullopt)
+ intf(std::move(intf)), path(std::move(path)), cachedService(std::nullopt),
+ cachedBusName(std::nullopt)
{
}
@@ -251,8 +250,8 @@
void ServiceCache::invalidate()
{
- cachedBusName = std::experimental::nullopt;
- cachedService = std::experimental::nullopt;
+ cachedBusName = std::nullopt;
+ cachedService = std::nullopt;
}
sdbusplus::message::message