Received: by 2002:ac0:8c9a:0:0:0:0:0 with SMTP id r26csp5480595ima; Tue, 5 Feb 2019 12:29:30 -0800 (PST) X-Google-Smtp-Source: AHgI3IZZ+a4xiqpvjoSlL0n/ywah9Fp5MnzWT8kNhEHh7i833vU3qpkak0Y01BjsTiZXMkupX0nb X-Received: by 2002:a17:902:9885:: with SMTP id s5mr7098365plp.52.1549398570672; Tue, 05 Feb 2019 12:29:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549398570; cv=none; d=google.com; s=arc-20160816; b=Qtja/YIQZqJkjYfz60sTx7ApteKMPiqONrMhydJRHBScVdCr5Rto2cZQcVT984sZmV r/qJ3htGsU6X2y08ueJ1ew9gQkRBqSD84+4iv7CEeNPMnghV8b8FozXcShM7EstqxpIX CbDVvacDiEJb3Ys2aBIb6gn6rsMOci5JzeRguDhbdwOW73HHx8Wa66/ay9e/KCjEk0P0 8gI+HKqvP34jAyxEUb0tcyYgSKTSfeg+YzkxMuy+OrCP6TT6VkaD8uQ9yPfDynLEqVXv /fGrNVn2XxSkJ/uP6YSUTI8pVk8gukRRXAb7nbWymU9Fa8FsR+gi0DE7yoBz4IvWLLe/ B0dw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=KV41r0ySdRCIWvH57UF0asBkzn1ocmazBDZUTljHxpY=; b=G77YmRDgl8iB/CMhQYa7OzvwItnrAtHfHvtuHUi5hTfCupZ4Ro77wjYAOHO8UsaSB7 etoVo9r5dZC83+XZrjrHF2OQSbdirMHB5OtvpajpnqPKvD0rL/tYKVsdGp+wt4OK5c1Q aIrIZH4nsJ7B3KQfkKCSFgeu/fOHr3mTV4c9Ld98lvRqutQcf4C06s/65FpmDLGo6zRA ca55p+LVbx6UwIyeY9UkRB3DV0YpYYDmbgCZN9riXWhRLY/SzGWoyqRoE91gHWvgp0su tRb7xL9r0ASIxLNcw53X0BA8Trx5PUbKqbOZUV/U5JYnEzqXlI92FV5QUM0jaIQ5SrOQ CeFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=bOBdxdJ0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n4si1989459pgm.487.2019.02.05.12.29.15; Tue, 05 Feb 2019 12:29:30 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=bOBdxdJ0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729569AbfBEU1U (ORCPT + 99 others); Tue, 5 Feb 2019 15:27:20 -0500 Received: from mail-ed1-f68.google.com ([209.85.208.68]:43784 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728946AbfBEU1U (ORCPT ); Tue, 5 Feb 2019 15:27:20 -0500 Received: by mail-ed1-f68.google.com with SMTP id f9so4001028eds.10 for ; Tue, 05 Feb 2019 12:27:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=KV41r0ySdRCIWvH57UF0asBkzn1ocmazBDZUTljHxpY=; b=bOBdxdJ0bx+DMdoSOTMFmkrPvTIX9MAvWHpYSq+Ne9sHuWa226w4iGAEFt3OaWZPCd A9GeRuuiG9iNK3MUHIJdzzWKJq61J5RR5CQSk/qWqWR1+Hs8RCxpVlUEXujbA0l5is/B vHazNEm7hgl32OWFHhhw3MZzA13G5uLo9+Y3H0nDXYE8tn711nwh8sO359q2Y3MFOjMv Yl9ETxdkhBTlV0P/gDGTyLfToMwTPpm+uQNnaqse0f3QAGmvxvkbxCi60EZd41bM1Lgs g4r2ZGec1QWpJoJHxxNKcLRUxp5aIN1HqcgszXG8ZgB90fKychoJOiza7k1XVlAKC1ET 4wPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=KV41r0ySdRCIWvH57UF0asBkzn1ocmazBDZUTljHxpY=; b=Okk9ycJJL1xrTvXoRrkL2mPet0t/p9FcijyfE5xse/awvjbkS2UO5F+0Rrq8txDFZ1 nsb3uDdZ09wtITuzVsPKJT1zhuGgKmpMtj6kwQ/JCCBZNXVckRALVv7FCspwL9xPxdvU aj0s/jnD3JSTeaLB+pJ/H5B/0i7b2fz/sAVGj274mttlm1SEcpIctKUy1f4ZoZQyoMnG ROyVl+h1FUOnrHNdF8dwhg9uHSYN1C37aUGCc9zGRr/Nb3cvB3wv8nitH68bnV9pzda/ QgDHXKBp9rxz+RflXe4TymdYYyPVHaLcyA5HvT9uwIQ8PP3uvYBanDPGce9TrsOwxvE0 rwCw== X-Gm-Message-State: AHQUAubSwjeqVCSOJcbLEtUjGvD81AK3MayNDBsbwbTf0E3PI2D3eJZ+ r9+j/aN0CJRsjLTVUjrVcb4= X-Received: by 2002:a50:f284:: with SMTP id f4mr5361041edm.77.1549398438662; Tue, 05 Feb 2019 12:27:18 -0800 (PST) Received: from ltop.local ([2a02:a03f:40eb:400:f595:6cb4:537e:4c4b]) by smtp.gmail.com with ESMTPSA id m10sm3149165eja.38.2019.02.05.12.27.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 05 Feb 2019 12:27:17 -0800 (PST) Date: Tue, 5 Feb 2019 21:27:15 +0100 From: Luc Van Oostenryck To: Rasmus Villemoes Cc: Andrew Morton , Kees Cook , Nick Desaulniers , Masahiro Yamada , linux-kernel@vger.kernel.org Subject: Re: [PATCH] build_bug.h: add wrapper for _Static_assert Message-ID: <20190205202714.7jeuvso4hyjrjy77@ltop.local> References: <20190203192401.29170-1-linux@rasmusvillemoes.dk> <20190204150916.f29d782b27f096e6c4c6d6cf@linux-foundation.org> <20190204151209.d6fae2c6466cb5c9c5814fd9@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 05, 2019 at 10:53:31AM +0100, Rasmus Villemoes wrote: > On 05/02/2019 00.12, Andrew Morton wrote: > >> > >> It would be (very) nice to actually use this macro in a few places so > >> it gets its build testing while in -next. > > > > ie, just about every BUILD_BUG_ON in mm/ could use this. Let's switch > > a few? > > > > Perhaps, but some make sense where they are, e.g. when iterating over > two arrays using one iterator variable, it's fine to assert they have > the same size just above the loop. And, unfortunately, static_assert() > is not quite a drop-in replacement for BUILD_BUG_ON even when the > argument is an ICE due to -Wdeclaration-after-statement. Yes, unfortunately. -- Luc