aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/ast
diff options
context:
space:
mode:
authorCohenArthur <cohenarthur.dev@gmail.com>2025-01-10 15:26:39 +0100
committerCohenArthur <arthur.cohen@embecosm.com>2025-01-10 14:54:18 +0000
commit5db9ab5426ab234ed9cda01ceebc444c90631f6a (patch)
treed83838f4691462697612b38693b39c2011c8d15f /gcc/rust/ast
parentaa8d6981fd6f564ca2c29ea758e3fb1d7a69034a (diff)
downloadgcc-5db9ab5426ab234ed9cda01ceebc444c90631f6a.zip
gcc-5db9ab5426ab234ed9cda01ceebc444c90631f6a.tar.gz
gcc-5db9ab5426ab234ed9cda01ceebc444c90631f6a.tar.bz2
Revert "gcc/rust/ChangeLog:"
This reverts commit 600fd806b8821ea24103ea0f31d666077245c6b7.
Diffstat (limited to 'gcc/rust/ast')
-rw-r--r--gcc/rust/ast/rust-collect-lang-items.cc7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/rust/ast/rust-collect-lang-items.cc b/gcc/rust/ast/rust-collect-lang-items.cc
index ec6919d..50d134a 100644
--- a/gcc/rust/ast/rust-collect-lang-items.cc
+++ b/gcc/rust/ast/rust-collect-lang-items.cc
@@ -40,7 +40,12 @@ get_lang_item_attr (const T &maybe_lang_item)
continue;
}
- if (Analysis::Attributes::is_lang_item (str_path, attr))
+ bool is_lang_item = str_path == Values::Attributes::LANG
+ && attr.has_attr_input ()
+ && attr.get_attr_input ().get_attr_input_type ()
+ == AST::AttrInput::AttrInputType::LITERAL;
+
+ if (is_lang_item)
{
auto &literal
= static_cast<AST::AttrInputLiteral &> (attr.get_attr_input ());