Closed
Description
Bug Report
A lot of tests fail on FreeBSD with the following output:
_________________________________ testBuiltins _________________________________
data: /work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/test-data/run-misc.test:47:
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/test/test_run.py:144: in run_case
self.run_case_inner(testcase)
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/test/test_run.py:160: in run_case_inner
self.run_case_step(testcase, step)
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/test/test_run.py:272: in run_case_step
assert False, "Compilation failed"
E AssertionError: Compilation failed
E assert False
----------------------------- Captured stdout call -----------------------------
running build_ext
building 'native' extension
creating build/temp.freebsd-13.1-RELEASE-amd64-cpython-39
creating build/temp.freebsd-13.1-RELEASE-amd64-cpython-39/build
cc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -fPIC -I/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/lib-rt -I/usr/local/include/python3.9 -c build/__native.c -o build/temp.freebsd-13.1-RELEASE-amd64-cpython-39/build/__native.o -O0 -g1 -Werror -Wno-unused-function -Wno-unused-label -Wno-unreachable-code -Wno-unused-variable -Wno-unused-command-line-argument -Wno-unknown-warning-option
----------------------------- Captured stderr call -----------------------------
In file included from build/__native.c:4:
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/lib-rt/int_ops.c:547:30: error: shifting a negative signed value is undefined [-Werror,-Wshift-negative-value]
if (y == -1 && x == -1LL << 63) {
~~~~ ^
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/lib-rt/int_ops.c:565:30: error: shifting a negative signed value is undefined [-Werror,-Wshift-negative-value]
if (y == -1 && x == -1LL << 63) {
~~~~ ^
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/lib-rt/int_ops.c:610:30: error: shifting a negative signed value is undefined [-Werror,-Wshift-negative-value]
if (y == -1 && x == -1LL << 31) {
~~~~ ^
/work/usr/ports/devel/py-mypy/work-py39/mypy-0.981/mypyc/lib-rt/int_ops.c:628:30: error: shifting a negative signed value is undefined [-Werror,-Wshift-negative-value]
if (y == -1 && x == -1LL << 31) {
~~~~ ^
4 errors generated.
Your Environment
- Mypy version used: 0.981
- Mypy command-line flags: -
- Mypy configuration options from
mypy.ini
(and other config files): - - Python version used: 3.10.7
- FreeBSD 13.1
- Clang 13.0.0