{"id":2223296,"url":"http://patchwork.ozlabs.org/api/1.2/patches/2223296/?format=json","web_url":"http://patchwork.ozlabs.org/project/gcc/patch/20260414231905.191063-25-arthur.cohen@embecosm.com/","project":{"id":17,"url":"http://patchwork.ozlabs.org/api/1.2/projects/17/?format=json","name":"GNU Compiler Collection","link_name":"gcc","list_id":"gcc-patches.gcc.gnu.org","list_email":"gcc-patches@gcc.gnu.org","web_url":null,"scm_url":null,"webscm_url":null,"list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<20260414231905.191063-25-arthur.cohen@embecosm.com>","list_archive_url":null,"date":"2026-04-14T23:18:46","name":"[COMMITTED,25/43] gccrs: Update test with builtin macro definition","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"637d13bc62207082d5de32af2c9b6b4879e47a25","submitter":{"id":83476,"url":"http://patchwork.ozlabs.org/api/1.2/people/83476/?format=json","name":"Arthur Cohen","email":"arthur.cohen@embecosm.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/gcc/patch/20260414231905.191063-25-arthur.cohen@embecosm.com/mbox/","series":[{"id":499900,"url":"http://patchwork.ozlabs.org/api/1.2/series/499900/?format=json","web_url":"http://patchwork.ozlabs.org/project/gcc/list/?series=499900","date":"2026-04-14T23:18:24","name":"[COMMITTED,01/43] gccrs: testsuite:Add a testcase for setup_associated_types","version":1,"mbox":"http://patchwork.ozlabs.org/series/499900/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2223296/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2223296/checks/","tags":{},"related":[],"headers":{"Return-Path":"<gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org>","X-Original-To":["incoming@patchwork.ozlabs.org","gcc-patches@gcc.gnu.org"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","gcc-patches@gcc.gnu.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=embecosm.com header.i=@embecosm.com header.a=rsa-sha256\n header.s=google header.b=J3IA9RGv;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org\n (client-ip=2620:52:6:3111::32; helo=vm01.sourceware.org;\n envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org;\n receiver=patchwork.ozlabs.org)","sourceware.org;\n\tdkim=pass (2048-bit key,\n unprotected) header.d=embecosm.com header.i=@embecosm.com header.a=rsa-sha256\n header.s=google header.b=J3IA9RGv","sourceware.org;\n dmarc=none (p=none dis=none) header.from=embecosm.com","sourceware.org; spf=pass smtp.mailfrom=embecosm.com","server2.sourceware.org;\n arc=none smtp.remote-ip=209.85.128.65"],"Received":["from vm01.sourceware.org (vm01.sourceware.org\n [IPv6:2620:52:6:3111::32])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fwL6K58Fxz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 15 Apr 2026 09:27:37 +1000 (AEST)","from vm01.sourceware.org (localhost [127.0.0.1])\n\tby sourceware.org (Postfix) with ESMTP id E764C4BA2E0A\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 14 Apr 2026 23:27:35 +0000 (GMT)","from mail-wm1-f65.google.com (mail-wm1-f65.google.com\n [209.85.128.65])\n by sourceware.org (Postfix) with ESMTPS id 618E24BA23DC\n for <gcc-patches@gcc.gnu.org>; Tue, 14 Apr 2026 23:14:47 +0000 (GMT)","by mail-wm1-f65.google.com with SMTP id\n 5b1f17b1804b1-488ba6366a7so75542695e9.0\n for <gcc-patches@gcc.gnu.org>; Tue, 14 Apr 2026 16:14:47 -0700 (PDT)","from platypus.localdomain (176-147-231-59.abo.bbox.fr.\n [176.147.231.59]) by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-488f1dd8806sm3325945e9.3.2026.04.14.16.14.44\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 14 Apr 2026 16:14:44 -0700 (PDT)"],"DKIM-Filter":["OpenDKIM Filter v2.11.0 sourceware.org E764C4BA2E0A","OpenDKIM Filter v2.11.0 sourceware.org 618E24BA23DC"],"DMARC-Filter":"OpenDMARC Filter v1.4.2 sourceware.org 618E24BA23DC","ARC-Filter":"OpenARC Filter v1.0.0 sourceware.org 618E24BA23DC","ARC-Seal":"i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1776208487; cv=none;\n b=ZLvR+HB2kmHVsgnlTAl6LwAzMiTtmJ4F1CSVEyMTb0vn5BcaN/LtmTODYjSShZy6W6vvKGwJYGbFQIY8/lOUP72jld8JrEw3Sai/5lH6WmS59HiXhhMisjwgikOhZESlFqUT6QBIM2ruP6BJysZjy2PzqhmPs+rYfSd/IUQdfVA=","ARC-Message-Signature":"i=1; a=rsa-sha256; d=sourceware.org; s=key;\n t=1776208487; c=relaxed/simple;\n bh=FayXiSRNcQTup8zLwnP7/WjyaFX1Skueb6gkx4g89TU=;\n h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version;\n b=jAPL6Kp87tpuzvKW1DoAoCsAetFfBJwo2yY2G3YzXbD9UxL4kvBjKcPVuKWnkKDCF6YMMNChJ+fj627pum2E7S34bKiO/tF0BFzBOPp+mprR5L6p4ek0qJy9jMFP5X6R3Y0ElzWfHGSqidZQTdaw3VP8SbrkTsati0CRySOFmK4=","ARC-Authentication-Results":"i=1; server2.sourceware.org","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=embecosm.com; s=google; t=1776208486; x=1776813286; darn=gcc.gnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=WUgD0esur1gHO0fx/F+XqjwpCrfpAA2xMTiwPvpoohM=;\n b=J3IA9RGvFw867CfU7w3NA9XKDIghbajLKFZVCgJ48RtXPNM1X0dumwqZvxaTphZuno\n HqD0HWyC5wyA5l1XarN2RIJEs0OEzFtRg8RdohnaTB0W5vmgHZIiAKJiLGz64kDsMgbG\n HkrPXtX/loIS9TLOgKcOxdzWzZMR68XPXSfdFqAoQxMR8MURB2ydO7jfUD4LZ3Elay2v\n J8uLaf3/F2WELDqFxIW9XJLPMVwli5chdbutX5Vopgds57QnuF4z9C9fFAy6hPsFM9eE\n UB64RyElotIclQwqCcoLKgyYFUwgTU17mLeRkGbuNdvuGQsACNqa3nF3JFlkOoy3iP2o\n gg2A==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776208486; x=1776813286;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=WUgD0esur1gHO0fx/F+XqjwpCrfpAA2xMTiwPvpoohM=;\n b=X830owx+SlCJS3qMDVOuV+alBwkABYxRuAJviiS7cmHr7M0nBob9XjrXkm3/d3NgOe\n r6xqtmJu9oCc/lxvz1fX+biqfg+YN8PsQ49N7GGzH9LoLheVgtGPw0BKIVh8dDWzl6A+\n 4orsodOtGIZznI0sYoCt//wME3Broj58SlNcVptcYMVh4XbNYrJzhgpvyM1dbE46q3uW\n ekuHcB6OPjfgWk5d2i2CcRDGhMBIkdjM2tu4G3i/1HnpVFnTLnUZYO7dpFT3fz6MZUZF\n 0mCdMHtxxKSD21UICYHS7QingsIRgg/qMMTGcK9tuPYy7tuHb7WLKX/5UD6SokfCgsor\n 049w==","X-Gm-Message-State":"AOJu0YxGiihkRfEgdt/A/shohO2q+qsvf4NFRBb+3W9MNweYEWrXG403\n jQmAZJ2NGdB/3Tk/rDwoteOsyQD7nntqoIaClaSPINEHmWTzkS+6qGxQNOdBG3s0YAbG6S776UR\n 04L+5k1ZI","X-Gm-Gg":"AeBDievuxTeFR9R9SIALhaJnYjg6kXSKqHpG9hBcG5I5rtHqEe/4vtXba7H+MTDwiZW\n CjUp67C3qmoB8TL9gbJG3A07UxCWtFlbKOAhrb81ORZWwi7QGZuS6gfPuqI5Bpnrsd6/7ereTIr\n cRQwvrwaGhzd8UKRIXu4najkl7CWw1BYoarEsYpkCOTjSlb5x/5vLRTLWRNTrpBd5ShI7a5j21y\n 0tiEH14NYJJMHxEIInf/PyyMvxZRWfYzzek1+YM5O96licd38eTkQ7AQTeHGtxRAZwZXbU2bF12\n SPG0sPcn7J0DTCyVGBWWYb6nhegb8AGiGVnn9+zrTz2LxSOH0C5SxsUa0b6VMaYme601/icEiH2\n N7mE3ElyN9gkQwAOuaRXDXtHmRqXUTQbNW1sZ7WLYt6hkhpcDKkYmk3YipKkWkLsqTgb2SURwYp\n SU30KiKP3bKaEWESutkfbiSUTwuxdxraLxZPPd6sdByLNW4/Z6QUBOnIYm+MeeqCahJBwwbhc+A\n BqX7w==","X-Received":"by 2002:a05:600c:4e45:b0:488:8c89:cfaa with SMTP id\n 5b1f17b1804b1-488d67bf6e0mr286526285e9.3.1776208485626;\n Tue, 14 Apr 2026 16:14:45 -0700 (PDT)","From":"arthur.cohen@embecosm.com","To":"gcc-patches@gcc.gnu.org","Cc":"gcc-rust@gcc.gnu.org,\n Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>","Subject":"[COMMITTED 25/43] gccrs: Update test with builtin macro definition","Date":"Wed, 15 Apr 2026 01:18:46 +0200","Message-ID":"<20260414231905.191063-25-arthur.cohen@embecosm.com>","X-Mailer":"git-send-email 2.50.1","In-Reply-To":"<20260414231905.191063-1-arthur.cohen@embecosm.com>","References":"<20260414231905.191063-1-arthur.cohen@embecosm.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","X-BeenThere":"gcc-patches@gcc.gnu.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"Gcc-patches mailing list <gcc-patches.gcc.gnu.org>","List-Unsubscribe":"<https://gcc.gnu.org/mailman/options/gcc-patches>,\n <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe>","List-Archive":"<https://gcc.gnu.org/pipermail/gcc-patches/>","List-Post":"<mailto:gcc-patches@gcc.gnu.org>","List-Help":"<mailto:gcc-patches-request@gcc.gnu.org?subject=help>","List-Subscribe":"<https://gcc.gnu.org/mailman/listinfo/gcc-patches>,\n <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe>","Errors-To":"gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org"},"content":"From: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>\n\nThose test contain builtin macros that were not correctly defined. This\nwas mostly fine because the compiler emitted attribute errors before the\nexpansion step but now that the new builtin attribute checking is\nexecuted after the expansion we cannot ignore those missing definitions.\n\ngcc/testsuite/ChangeLog:\n\n\t* rust/compile/doc_macro.rs: Add concat builtin macro definition.\n\t* rust/compile/early_feature_gate_in_macro.rs: Add stringify builtin\n\tmacro definition.\n\t* rust/compile/issue-3661.rs: Likewise.\n\t* rust/compile/parse_time_feature_gate.rs: Add concat and stringify\n\tbuiltin macro definition.\n\nSigned-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>\n---\n gcc/testsuite/rust/compile/doc_macro.rs               |  6 ++++++\n .../rust/compile/early_feature_gate_in_macro.rs       |  5 +++++\n gcc/testsuite/rust/compile/issue-3661.rs              |  8 +++++++-\n gcc/testsuite/rust/compile/parse_time_feature_gate.rs | 11 +++++++++++\n 4 files changed, 29 insertions(+), 1 deletion(-)","diff":"diff --git a/gcc/testsuite/rust/compile/doc_macro.rs b/gcc/testsuite/rust/compile/doc_macro.rs\nindex 179455ddf95..dff69baad07 100644\n--- a/gcc/testsuite/rust/compile/doc_macro.rs\n+++ b/gcc/testsuite/rust/compile/doc_macro.rs\n@@ -1,4 +1,10 @@\n+#![feature(rustc_attrs)]\n #![feature(no_core)]\n #![no_core]\n #![feature(extended_key_value_attributes)]\n #![doc = concat!(\"AB\")]\n+\n+#[rustc_builtin_macro]\n+macro_rules! concat {\n+    () => {{}};\n+}\ndiff --git a/gcc/testsuite/rust/compile/early_feature_gate_in_macro.rs b/gcc/testsuite/rust/compile/early_feature_gate_in_macro.rs\nindex f7657736261..9e2a51027aa 100644\n--- a/gcc/testsuite/rust/compile/early_feature_gate_in_macro.rs\n+++ b/gcc/testsuite/rust/compile/early_feature_gate_in_macro.rs\n@@ -8,6 +8,11 @@ macro_rules! concat {\n     () => {{}};\n }\n \n+#[rustc_builtin_macro]\n+macro_rules! stringify {\n+    () => {{}};\n+}\n+\n macro_rules! prefix_symbol(\n     ($prefix : tt, { $($ident: ident, )* }) => {\n         $(\ndiff --git a/gcc/testsuite/rust/compile/issue-3661.rs b/gcc/testsuite/rust/compile/issue-3661.rs\nindex 7cb7c6add7a..0c8eab3f2eb 100644\n--- a/gcc/testsuite/rust/compile/issue-3661.rs\n+++ b/gcc/testsuite/rust/compile/issue-3661.rs\n@@ -1,9 +1,15 @@\n #![feature(no_core)]\n #![no_core]\n #![feature(extended_key_value_attributes)]\n+#![feature(rustc_attrs)]\n+\n+#[rustc_builtin_macro]\n+macro_rules! stringify {\n+    () => {{}};\n+}\n \n pub macro m($inner_str:expr) {\n-    #[m = $inner_str] \n+    #[m = $inner_str]\n     // { dg-error \"macro not found\" \"\" { target *-*-* } .-1 }\n \n     struct S;\ndiff --git a/gcc/testsuite/rust/compile/parse_time_feature_gate.rs b/gcc/testsuite/rust/compile/parse_time_feature_gate.rs\nindex 238b2cfd5c7..907ac0c519b 100644\n--- a/gcc/testsuite/rust/compile/parse_time_feature_gate.rs\n+++ b/gcc/testsuite/rust/compile/parse_time_feature_gate.rs\n@@ -1,5 +1,16 @@\n #![feature(no_core)]\n #![no_core]\n+#![feature(rustc_attrs)]\n+\n+#[rustc_builtin_macro]\n+macro_rules! concat {\n+    () => {{}};\n+}\n+\n+#[rustc_builtin_macro]\n+macro_rules! stringify {\n+    () => {{}};\n+}\n \n // { dg-error \"arbitrary expressions in key-value attributes are unstable\" \"\" { target *-*-* } .+1 }\n #[export_name = concat!(stringify!(non), stringify!(literal))]\n","prefixes":["COMMITTED","25/43"]}