Use C++17 optional and any
The optional and any types are no longer experimental
in C++17.
Change-Id: I0b507b73fdd13afe531bef7a2ce308ebc8a3da7d
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/manager.hpp b/manager.hpp
index e340d90..b0446b6 100644
--- a/manager.hpp
+++ b/manager.hpp
@@ -5,7 +5,7 @@
#include "dbus.hpp"
#include "interfaces.hpp"
-#include <experimental/any>
+#include <any>
#include <experimental/filesystem>
#include <map>
#include <sdbusplus/bus.hpp>
@@ -46,10 +46,10 @@
private:
using EntryID = uint32_t;
- using InterfaceMap = std::map<InterfaceType, std::experimental::any>;
+ using InterfaceMap = std::map<InterfaceType, std::any>;
using EntryMap = std::map<EntryID, InterfaceMap>;
- using ObjectList = std::vector<std::experimental::any>;
+ using ObjectList = std::vector<std::any>;
using InterfaceMapMulti = std::map<InterfaceType, ObjectList>;
using EntryMapMulti = std::map<EntryID, InterfaceMapMulti>;
@@ -231,7 +231,7 @@
* @param[in] object - the interface object
*/
void addInterface(const std::string& objectPath, InterfaceType type,
- std::experimental::any& object);
+ std::any& object);
/**
* Adds an interface to a child object, which is an object that
@@ -246,7 +246,7 @@
* @param[in] object - the interface object
*/
void addChildInterface(const std::string& objectPath, InterfaceType type,
- std::experimental::any& object);
+ std::any& object);
/**
* The sdbusplus bus object