[clang] [clang][Sema] Avoid assert when diagnosing address-space qualified new/delete (PR #178424)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 28 06:34:55 PST 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results
* 85938 tests passed
* 1222 tests skipped
* 1 test failed
## Failed Tests
(click on a test name to see its output)
### Clang
<details>
<summary>Clang.SemaCXX/address-space-newdelete.cpp</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 1
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -cc1 -internal-isystem /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lib/clang/23/include -nostdsysteminc -fsyntax-only -verify /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/clang -cc1 -internal-isystem /home/gha/actions-runner/_work/llvm-project/llvm-project/build/lib/clang/23/include -nostdsysteminc -fsyntax-only -verify /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp
# .---command stderr------------
# | error: 'expected-error' diagnostics expected but not seen:
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 9: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 10: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 11: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 12: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 15: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 16: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 17: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 18: 'new' cannot allocate objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 22: 'delete' cannot delete objects of type 'int' in address space '1'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 23: 'delete' cannot delete objects of type 'int' in address space '1'
# | error: 'expected-error' diagnostics seen but not expected:
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 9: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 10: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 11: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 12: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 15: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 16: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 17: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 18: 'new' cannot allocate objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 22: 'delete' cannot delete objects of type 'int' in address space '__attribute__((address_space(1)))'
# | File /home/gha/actions-runner/_work/llvm-project/llvm-project/clang/test/SemaCXX/address-space-newdelete.cpp Line 23: 'delete' cannot delete objects of type 'int' in address space '__attribute__((address_space(1)))'
# | 20 errors generated.
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.
https://github.com/llvm/llvm-project/pull/178424
More information about the cfe-commits
mailing list