From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qv1-xf2f.google.com (mail-qv1-xf2f.google.com [IPv6:2607:f8b0:4864:20::f2f]) by sourceware.org (Postfix) with ESMTPS id BCBC9385743A for ; Tue, 11 Oct 2022 11:30:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org BCBC9385743A Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=kitware.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=kitware.com Received: by mail-qv1-xf2f.google.com with SMTP id o67so8286202qvo.13 for ; Tue, 11 Oct 2022 04:30:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kitware.com; s=google; h=user-agent:in-reply-to:content-disposition:mime-version:references :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=Wh0pDgIQudwywMWKPbh1fkJzmpyQQ8g9RTT+1jxpeUE=; b=qiajUuUxcgrNtSE5KSjf2le2rpYmKihELJkaiMMT3589dGLaHS6lG0cE5CF0naCLwF q6LO977mQyQo++VblxPdAPKCNxQGqS4oV6qsUhYye4vMZW+v/cTK02QFQ3Cv/ij8LWQC zngZJszXL19FznssNITKbMCIdetx/QPLC7c0w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=user-agent:in-reply-to:content-disposition:mime-version:references :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Wh0pDgIQudwywMWKPbh1fkJzmpyQQ8g9RTT+1jxpeUE=; b=vY63B4WyNZc7tfrd1Twc2jk1mBeTdaKhzFpELJ/reLPxY/lFIm2BUbmrX32jW2v/JJ u9aE9QSM+LUuPyXytXgVtxvZFbb/gjuzhBQN3xjAaPNbxhjI49hN6UzUzaKPpGlU6qGy VCF6fBqoS69K4ijoak/AnnL+9AmIQGcvHS7e+tp0tJu2XjWnoubJPQ6BDwYMiwbfuhKU Hs6F3Wz2+gjqo2FsOin6i+X25ZzTDzx6z0NbVKIDeXMTW0H70OHtikiMR8VTzxHz0Foh 0km3LLXbe3NONGvaDFEjqGqF8wTojyAmOqRKwIqeN3RARu2n3SvYn/KgC1+vWePaikIG y7UA== X-Gm-Message-State: ACrzQf0iq5vEb0Z+M8Hpzvuf6z/v/9H8ZXqS94pQeJB2u0EI9fWhHGpX n95QDqsCuHIbGhLvYeYWWlXCGA== X-Google-Smtp-Source: AMsMyM4UZci5Ejn/BTzUgSYITnmThnBMZWLLe7vnu443FQJCoPqdFVlszOklMahG7Jb0IGvj6GNV9A== X-Received: by 2002:a0c:b447:0:b0:4b3:cf2b:92f6 with SMTP id e7-20020a0cb447000000b004b3cf2b92f6mr15110975qvf.79.1665487824043; Tue, 11 Oct 2022 04:30:24 -0700 (PDT) Received: from localhost (cpe-142-105-146-128.nycap.res.rr.com. [142.105.146.128]) by smtp.gmail.com with ESMTPSA id dt27-20020a05620a479b00b006ed61f18651sm4688713qkb.16.2022.10.11.04.30.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Oct 2022 04:30:23 -0700 (PDT) Date: Tue, 11 Oct 2022 07:30:22 -0400 From: Ben Boeckel To: Harald Anlauf Cc: Ben Boeckel , gcc-patches@gcc.gnu.org, gcc@gcc.gnu.org, jason@redhat.com, brad.king@kitware.com, fortran@gcc.gnu.org, nathan@acm.org Subject: Re: [PATCH RESEND 1/1] p1689r5: initial support Message-ID: References: <20221004151200.1275636-1-ben.boeckel@kitware.com> <20221004151200.1275636-2-ben.boeckel@kitware.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.2.7 (2022-08-07) X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Tue, Oct 04, 2022 at 21:12:03 +0200, Harald Anlauf wrote: > Am 04.10.22 um 17:12 schrieb Ben Boeckel: > > This patch implements support for [P1689R5][] to communicate to a build > > system the C++20 module dependencies to build systems so that they may > > build `.gcm` files in the proper order. > > Is there a reason that you are touching so many frontends? Just those that needed the update for `cpp_finish`. It does align with those that will (eventually) need this support anyways (AFAIK). > > diff --git a/gcc/fortran/cpp.cc b/gcc/fortran/cpp.cc > > index 364bd0d2a85..0b9df9c02cd 100644 > > --- a/gcc/fortran/cpp.cc > > +++ b/gcc/fortran/cpp.cc > > @@ -712,7 +712,7 @@ gfc_cpp_done (void) > > FILE *f = fopen (gfc_cpp_option.deps_filename, "w"); > > if (f) > > { > > - cpp_finish (cpp_in, f); > > + cpp_finish (cpp_in, f, NULL); > > fclose (f); > > } > > else > > @@ -721,7 +721,7 @@ gfc_cpp_done (void) > > xstrerror (errno)); > > } > > else > > - cpp_finish (cpp_in, stdout); > > + cpp_finish (cpp_in, stdout, NULL); > > } > > > > cpp_undef_all (cpp_in); > > Couldn't you simply default the third argument of cpp_finish() to NULL? I could do that. Wasn't sure how much that would be acceptable given that it is a "silent" change, but it would reduce the number of files touched here. Thanks, --Ben