From owner-freebsd-stable@freebsd.org Fri Aug 25 07:15:01 2017 Return-Path: Delivered-To: freebsd-stable@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9F76DDF1721 for ; Fri, 25 Aug 2017 07:15:01 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: from mail-yw0-x22a.google.com (mail-yw0-x22a.google.com [IPv6:2607:f8b0:4002:c05::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 64FD3763B7 for ; Fri, 25 Aug 2017 07:15:01 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: by mail-yw0-x22a.google.com with SMTP id h127so8829159ywf.3 for ; Fri, 25 Aug 2017 00:15:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nuxi-nl.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=g2DTfZoMebmJh2RzdfhBmnMV+mEIa9ANAGkPWa8fN18=; b=XdY6n85AI4F+VOihOJ9lUK4Ie6b2nk7NcO7w2tFYbOTDeIyJIkLgCGxOM6/n7R5Ywb PG6AxXf0Pj+9ZeMaAR9c5KKPvTcGBSeqPkFgoPrs53CizcMMFLf8IwDPEoL0ARH2w5jk sDWxqL+ijG/b7pLNE3AMIrDFoxJK9rLsob+4CKWWcIk6O0jCZk+Aqk9RVHbMTwO1wXgf oQIgsa91jTimPBkVGRM2i4sG5jvutXbvyK3GmAR/T4T8fDYOUyFgfbT80oNstaUkFbk6 TeJSrUFe04sk+EDIaRP5niElUNLLDQZdfmwd6jZlp0EyZcu7eFxKrHi6W0OYEqYhWC+p pJ6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=g2DTfZoMebmJh2RzdfhBmnMV+mEIa9ANAGkPWa8fN18=; b=LCxh+pnHnTW64TTtWJz+hQ+a9vwct0SV9h2oUojIqQfTyxpIls8Vky67xRUl5EaEVW 2RvyugzGfjfaMRjCiwZ8NW7+fmfbA88zCauIik2t8Vcq7MdJIE8mCIHy1XTKFn9OWK2+ NXCFKGMhKjGb9GR5dmRc9Rg/sqlnkOp2/C2TyjniTw+0XhEczC5h1HuhJFkYtRv/Cs26 BrqqeEExqXu1kJxoMRewJy0iX9hpX3pFUlXAd8aukoeuf/MTWpjrqhM0nmvlDLF5H81y xjqMLBy8yjFHury33jsQDgg57C6e8c2H4SynQmEBy8ogyFNoiN7QWiEm4KROtWCEjJBc EN2g== X-Gm-Message-State: AHYfb5hUL/sUrFxDH0MQI+dBpMnLXoLfI8SCI1gpRlqJn0vDJ24Qhbzs +s5lZWt4NOiVtFbn1UbcNEmtptcrtUfI X-Received: by 10.129.44.85 with SMTP id s82mr7075965yws.254.1503645300382; Fri, 25 Aug 2017 00:15:00 -0700 (PDT) MIME-Version: 1.0 Received: by 10.13.227.193 with HTTP; Fri, 25 Aug 2017 00:14:29 -0700 (PDT) In-Reply-To: <1C5A448F-C91A-4599-8500-E4E46E6F5205@dsl-only.net> References: <1C5A448F-C91A-4599-8500-E4E46E6F5205@dsl-only.net> From: Ed Schouten Date: Fri, 25 Aug 2017 09:14:29 +0200 Message-ID: Subject: Re: svn commit: r322875 - head/sys/dev/nvme To: Mark Millard Cc: Warner Losh , svn-src-head@freebsd.org, FreeBSD Current , FreeBSD-STABLE Mailing List , freebsd-hackers Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Aug 2017 07:15:01 -0000 2017-08-25 8:32 GMT+02:00 Mark Millard : >> # g++49 main.cc >> main.cc:2:15: error: expected constructor, destructor, or type conversion before '(' token >> _Static_assert(1,"Test"); Yeah, that's because GCC is such a pain in the neck compiler that it doesn't want to expose these C11 keywords when building C++, even though they are in the reserved namespace (_[A-Z]). GCC would be permitted to expose these and still comply to standards. Doing so would make things so much easier for operating system implementors, like us. Clang does get it right, in my opinion. We should just extend to define _Static_assert() when using GCC in C++ mode (if we're not doing so already). -- Ed Schouten Nuxi, 's-Hertogenbosch, the Netherlands KvK-nr.: 62051717