[gnome-commander/Implement_CppCheck_suggestions] User override specifier for derived, overriding methods
- From: Uwe Scholz <uwescholz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-commander/Implement_CppCheck_suggestions] User override specifier for derived, overriding methods
- Date: Mon, 18 Mar 2019 22:23:53 +0000 (UTC)
commit 9b8c6780f2a47db70f4decdc0a9558ff0968ee48
Author: Uwe Scholz <u scholz83 gmx de>
Date: Mon Mar 18 23:23:18 2019 +0100
User override specifier for derived, overriding methods
src/gnome-cmd-plain-path.h | 31 +++++++++++++++++++++++--------
1 file changed, 23 insertions(+), 8 deletions(-)
---
diff --git a/src/gnome-cmd-plain-path.h b/src/gnome-cmd-plain-path.h
index 5d809501..2c97f8db 100644
--- a/src/gnome-cmd-plain-path.h
+++ b/src/gnome-cmd-plain-path.h
@@ -1,4 +1,4 @@
-/**
+/**
* @file gnome-cmd-plain-path.h
* @copyright (C) 2001-2006 Marcus Bjurman\n
* @copyright (C) 2007-2012 Piotr Eljasiak\n
@@ -32,18 +32,33 @@ class GnomeCmdPlainPath: public GnomeCmdPath
protected:
- virtual GnomeCmdPlainPath *do_clone() const { return new GnomeCmdPlainPath(*this); }
+ virtual GnomeCmdPlainPath *do_clone() const override
+ {
+ return new GnomeCmdPlainPath(*this);
+ }
public:
GnomeCmdPlainPath(const GnomeCmdPlainPath &thePath);
- explicit GnomeCmdPlainPath(const gchar *plain_path) { this->path = g_strdup (plain_path); }
- virtual ~GnomeCmdPlainPath() { g_free (path); }
+ explicit GnomeCmdPlainPath(const gchar *plain_path)
+ {
+ this->path = g_strdup (plain_path);
+ }
+ virtual ~GnomeCmdPlainPath()
+ {
+ g_free (path);
+ }
- virtual const gchar *get_path() { return path; }
- virtual const gchar *get_display_path() { return path; }
- virtual GnomeCmdPath *get_parent();
- virtual GnomeCmdPath *get_child(const gchar *child);
+ virtual const gchar *get_path() override
+ {
+ return path;
+ }
+ virtual const gchar *get_display_path() override
+ {
+ return path;
+ }
+ virtual GnomeCmdPath *get_parent() override;
+ virtual GnomeCmdPath *get_child(const gchar *child) override;
};
inline GnomeCmdPlainPath::GnomeCmdPlainPath(const GnomeCmdPlainPath &thePath)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]