From: Timm Bäder Date: Sat, 17 Sep 2022 06:11:36 +0000 (+0200) Subject: [clang][Interp] Specify Boolean conversion operartors as (u)int32 X-Git-Tag: upstream/17.0.6~32136 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f927b71376c198a41f0c578be896bf231a6a5fd1;p=platform%2Fupstream%2Fllvm.git [clang][Interp] Specify Boolean conversion operartors as (u)int32 Follow up to https://reviews.llvm.org/D133934 --- diff --git a/clang/lib/AST/Interp/Boolean.h b/clang/lib/AST/Interp/Boolean.h index 20831ff..3122388a 100644 --- a/clang/lib/AST/Interp/Boolean.h +++ b/clang/lib/AST/Interp/Boolean.h @@ -46,14 +46,14 @@ class Boolean final { Boolean operator-() const { return Boolean(V); } Boolean operator~() const { return Boolean(true); } - explicit operator unsigned() const { return V; } explicit operator int8_t() const { return V; } explicit operator uint8_t() const { return V; } explicit operator int16_t() const { return V; } explicit operator uint16_t() const { return V; } + explicit operator int32_t() const { return V; } + explicit operator uint32_t() const { return V; } explicit operator int64_t() const { return V; } explicit operator uint64_t() const { return V; } - explicit operator int() const { return V; } explicit operator bool() const { return V; } APSInt toAPSInt() const {