[gcc r16-8231] gccrs: Add no_std to builtin attributes

Arthur Cohen cohenarthur@gcc.gnu.org
Fri Mar 20 17:26:02 GMT 2026


https://gcc.gnu.org/g:7fc6e3d2aa6b911cc64abf6b1a5bddde359ae20e

commit r16-8231-g7fc6e3d2aa6b911cc64abf6b1a5bddde359ae20e
Author: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Date:   Fri Mar 6 17:24:31 2026 +0100

    gccrs: Add no_std to builtin attributes
    
    no_std is a builtin attribute required for rust-for-linux but was
    missing from the builtin attribute list and instead considered an unknown
    attribute macro invocation.
    
    gcc/rust/ChangeLog:
    
            * util/rust-attributes.cc: Add no_std to list of builtin attributes.
    
    Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>

Diff:
---
 gcc/rust/util/rust-attributes.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/rust/util/rust-attributes.cc b/gcc/rust/util/rust-attributes.cc
index d246cc672115..93d71a490d24 100644
--- a/gcc/rust/util/rust-attributes.cc
+++ b/gcc/rust/util/rust-attributes.cc
@@ -98,6 +98,7 @@ static const BuiltinAttrDefinition __definitions[]
      // #![feature(rustc_attrs)]
      {Attrs::FEATURE, STATIC_ANALYSIS},
      {Attrs::NO_CORE, CODE_GENERATION},
+     {Attrs::NO_STD, CODE_GENERATION},
      {Attrs::DOC, EXTERNAL},
      {Attrs::CRATE_NAME, CODE_GENERATION},
      {Attrs::CRATE_TYPE, CODE_GENERATION},


More information about the Gcc-cvs mailing list