aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/TextAPI/Architecture.cpp
diff options
context:
space:
mode:
authorTimm Baeder <tbaeder@redhat.com>2025-08-06 16:49:00 +0200
committerGitHub <noreply@github.com>2025-08-06 16:49:00 +0200
commit8704ca0fb8fb3c659a4e98e9362cd56d453dcb4b (patch)
treec2e49d091c10143c25697e1e36d5950c600f30da /llvm/lib/TextAPI/Architecture.cpp
parent75838b818bdbc14fc41f901b4e60821647009cf3 (diff)
downloadllvm-8704ca0fb8fb3c659a4e98e9362cd56d453dcb4b.zip
llvm-8704ca0fb8fb3c659a4e98e9362cd56d453dcb4b.tar.gz
llvm-8704ca0fb8fb3c659a4e98e9362cd56d453dcb4b.tar.bz2
[clang][ExprConst] Consider integer pointers of value 0 nullptr (#150164)
When casting a 0 to a pointer type, the IsNullPtr flag was always set to false, leading to weird results like a pointer with value 0 that isn't a null pointer. This caused ```c++ struct B { const int *p;}; template<B> void f() {} template void f<B{nullptr}>(); template void f<B{fold(reinterpret_cast<int*>(0))}>(); ``` to be valid code, since nullptr and (int*)0 aren't equal. This seems weird and GCC doesn't behave like this.
Diffstat (limited to 'llvm/lib/TextAPI/Architecture.cpp')
0 files changed, 0 insertions, 0 deletions