1 /* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
2 file Copyright.txt or https://cmake.org/licensing for details. */
5 #include "cmConfigure.h" // IWYU pragma: keep
7 #include <initializer_list>
12 #include <cm/string_view>
13 #include <cmext/string_view>
15 class cmExecutionStatus
;
17 class cmSubcommandTable
20 using Command
= bool (*)(std::vector
<std::string
> const&,
23 using Elem
= std::pair
<cm::string_view
, Command
>;
24 using InitElem
= std::pair
<cm::static_string_view
, Command
>;
26 cmSubcommandTable(std::initializer_list
<InitElem
> init
);
28 bool operator()(cm::string_view key
, std::vector
<std::string
> const& args
,
29 cmExecutionStatus
& status
) const;
32 std::vector
<Elem
> Impl
;