diff options
author | David Robillard <d@drobilla.net> | 2020-07-30 20:54:49 +0200 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2020-07-30 20:55:28 +0200 |
commit | 473d9bd0cb085dee2fc73506ccdfce990aeee147 (patch) | |
tree | 3d57ab4200c29b7542bd1f830653acebd5c2a2c8 /ganv/Edge.hpp | |
parent | e75c1e1873165e269c78d624d194fd165756837d (diff) | |
download | ganv-473d9bd0cb085dee2fc73506ccdfce990aeee147.tar.gz ganv-473d9bd0cb085dee2fc73506ccdfce990aeee147.tar.bz2 ganv-473d9bd0cb085dee2fc73506ccdfce990aeee147.zip |
Use modern casts in C++ code
Diffstat (limited to 'ganv/Edge.hpp')
-rw-r--r-- | ganv/Edge.hpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ganv/Edge.hpp b/ganv/Edge.hpp index 5c60711..eb723e5 100644 --- a/ganv/Edge.hpp +++ b/ganv/Edge.hpp @@ -48,8 +48,8 @@ public: tail->gobj(), head->gobj(), "color", color, - "curved", (gboolean)curved, - "arrowhead", (gboolean)show_arrowhead, + "curved", static_cast<gboolean>(curved), + "arrowhead", static_cast<gboolean>(show_arrowhead), NULL))) {} @@ -77,8 +77,8 @@ public: METHODRETWRAP0(ganv_edge, Node*, get_tail) METHODRETWRAP0(ganv_edge, Node*, get_head) - GanvEdge* gobj() { return (GanvEdge*)_gobj; } - const GanvEdge* gobj() const { return (GanvEdge*)_gobj; } + GanvEdge* gobj() { return reinterpret_cast<GanvEdge*>(_gobj); } + const GanvEdge* gobj() const { return reinterpret_cast<GanvEdge*>(_gobj); } private: Edge(const Edge& copy); |