#974841 ms-gsl: new clang test fails on s390x

Package:
src:ms-gsl
Source:
ms-gsl
Submitter:
Gianfranco Costamagna
Date:
2026-09-16 13:21:04 UTC
Severity:
important
Tags:
#974841#5
Date:
2020-11-15 13:11:06 UTC
From:
To:
Hello, looks like the new clang tests are failing on s390x, I don't know why...

I can say that removing
"flags" (set flags= on line 13 of entry file) to make it behave in a similar way with gcc works to shut down the errors

https://autopkgtest.ubuntu.com/packages/m/ms-gsl/hirsute/s390x


unfortunately, after doing that, there is still a failure on s390x with clang-11

cd /home/locutusofborg/ms-gsl-3.1.0/pippo/ms-gsl/tests && /usr/bin/clang++-11  -I/home/locutusofborg/ms-gsl-3.1.0/include -isystem /home/locutusofborg/ms-gsl-3.1.0/tests/googletest/googletest/include -O3 -DNDEBUG -fno-strict-aliasing -Wall -Wcast-align -Wconversion -Wctor-dtor-privacy -Werror -Wextra -Wpedantic -Wshadow -Wsign-conversion -Wno-deprecated-declarations -Weverything -Wno-c++98-compat -Wno-c++98-compat-pedantic -Wno-missing-braces -Wno-covered-switch-default -Wno-global-constructors -Wno-missing-prototypes -Wno-padded -Wno-unknown-attributes -Wno-used-but-marked-unused -Wno-weak-vtables -std=c++20 -o CMakeFiles/assertion_tests.dir/assertion_tests.cpp.o -c /home/locutusofborg/ms-gsl-3.1.0/tests/assertion_tests.cpp
In file included from /home/locutusofborg/ms-gsl-3.1.0/tests/notnull_tests.cpp:19:
/home/locutusofborg/ms-gsl-3.1.0/include/gsl/pointers:146:86: error: zero as null pointer constant [-Werror,-Wzero-as-null-pointer-constant]
auto operator<(const not_null<T>& lhs, const not_null<U>& rhs) -> decltype(lhs.get() < rhs.get())
                                                                                     ^
                                                                                     nullptr
