public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-7702] gccrs: ast: Add explicit default copy constructor
@ 2024-01-16 17:55 Arthur Cohen
  0 siblings, 0 replies; only message in thread
From: Arthur Cohen @ 2024-01-16 17:55 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:5373b8e66cc66e0691e60ec7a2ea633ca7e5a9d1

commit r14-7702-g5373b8e66cc66e0691e60ec7a2ea633ca7e5a9d1
Author: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Date:   Tue Jun 27 14:03:16 2023 +0200

    gccrs: ast: Add explicit default copy constructor
    
    Add explicit default copy/move constructor to identifiers.
    
    gcc/rust/ChangeLog:
    
            * ast/rust-ast.h: Add default constructors.
    
    Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>

Diff:
---
 gcc/rust/ast/rust-ast.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/gcc/rust/ast/rust-ast.h b/gcc/rust/ast/rust-ast.h
index a4caee7237d..e097a21d1cf 100644
--- a/gcc/rust/ast/rust-ast.h
+++ b/gcc/rust/ast/rust-ast.h
@@ -39,6 +39,11 @@ public:
     : ident (ident), node_id (Analysis::Mappings::get ()->get_next_node_id ())
   {}
 
+  Identifier (const Identifier &) = default;
+  Identifier (Identifier &&) = default;
+  Identifier &operator= (const Identifier &) = default;
+  Identifier &operator= (Identifier &&) = default;
+
   NodeId get_node_id () const { return node_id; }
   const std::string &as_string () const { return ident; }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-01-16 17:55 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-16 17:55 [gcc r14-7702] gccrs: ast: Add explicit default copy constructor Arthur Cohen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).