This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG95ce9fbc235a: [clang] Do not crash on pointer wchar_t
pointer assignment. (authored by adamcz).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE
hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.
Thanks!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91625/new/
https://reviews.llvm.org/D91625
__
adamcz added inline comments.
Comment at: clang/lib/Sema/SemaExpr.cpp:8726
+else if (!lhptee->isWideCharType() &&
+ lhptee->hasSignedIntegerRepresentation())
ltrans = S.Context.getCorrespondingUnsignedType(ltrans);
hokein wrote:
> I'm wonde
adamcz updated this revision to Diff 306108.
adamcz added a comment.
addressed review comment
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91625/new/
https://reviews.llvm.org/D91625
Files:
clang/lib/AST/ASTContext.cpp
clang/test/SemaCXX/wchar
hokein added inline comments.
Comment at: clang/lib/Sema/SemaExpr.cpp:8726
+else if (!lhptee->isWideCharType() &&
+ lhptee->hasSignedIntegerRepresentation())
ltrans = S.Context.getCorrespondingUnsignedType(ltrans);
I'm wondering whether the
adamcz created this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
adamcz requested review of this revision.
wchar_t can be signed (thus hasSignedIntegerRepresentation() returns
true), but it doesn't have an unsigned type, which would lead to a crash
when trying t
adamcz updated this revision to Diff 305752.
adamcz added a comment.
rebase
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91625/new/
https://reviews.llvm.org/D91625
Files:
clang/lib/Sema/SemaExpr.cpp
clang/test/SemaCXX/wchar_t.cpp
Index: cla