Add more const const
Found by clang-tidy.
Change-Id: I4faa8135052690f59020779408894eb951e707e5
diff --git a/src/grammars.hpp b/src/grammars.hpp
index 7e5b49d..02da179 100644
--- a/src/grammars.hpp
+++ b/src/grammars.hpp
@@ -96,8 +96,8 @@
}
} const datastore;
-auto copy_source = x3::rule<class source, Datastore>{"source datastore"} = datastore;
-auto copy_destination = x3::rule<class source, Datastore>{"destination datastore"} = datastore;
+const auto copy_source = x3::rule<class source, Datastore>{"source datastore"} = datastore;
+const auto copy_destination = x3::rule<class source, Datastore>{"destination datastore"} = datastore;
const auto datastoreSuggestions = x3::eps[([](auto& ctx) {
auto& parserContext = x3::get<parser_context_tag>(ctx);
@@ -131,7 +131,7 @@
return true;
}
-} copy_args;
+} const copy_args;
auto const copy_def =
copy_::name > space_separator > copy_args;
diff --git a/src/netconf-client.cpp b/src/netconf-client.cpp
index fde9561..c09a2db 100644
--- a/src/netconf-client.cpp
+++ b/src/netconf-client.cpp
@@ -75,7 +75,7 @@
}
template <typename Type> using deleter_type_for = void (*)(Type*);
-template <typename Type> deleter_type_for<Type> deleter_for;
+template <typename Type> deleter_type_for<Type> const deleter_for;
template <> const auto deleter_for<nc_rpc> = nc_rpc_free;
template <> const auto deleter_for<nc_reply> = nc_reply_free;
diff --git a/src/path_parser.hpp b/src/path_parser.hpp
index eb34033..fca760d 100644
--- a/src/path_parser.hpp
+++ b/src/path_parser.hpp
@@ -433,7 +433,7 @@
return true;
}
-} writableLeafPath;
+} const writableLeafPath;
struct RpcActionPath : x3::parser<RpcActionPath> {
using attribute_type = dataPath_;