mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-02 07:32:52 +00:00
Don't leave IsUnsigned uninitialized in a default-constructed APSInt. Copying
such a structure has undefined behavior. Caught by -fsanitize=bool. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@170652 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2427773f2f
commit
e8ce626308
@ -23,7 +23,7 @@ class APSInt : public APInt {
|
||||
bool IsUnsigned;
|
||||
public:
|
||||
/// Default constructor that creates an uninitialized APInt.
|
||||
explicit APSInt() {}
|
||||
explicit APSInt() : IsUnsigned(false) {}
|
||||
|
||||
/// APSInt ctor - Create an APSInt with the specified width, default to
|
||||
/// unsigned.
|
||||
|
Loading…
Reference in New Issue
Block a user