]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
gccrs: Make node id getter const.
authorPierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Thu, 26 Sep 2024 20:46:16 +0000 (22:46 +0200)
committerArthur Cohen <arthur.cohen@embecosm.com>
Wed, 19 Mar 2025 14:32:15 +0000 (15:32 +0100)
gcc/rust/ChangeLog:

* ast/rust-ast.h: Node id getter could be const.

Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
gcc/rust/ast/rust-ast.h

index f5a2e77af3f948ea523b6c989dc09db522b66a84..129a3041c7f1758c62ae0389d1d03f4ddf89b80c 100644 (file)
@@ -1587,7 +1587,7 @@ public:
 
   virtual Kind get_kind () const = 0;
 
-  NodeId get_node_id () { return node_id; }
+  NodeId get_node_id () const { return node_id; }
 
 protected:
   GenericParam () : node_id (Analysis::Mappings::get ().get_next_node_id ()) {}