aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorPierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>2023-11-02 18:10:32 +0100
committerP-E-P <32375388+P-E-P@users.noreply.github.com>2023-11-06 11:46:54 +0000
commit78ba5b74fb0900b3ba00625839a5dc624e37c2c7 (patch)
tree7feb8e7d69c8878b74fc7e9e676235c8f530e13a /gcc
parente009d3df6a03cf4b4cc020199ede902297b31076 (diff)
downloadgcc-78ba5b74fb0900b3ba00625839a5dc624e37c2c7.zip
gcc-78ba5b74fb0900b3ba00625839a5dc624e37c2c7.tar.gz
gcc-78ba5b74fb0900b3ba00625839a5dc624e37c2c7.tar.bz2
Add missing override specifier
Some function lacked the override specifier, this made the compiler emit several warning. gcc/rust/ChangeLog: * ast/rust-ast.h: Add override specifier. * ast/rust-item.h: Likewise. Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Diffstat (limited to 'gcc')
-rw-r--r--gcc/rust/ast/rust-ast.h2
-rw-r--r--gcc/rust/ast/rust-item.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/gcc/rust/ast/rust-ast.h b/gcc/rust/ast/rust-ast.h
index a2d088e..3561293 100644
--- a/gcc/rust/ast/rust-ast.h
+++ b/gcc/rust/ast/rust-ast.h
@@ -1495,7 +1495,7 @@ public:
}
NodeId get_node_id () const { return node_id; }
- location_t get_locus () const { return locus; }
+ location_t get_locus () const override { return locus; }
};
/* Abstract base class for items used within an inherent impl block (the impl
diff --git a/gcc/rust/ast/rust-item.h b/gcc/rust/ast/rust-item.h
index 99cb908..bcc33dc 100644
--- a/gcc/rust/ast/rust-item.h
+++ b/gcc/rust/ast/rust-item.h
@@ -3291,7 +3291,7 @@ public:
std::string as_string () const override;
- location_t get_locus () const { return locus; }
+ location_t get_locus () const override { return locus; }
void accept_vis (ASTVisitor &vis) override;