@@ -1749,8 +1749,8 @@ static __u16 parse_phys_addr_from_edid(const char *edid_path)
return pa;
}
-typedef std::vector<std::string> dev_vec;
-typedef std::map<std::string, std::string> dev_map;
+using dev_vec = std::vector<std::string>;
+using dev_map = std::map<std::string, std::string>;
static void list_devices()
{
@@ -39,7 +39,7 @@
#define ARRAY_SIZE(arr) ((int)(sizeof(arr) / sizeof((arr)[0])))
typedef std::vector<std::string> dev_vec;
-typedef std::map<std::string, std::string> dev_map;
+using dev_map = std::map<std::string, std::string>;
/* Short option list
@@ -322,7 +322,7 @@ static media_link_desc link_disabled;
int testMediaEnum(struct node *node)
{
- typedef std::map<__u32, media_entity_desc> entity_map;
+ using entity_map = std::map<__u32, media_entity_desc>;
entity_map ent_map;
id_set has_default_set;
struct media_entity_desc ent;
@@ -34,22 +34,22 @@ struct ctrl_subset {
typedef std::map<unsigned, std::vector<struct v4l2_ext_control> > class2ctrls_map;
-typedef std::map<std::string, struct v4l2_query_ext_ctrl> ctrl_qmap;
+using ctrl_qmap = std::map<std::string, struct v4l2_query_ext_ctrl>;
static ctrl_qmap ctrl_str2q;
-typedef std::map<unsigned, std::string> ctrl_idmap;
+using ctrl_idmap = std::map<unsigned int, std::string>;
static ctrl_idmap ctrl_id2str;
-typedef std::map<std::string, ctrl_subset> ctrl_subset_map;
+using ctrl_subset_map = std::map<std::string, ctrl_subset>;
static ctrl_subset_map ctrl_subsets;
-typedef std::list<std::string> ctrl_get_list;
+using ctrl_get_list = std::list<std::string>;
static ctrl_get_list get_ctrls;
-typedef std::map<std::string, std::string> ctrl_set_map;
+using ctrl_set_map = std::map<std::string, std::string>;
static ctrl_set_map set_ctrls;
-typedef std::vector<std::string> dev_vec;
-typedef std::map<std::string, std::string> dev_map;
+using dev_vec = std::vector<std::string>;
+using dev_map = std::map<std::string, std::string>;
static enum v4l2_priority prio = V4L2_PRIORITY_UNSET;
Found with modernize-use-using Signed-off-by: Rosen Penev <rosenp@gmail.com> --- utils/cec-ctl/cec-ctl.cpp | 4 ++-- utils/rds-ctl/rds-ctl.cpp | 2 +- utils/v4l2-compliance/v4l2-test-media.cpp | 2 +- utils/v4l2-ctl/v4l2-ctl-common.cpp | 14 +++++++------- 4 files changed, 11 insertions(+), 11 deletions(-)