From nobody Wed Jan 31 01:38:54 2024 X-Original-To: toolchain@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TPl7L4pbxz5857c for ; Wed, 31 Jan 2024 01:38:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TPl7L231kz4GXw for ; Wed, 31 Jan 2024 01:38:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1706665134; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=jdd6PXLWafd1f7x/mUYI2IZuXtYADcpfCri/I9WyyvA=; b=B/5vaLo55Q6IKjfiWmqdY61QbuTpxerBCMR92BufHZ2Lo9WS+8ay61l4g8qd5LjLxGZdYu kd2noAI+6FMgumJVlem7xARnNzowmNIbwOfz04bVOeXdgMgzyKB+wDo4QS9Vi1O73ev2wt Gm5eaBMxXrHhjmPHuQ2ApzJLiPsRFDF17XCo23Gf6gQDHMrG+5To1Oz2V6h68G6+iFQZpH 2y+7Gp5QEusw0MrGpPtOQ8WdPIUHVDmdz/0T9qgXIXCF5NUM+zPbI7yrDsygSjJgGHA85S dRZPsRGEifWVgTlXso2AexKz5r8nN9oyY7WjUO5/iEgMuM1n2Pj5k4Bjbzjj+g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1706665134; a=rsa-sha256; cv=none; b=APRpD64U32nwvaBlY6sQBkDXKsUKl9DsnNu7hbZHy1p9QhXbZa0PMAJIP+rxCuBc4ZlCni Z7tVo8pnCRN5jedALlzDILhUVlWxszsambw6p/qiKwCcJdofshNzIfKXYNOuX9R99j8Hyo klU4d94LjQe24YLJjzrHWYFmKM7d61yk3EDi8tDnhXIfatT9cWHi8IGWxBONEwlLqf1in/ rNjDgSZgVSaGkFaWIA0CTROZMKWfotMg5c5tqZY/xsi6FsDuIyjvw3PiGZdSx/y3dd4ToF cWD4ldQ958tYfy0elb7VZ3NqovXS5VSTRH6Ik/4xvSxYB8H/IteumpEBv6ACwg== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TPl7L16Fjz102D for ; Wed, 31 Jan 2024 01:38:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 40V1cs6v046412 for ; Wed, 31 Jan 2024 01:38:54 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 40V1crtC046411 for toolchain@FreeBSD.org; Wed, 31 Jan 2024 01:38:53 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: toolchain@FreeBSD.org Subject: [Bug 276738] clang: static_assert conflicts with -std=c++98 -pedantic-errors Date: Wed, 31 Jan 2024 01:38:54 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: 14.0-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: marklmi26-fbsd@yahoo.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: toolchain@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Maintenance of FreeBSD s integrated toolchain List-Archive: https://lists.freebsd.org/archives/freebsd-toolchain List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-toolchain@freebsd.org X-BeenThere: freebsd-toolchain@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D276738 Mark Millard changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |marklmi26-fbsd@yahoo.com --- Comment #1 from Mark Millard --- static_assert was added to C++ in C++ 11: after C++ 98. The /usr/include/c++/v1/__algorithm/iterator_operations.h code: template _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR_SINCE_CXX14 static void __validate_iter_reference() { static_assert(is_same<__deref_t<_Iter>, typename iterator_traits<__remove_cvref_t<_Iter> >::reference>::value, "It looks like your iterator's `iterator_traits::reference` does not match the return type of " "dereferencing the iterator, i.e., calling `*it`. This is undefined behavior according to [input.iterators] " "and can lead to dangling reference issues at runtime, so we are flagging this."); } is not compliant with the C++98 standard. But . . . https://libcxx.llvm.org reports: QUOTE libc++ is a new implementation of the C++ standard library, targeting C++11= and above. Features and Goals Correctness as defined by the C++11 standard. END QUOTE So: Not a bug. FreeBSD gave up on C++98 when it decided to be based, in part, on libc++ . --=20 You are receiving this mail because: You are the assignee for the bug.=