/usr/bin/../lib/gcc/s390x-linux-gnu/10/../../../../include/c++/10/bits/shared_ptr.h:448:5: note: while rewriting comparison as call to 'operator<=>' declared here
    operator<=>(const shared_ptr<_Tp>& __a,
    ^
/home/locutusofborg/ms-gsl-3.1.0/tests/notnull_tests.cpp:363:34: note: while substituting deduced template arguments into function template 'operator<' [with T = std::shared_ptr<int>, U = std::shared_ptr<int>]
    EXPECT_TRUE((NotNullSp1(sp1) < NotNullSp1(sp1)) == false);
                                 ^
In file included from /home/locutusofborg/ms-gsl-3.1.0/tests/notnull_tests.cpp:19:
/home/locutusofborg/ms-gsl-3.1.0/include/gsl/pointers:146:86: error: zero as null pointer constant [-Werror,-Wzero-as-null-pointer-constant]
auto operator<(const not_null<T>& lhs, const not_null<U>& rhs) -> decltype(lhs.get() < rhs.get())
                                                                                     ^
                                                                                     nullptr
/usr/bin/../lib/gcc/s390x-linux-gnu/10/../../../../include/c++/10/bits/shared_ptr.h:448:5: note: while rewriting comparison as call to 'operator<=>' declared here
    operator<=>(const shared_ptr<_Tp>& __a,
    ^
/home/locutusofborg/ms-gsl-3.1.0/tests/notnull_tests.cpp:364:34: note: while substituting deduced template arguments into function template 'operator<' [with T = std::shared_ptr<int>, U = std::shared_ptr<const int>]
    EXPECT_TRUE((NotNullSp1(sp1) < NotNullSp2(sp2)) == (sp1 < sp2));
                                 ^
/home/locutusofborg/ms-gsl-3.1.0/tests/notnull_tests.cpp:364:61: error: zero as null pointer constant [-Werror,-Wzero-as-null-pointer-constant]
    EXPECT_TRUE((NotNullSp1(sp1) < NotNullSp2(sp2)) == (sp1 < sp2));
                                                            ^
                                                            nullptr

(full log attached)

Can you please have a look? this error might be a real error spotted by clang-11 (and maybe when optimization level is set to -O3? I don't honestly know)

thanks

Gianfranco

#974841#10
Date:
2026-09-14 17:59:11 UTC
From:
To:
Hello,

Bug #974841 in ms-gsl reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/debian/ms-gsl/-/commit/235747d6b585f57b2af806a2e5a28cc0ad720f9f
------------------------------------------------------------------------
Enable Clang tests on s390x

At least, they do not fail in emulator anymore. Fixed somehow.

Closes: #974841
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/974841

#974841#17
Date:
2026-09-16 13:19:47 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
ms-gsl, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 974841@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Nicholas Guriev <guriev-ns@ya.ru> (supplier of updated ms-gsl package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Wed, 16 Sep 2026 14:30:25 +0300
Source: ms-gsl
Architecture: source
Version: 5.0.0-1
Distribution: unstable
Urgency: medium
Maintainer: Nicholas Guriev <guriev-ns@ya.ru>
Changed-By: Nicholas Guriev <guriev-ns@ya.ru>
Closes: 974841
Changes:
 ms-gsl (5.0.0-1) unstable; urgency=medium
 .
   * New upstream release.
   * Run autopkgtests directly with ctest(1).
   * Upgrade to Debhelper compatibility level 14.
   * Upgrade standards version to 4.7.4.
   * Set Dpkg build API level equal to 1.
   * Enable Clang tests on s390x (Closes: #974841).
   * Add autopkgtests with C++26.
   * Migrate to d/watch of version 5.
Checksums-Sha1:
 d808cd32a11873019d2ca1c4be9e72a5556cbd6a 1490 ms-gsl_5.0.0-1.dsc
 0d389a5bf53ce384be0a3bdcff9d336a8e383605 75108 ms-gsl_5.0.0.orig.tar.gz
 c7562d82322ac06c766de2259162788f6338cf88 6112 ms-gsl_5.0.0-1.debian.tar.xz
Checksums-Sha256:
 2ab605ae992ba90343bf21185e47103dbfa772a3510851fe0f4bf5711e0c79ca 1490 ms-gsl_5.0.0-1.dsc
 e646da6ac00a885cfae33dc935e52bb42bd1d05e41b8437cbc25ca3d74930f35 75108 ms-gsl_5.0.0.orig.tar.gz
 d81a4e7e807bd562926079e9866c14e3b076d0b4f2168b06b9e0fb40aecede0f 6112 ms-gsl_5.0.0-1.debian.tar.xz
Files:
 0667421dcdd1f5ae3eb6ec4de085a320 1490 libdevel - ms-gsl_5.0.0-1.dsc
 49a376b5c612748795a853b7cdbd04ee 75108 libdevel - ms-gsl_5.0.0.orig.tar.gz
 5bce1aff370990de65ab35afb2ae07d8 6112 libdevel - ms-gsl_5.0.0-1.debian.tar.xz
-----BEGIN PGP SIGNATURE-----

iIYEARYIAC4WIQQRm7llN8yxifaG60cF2qh9JI3wlQUCaqqUKRAcZ3VyaWV2LW5z
QHlhLnJ1AAoJEAXaqH0kjfCVXFEBAO3vqRIgcboeQSFjM1leoJmvzdsbeUB+FqFX
ySHs0wKvAP9mFfc2zWUvCn3uoAJwpHpdRcQdthpYj4ZtyCJNckzVDA==
=RsVG
-----END PGP SIGNATURE-----