Summary: | math/sprng: BROKEN with recent clang | ||
---|---|---|---|
Product: | Base System | Reporter: | Thierry Thomas <thierry> |
Component: | bin | Assignee: | freebsd-toolchain (Nobody) <toolchain> |
Status: | Closed FIXED | ||
Severity: | Affects Only Me | CC: | dim |
Priority: | --- | ||
Version: | 15.0-CURRENT | ||
Hardware: | Any | ||
OS: | Any |
Description
Thierry Thomas
2024-05-03 07:43:58 UTC
I would guess that the code in question has "using namespace std;" at the top? That is most likely the cause for this error: the local variable name 'stack' now conflicts with 'std::stack'. It would be more correct to remove the "using namespace std;" statement and fix up the instances of std types used in the source, but an easier fix is to rename the local 'stack' variable to something else, for instance 'stack_' or 'my_stack'. Committed, thanks Dimitry! A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=d05586213892764617a96edec7151b464b1906ff commit d05586213892764617a96edec7151b464b1906ff Author: Thierry Thomas <thierry@FreeBSD.org> AuthorDate: 2024-05-04 13:21:44 +0000 Commit: Thierry Thomas <thierry@FreeBSD.org> CommitDate: 2024-05-04 13:32:02 +0000 math/sprng: fix build with clang 18 This is not a bug of clang. Patch suggested by dim@. PR: 278711 .../files/patch-TESTS_mpitests_wolff.cpp (new) | 37 ++++++++++++++++++++++ math/sprng/files/patch-TESTS_wolff.cpp (new) | 37 ++++++++++++++++++++++ math/sprng/files/patch-TESTS_wolfftest.cpp (new) | 37 ++++++++++++++++++++++ 3 files changed, 111 insertions(+) |