diff options
author | Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com> | 2023-06-28 14:52:31 +0200 |
---|---|---|
committer | CohenArthur <arthur.cohen@embecosm.com> | 2023-07-07 13:46:54 +0000 |
commit | ac9003b440d1b677b2002c4d24cf5ce1eb3ec095 (patch) | |
tree | 1398cb1e30fd78b0bcff62260a92586f02104a08 /gcc | |
parent | ee95b41c072fbcec63df1ac8f8a67ee3996e9ac8 (diff) | |
download | gcc-ac9003b440d1b677b2002c4d24cf5ce1eb3ec095.zip gcc-ac9003b440d1b677b2002c4d24cf5ce1eb3ec095.tar.gz gcc-ac9003b440d1b677b2002c4d24cf5ce1eb3ec095.tar.bz2 |
collector: Add generics to external functions
Add generic to external functiond declaration collector output.
gcc/rust/ChangeLog:
* ast/rust-ast-collector.cc (TokenCollector::visit): Add
generics.
Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/rust/ast/rust-ast-collector.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/rust/ast/rust-ast-collector.cc b/gcc/rust/ast/rust-ast-collector.cc index 84ebcad..fedff55 100644 --- a/gcc/rust/ast/rust-ast-collector.cc +++ b/gcc/rust/ast/rust-ast-collector.cc @@ -2192,6 +2192,8 @@ TokenCollector::visit (ExternalFunctionItem &function) push (Rust::Token::make (FN_TOK, function.get_locus ())); push (Rust::Token::make_identifier (Location (), std::move (id))); + if (function.has_generics ()) + visit (function.get_generic_params ()); push (Rust::Token::make (LEFT_PAREN, Location ())); visit_items_joined_by_separator (function.get_function_params ()); |