diff options
| author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2018-06-18 16:54:54 +0000 |
|---|---|---|
| committer | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2018-06-18 18:27:11 +0000 |
| commit | 571f36f1b61d316a2f2ace00fa94ba83ab1ac0a0 (patch) | |
| tree | 95696a57d31908e2d5b5853b4c84e3d53c700db1 /src/event.h | |
| parent | Update pdf-parser.cpp (diff) | |
| download | inkscape-571f36f1b61d316a2f2ace00fa94ba83ab1ac0a0.tar.gz inkscape-571f36f1b61d316a2f2ace00fa94ba83ab1ac0a0.zip | |
Run clang-tidy’s modernize-pass-by-value pass.
This avoids having to pass variables by reference before copying them
when calling a constructor.
Diffstat (limited to 'src/event.h')
| -rw-r--r-- | src/event.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/event.h b/src/event.h index fe4ed681c..03c64509d 100644 --- a/src/event.h +++ b/src/event.h @@ -16,6 +16,8 @@ #include <glibmm/ustring.h> +#include <utility> + #include "xml/event-fns.h" #include "verbs.h" @@ -30,7 +32,7 @@ namespace Inkscape { struct Event { Event(XML::Event *_event, unsigned int _type=SP_VERB_NONE, Glib::ustring _description="") - : event (_event), type (_type), description (_description) { } + : event (_event), type (_type), description (std::move(_description)) { } virtual ~Event() { sp_repr_free_log (event); } |
