From 175c04323ad1aaaa1e0c949b8de411d5e2cece74 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 17 Jul 2024 11:33:25 -0400 Subject: Avoid C-style casts and some size type conversions Aside from the syntactic cast changes, reduces some size types to 32-bits, since they can never be so large in practice. This eliminates some type conversions and shaves a few bytes. --- src/gui/GraphCanvas.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/gui/GraphCanvas.cpp') diff --git a/src/gui/GraphCanvas.cpp b/src/gui/GraphCanvas.cpp index 5ea39de0..e02c4e5b 100644 --- a/src/gui/GraphCanvas.cpp +++ b/src/gui/GraphCanvas.cpp @@ -876,7 +876,7 @@ GraphCanvas::menu_add_port(const string& sym_base, uris.rdf_type, Property(is_output ? uris.lv2_OutputPort : uris.lv2_InputPort)); props.emplace(uris.lv2_index, - _app.forge().make(int32_t(_graph->num_ports()))); + _app.forge().make(static_cast(_graph->num_ports()))); props.emplace(uris.lv2_name, _app.forge().alloc(name.c_str())); _app.interface()->put(path_to_uri(path), props); } -- cgit v1.2.1