From patchwork Wed May 10 16:48:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bernhard Reutner-Fischer X-Patchwork-Id: 92213 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp3769932vqo; Wed, 10 May 2023 09:51:10 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4/xo7Bo/KjoITMHfigLdbqC5Q96VMK9a4EZWtfBPZE/TIEp/djDmXvyYPYqrKd5ib80mVP X-Received: by 2002:a17:907:98c:b0:94a:5819:5a2b with SMTP id bf12-20020a170907098c00b0094a58195a2bmr16505334ejc.33.1683737470100; Wed, 10 May 2023 09:51:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683737470; cv=none; d=google.com; s=arc-20160816; b=uI0vOXCHkYvFAIxuqFIgnfGn6ifiBNhjTCL1TAmKa6QIfavSAHXWagnurgpgELHjob 0jTNBlUgGilM96bKJXWaRDz+la1jhraRqKq4pEI10/TEBskZ3dlSB+mfeRbvxEBV3mLV i3faYJrv4XTrr7oh9KIYIVHoP0ISDeODJPrcoRhkALmb0jjnetRmI37z802kn/cAQB0j PLimn7gY2+iX95Zei03edSExD4AIGGoUrbFkF/vo1E2OjfQpKLbEeNECE395UCKZ42l4 1V7cv3BmUdPePoqk0IwWNrs62Tw7Uf8jjqEdy2MwusMLijgRlXEeOgWmo+2TaZNCg9Nq MdHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:message-id:date:subject:cc :to:dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=hyKt3QiD+lKrgnEEuXf9PAWjF9awbG4d7igQip9eUTM=; b=qRT2umaAOtkVDg5ERi02y3K+81VOjqdrqUANj96bWGs/Iy33pahc3FmtJbWn4BP4Jm HdtLag9RZ7uLLBOFE5TQIK0Zrjinb+QXcAlBDdtHdWA8iWvctlzcCXLZ+S6g6i+ICbWk bWlvp/xKqrWCXUHWYksIX/d9ebftNgXT3mWMf+glS0lQxhEt3Q1b7IL1vB6hIEeYomOf 7PBPAvW5MTj5QCh7/mONyFRtk+F4TqD4Ezg63Hfybru1yiPeQflj/S75daFeP7NP0hcD RAMzCZ/XOO80UUr+5kLd/WVl9Fm9qsiXLDFfwo0QB16DZTyp2uRpv6KuroXlNZJKWd7C YxUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=pjywJwPR; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id ml23-20020a170906cc1700b00965d8137645si3024212ejb.208.2023.05.10.09.51.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 May 2023 09:51:10 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=pjywJwPR; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id D872E3835E04 for ; Wed, 10 May 2023 16:49:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D872E3835E04 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1683737387; bh=hyKt3QiD+lKrgnEEuXf9PAWjF9awbG4d7igQip9eUTM=; h=To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=pjywJwPRap7q9Nm8eo841B2CZT+9wORLM6ERRGkTku8DRvB1i71JVKngffGl0CVAE vuxLzB6Mek2DTBTYYXVCqgwQ/7rV/l//1bqrhgHn/BGx0NTzCxYyUIUnsMzOLVgrVz lVPXJlmkA5euyITeL3o8F4murCZlmyfLPYt2c810= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) by sourceware.org (Postfix) with ESMTPS id 38C4B3876880; Wed, 10 May 2023 16:49:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 38C4B3876880 Received: by mail-ej1-x629.google.com with SMTP id a640c23a62f3a-9659f452148so1324109666b.1; Wed, 10 May 2023 09:49:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683737340; x=1686329340; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=hyKt3QiD+lKrgnEEuXf9PAWjF9awbG4d7igQip9eUTM=; b=gbqmopfiJZ7T6x7mJ2r8DUFeCD+An8NeVSOWHkz5nZwcN4OWoGx4bMTqATKUzaQS2c oQn6p/vmvxIAWp5RDXCPR9+KR2skqfK+cFsNKCgYKuMKlY37RikOE7wC6jk2ReTi8zws aRwaA8pLvAUo+bRbNVM7kkYU+detgeTetEsnVQjmRryD8yRh0QTP1y2d9X+TT/QU0Nw1 Sz668bgGHJ1xoqWY749Y9sDr6jONmxvRQo1lTGPBvqoSMn/SlvHK8sorwsTeQZp86jUf 2EwBg2XtiojRFMG8U/MDQFq/8+IPYKXuf0kHp+ecbfCmjR9zhXSom7+4yPyLv0zteQHg YO2g== X-Gm-Message-State: AC+VfDxTV0CD7TavJVm+kGYIssW9ja7C38qy7gFqzF2irISs2uECdPvY jfsQF+JgPJdztQr4ZOUIJggeeSsYcoU= X-Received: by 2002:a17:907:3da3:b0:95e:d74c:b06 with SMTP id he35-20020a1709073da300b0095ed74c0b06mr18873742ejc.64.1683737340436; Wed, 10 May 2023 09:49:00 -0700 (PDT) Received: from nbbrfq (80-110-214-113.static.upcbusiness.at. [80.110.214.113]) by smtp.gmail.com with ESMTPSA id p3-20020a17090664c300b0094f2f1c5ea1sm2925212ejn.174.2023.05.10.09.48.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 May 2023 09:48:59 -0700 (PDT) Received: from b by nbbrfq with local (Exim 4.96) (envelope-from ) id 1pwmzq-000eXP-2r; Wed, 10 May 2023 18:48:58 +0200 To: fortran@gcc.gnu.org Cc: gcc-patches@gcc.gnu.org, Bernhard Reutner-Fischer Subject: [PATCH 1/2] Fortran: dump-parse-tree attribs: fix unbalanced braces [PR109624] Date: Wed, 10 May 2023 18:48:40 +0200 Message-Id: <20230510164841.155816-1-rep.dot.nop@gmail.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Bernhard Reutner-Fischer via Gcc-patches From: Bernhard Reutner-Fischer Reply-To: Bernhard Reutner-Fischer Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765526701323937765?= X-GMAIL-MSGID: =?utf-8?q?1765526701323937765?= From: Bernhard Reutner-Fischer gcc/fortran/ChangeLog: PR fortran/109624 * dump-parse-tree.cc (debug): New function for gfc_namespace. (gfc_debug_code): Delete forward declaration. (show_attr): Make sure to print balanced braces. --- (gdb) call debug(gfc_current_ns) Namespace: A-H: (REAL 4) I-N: (INTEGER 4) O-Z: (REAL 4) procedure name = fmodule symtree: 'C_ptr' || symbol: 'c_ptr' type spec : (UNKNOWN 0) attributes: ) There is an open brace missing after "attributes: " Regression tested on x86_64-linux, OK for trunk? --- gcc/fortran/dump-parse-tree.cc | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/gcc/fortran/dump-parse-tree.cc b/gcc/fortran/dump-parse-tree.cc index 1fc1f311e84..2380fa04796 100644 --- a/gcc/fortran/dump-parse-tree.cc +++ b/gcc/fortran/dump-parse-tree.cc @@ -125,6 +125,16 @@ void debug (gfc_ref *p) dumpfile = tmp; } +void +debug (gfc_namespace *ns) +{ + FILE *tmp = dumpfile; + dumpfile = stderr; + show_namespace (ns); + fputc ('\n', dumpfile); + dumpfile = tmp; +} + void gfc_debug_expr (gfc_expr *e) { @@ -136,7 +146,6 @@ gfc_debug_expr (gfc_expr *e) } /* Allow for dumping of a piece of code in the debugger. */ -void gfc_debug_code (gfc_code *c); void gfc_debug_code (gfc_code *c) @@ -758,12 +767,13 @@ show_expr (gfc_expr *p) static void show_attr (symbol_attribute *attr, const char * module) { + fputc ('(', dumpfile); if (attr->flavor != FL_UNKNOWN) { if (attr->flavor == FL_DERIVED && attr->pdt_template) - fputs (" (PDT-TEMPLATE", dumpfile); + fputs ("PDT-TEMPLATE ", dumpfile); else - fprintf (dumpfile, "(%s ", gfc_code2string (flavors, attr->flavor)); + fprintf (dumpfile, "%s ", gfc_code2string (flavors, attr->flavor)); } if (attr->access != ACCESS_UNKNOWN) fprintf (dumpfile, "%s ", gfc_code2string (access_types, attr->access)); From patchwork Wed May 10 16:48:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bernhard Reutner-Fischer X-Patchwork-Id: 92214 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp3770173vqo; Wed, 10 May 2023 09:51:32 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7nNi/dfkTP5yI9LaEcKpkL10E7Nf94yi+clrxe/oqAMcT4bcgruqH3U8epxe92wjhRUHod X-Received: by 2002:a17:907:97cb:b0:96a:4654:9a57 with SMTP id js11-20020a17090797cb00b0096a46549a57mr1109954ejc.54.1683737492279; Wed, 10 May 2023 09:51:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683737492; cv=none; d=google.com; s=arc-20160816; b=mOpipMRn8ZpH915PuvpKBIumCmgmdB5bgC6heqYafRptX+K7tjOq377nqRktiaMEY7 WsVsKPSkAX711VnBSccJpSDH/GThH7ZjvjjXUUX8UrlheDZNhgQdtqYUDAWwgTkOMwJJ 5d9GpRogr94oXwctwzcOA4FZ8NnUVJP9F/BkgcApzNLIKCvt9c4lEfp/Dngnf3eWfpjH llYmV4TD+xIKSMkbsE7wTdwDBCOzgrS8PYaQZeB31uVe56JubG/66lBn3+HHiibOr8Qg U/VmMU6mjjxoBm5zopLTHBS0afXPhx6eel3+3XAA4sRwMzt0r14NeaYREE9RzLpQh8GX 5QKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:dmarc-filter:delivered-to :dkim-signature:dkim-filter; bh=mzRICJ8aezvNYezC1izf5S0yDNYL4wdfQxZeqjvBEmo=; b=dyCYyuHO3mp8WP6X86TiegPNKnrKgDyioOqIbwdtb8zsumfbFFGiBs3SuUhzrcFfCN 6iwo/A9cmHKmQ5OgfVqgMXiexOnfVSR8/INW4MmOujQsYuM1+oMWO1e0uuPbAYuNA8Ze SIGYKyV+7kdv3oyusvAGbdpK5SHvs4cFaJyNr0riVTLvkMb57oCkkHUcpOSI3QZDwUQ5 7pQ8BS2ZwS3RfS4qGaLOfJAnk31stG2xlVcyt2Jh9UEs2v7rbsibJQM6rWfue2NWYw05 8GoXg7VCQSlXNVw+iGnyvPGaBMgDCpnT2x3GFfxmDPrHz97Rn5rRDZHpPW8O2buro4na BTJQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=Ur6ePrib; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id h25-20020a170906855900b0094efa335a49si3707225ejy.851.2023.05.10.09.51.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 May 2023 09:51:32 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=Ur6ePrib; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 540CD3853829 for ; Wed, 10 May 2023 16:50:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 540CD3853829 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1683737405; bh=mzRICJ8aezvNYezC1izf5S0yDNYL4wdfQxZeqjvBEmo=; h=To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=Ur6ePrib+z1sAcwdS5GcFZ+QHPuLZp4doMf7OZlmMQ3TvxDjdydQDEXAEx4SQ9qFL 7uZws7YSK2bQPK+Xc/a06hI6y27bgvlm9PP74fZLIcpfbAA3+4BQ56kX5hfA6dSOO6 cxvLBej8fCqN3+0VLUrja0NLLsoKqJxdkDJwlRh8= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) by sourceware.org (Postfix) with ESMTPS id 0159C386D623; Wed, 10 May 2023 16:49:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 0159C386D623 Received: by mail-ej1-x632.google.com with SMTP id a640c23a62f3a-965e93f915aso1207150166b.2; Wed, 10 May 2023 09:49:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683737340; x=1686329340; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mzRICJ8aezvNYezC1izf5S0yDNYL4wdfQxZeqjvBEmo=; b=TJdi8B885xe85opbn46ddROMIh8dVCDgw80Vczz0MCnxg89xEY1SuO9YJTj7dO6nZ1 Smxa+GWF+8QRHj07t2/dtajy4jczl4gMCJdRaNFjbfNSkCXjx08U6iyM7Ot+RsaTbhRt 6cHy6ii81WygiA57v6v37QOvFYcjWDTp30f3gJh6F/E0H2tVIYF+3+/bfw1mNYSsRcD0 Qd0CJzykxYoq9DBmfqXAn2KdFHeEjQNVjkutv1LfTN5yp+wt4WP8F/yL6PTWGHQVQZfX J1pSQXQojP5dHDv+oGGCkPX7ujrsqaHTY6WaQXVkogZi1hb7nO+cf+hi4n76tnlQo2kd kDgw== X-Gm-Message-State: AC+VfDycF9796JCLrYqCip1YM+gBuRbrCNmBduYjdaTl/1OCR8aLAvJe C8CEdbLLBr7dDTDlgulzfIVrBRThedw= X-Received: by 2002:a17:907:1614:b0:94d:8b66:46d1 with SMTP id hb20-20020a170907161400b0094d8b6646d1mr16835209ejc.6.1683737340181; Wed, 10 May 2023 09:49:00 -0700 (PDT) Received: from nbbrfq (80-110-214-113.static.upcbusiness.at. [80.110.214.113]) by smtp.gmail.com with ESMTPSA id hv7-20020a17090760c700b00965be665811sm2897600ejc.2.2023.05.10.09.48.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 May 2023 09:48:59 -0700 (PDT) Received: from b by nbbrfq with local (Exim 4.96) (envelope-from ) id 1pwmzq-000eXS-2u; Wed, 10 May 2023 18:48:58 +0200 To: fortran@gcc.gnu.org Cc: gcc-patches@gcc.gnu.org, Bernhard Reutner-Fischer Subject: [PATCH 2/2] Fortran: dump-parse-tree: Mark debug functions with DEBUG_FUNCTION Date: Wed, 10 May 2023 18:48:41 +0200 Message-Id: <20230510164841.155816-2-rep.dot.nop@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230510164841.155816-1-rep.dot.nop@gmail.com> References: <20230510164841.155816-1-rep.dot.nop@gmail.com> MIME-Version: 1.0 X-Spam-Status: No, score=-9.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Bernhard Reutner-Fischer via Gcc-patches From: Bernhard Reutner-Fischer Reply-To: Bernhard Reutner-Fischer Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765526724772470895?= X-GMAIL-MSGID: =?utf-8?q?1765526724772470895?= From: Bernhard Reutner-Fischer gcc/fortran/ChangeLog: * dump-parse-tree.cc (gfc_debug_expr): Remove forward declaration. (debug): Add DEBUG_FUNCTION. (show_code_node): Remove erroneous whitespace. --- Regression tested on x86_64-linux, OK for trunk? --- gcc/fortran/dump-parse-tree.cc | 38 ++++++++++++++++++++-------------- 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/gcc/fortran/dump-parse-tree.cc b/gcc/fortran/dump-parse-tree.cc index 2380fa04796..644f8f37d63 100644 --- a/gcc/fortran/dump-parse-tree.cc +++ b/gcc/fortran/dump-parse-tree.cc @@ -55,10 +55,8 @@ static void show_typespec (gfc_typespec *); static void show_ref (gfc_ref *); static void show_attr (symbol_attribute *, const char *); -/* Allow dumping of an expression in the debugger. */ -void gfc_debug_expr (gfc_expr *); - -void debug (symbol_attribute *attr) +DEBUG_FUNCTION void +debug (symbol_attribute *attr) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -67,7 +65,8 @@ void debug (symbol_attribute *attr) dumpfile = tmp; } -void debug (gfc_formal_arglist *formal) +DEBUG_FUNCTION void +debug (gfc_formal_arglist *formal) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -80,12 +79,14 @@ void debug (gfc_formal_arglist *formal) dumpfile = tmp; } -void debug (symbol_attribute attr) +DEBUG_FUNCTION void +debug (symbol_attribute attr) { debug (&attr); } -void debug (gfc_expr *e) +DEBUG_FUNCTION void +debug (gfc_expr *e) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -102,7 +103,8 @@ void debug (gfc_expr *e) dumpfile = tmp; } -void debug (gfc_typespec *ts) +DEBUG_FUNCTION void +debug (gfc_typespec *ts) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -111,12 +113,14 @@ void debug (gfc_typespec *ts) dumpfile = tmp; } -void debug (gfc_typespec ts) +DEBUG_FUNCTION void +debug (gfc_typespec ts) { debug (&ts); } -void debug (gfc_ref *p) +DEBUG_FUNCTION void +debug (gfc_ref *p) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -125,7 +129,7 @@ void debug (gfc_ref *p) dumpfile = tmp; } -void +DEBUG_FUNCTION void debug (gfc_namespace *ns) { FILE *tmp = dumpfile; @@ -135,7 +139,7 @@ debug (gfc_namespace *ns) dumpfile = tmp; } -void +DEBUG_FUNCTION void gfc_debug_expr (gfc_expr *e) { FILE *tmp = dumpfile; @@ -147,7 +151,7 @@ gfc_debug_expr (gfc_expr *e) /* Allow for dumping of a piece of code in the debugger. */ -void +DEBUG_FUNCTION void gfc_debug_code (gfc_code *c) { FILE *tmp = dumpfile; @@ -157,7 +161,8 @@ gfc_debug_code (gfc_code *c) dumpfile = tmp; } -void debug (gfc_symbol *sym) +DEBUG_FUNCTION void +debug (gfc_symbol *sym) { FILE *tmp = dumpfile; dumpfile = stderr; @@ -2513,7 +2518,7 @@ show_code_node (int level, gfc_code *c) case EXEC_SYNC_MEMORY: fputs ("SYNC MEMORY ", dumpfile); if (c->expr2 != NULL) - { + { fputs (" stat=", dumpfile); show_expr (c->expr2); } @@ -4031,7 +4036,8 @@ gfc_dump_global_symbols (FILE *f) /* Show an array ref. */ -void debug (gfc_array_ref *ar) +DEBUG_FUNCTION void +debug (gfc_array_ref *ar) { FILE *tmp = dumpfile; dumpfile = stderr;