Message ID | 20240618224528.878425-1-rkir@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [1/3] exec: Make the MemOp enum cast explicit | expand |
On 6/18/24 15:45, Roman Kiryanov wrote: > to use the QEMU headers with a C++ compiler. > > Google-Bug-Id: 331190993 > Change-Id: I785f2e65d192287f1f964d2840131b653755648c > Signed-off-by: Roman Kiryanov <rkir@google.com> > --- > include/exec/memop.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/include/exec/memop.h b/include/exec/memop.h > index 06417ff361..f881fe7af4 100644 > --- a/include/exec/memop.h > +++ b/include/exec/memop.h > @@ -161,7 +161,7 @@ static inline MemOp size_memop(unsigned size) > /* Power of 2 up to 8. */ > assert((size & (size - 1)) == 0 && size >= 1 && size <= 8); > #endif > - return ctz32(size); > + return (MemOp)ctz32(size); > } > Reviewed-by: Richard Henderson <richard.henderson@linaro.org> r~
On 19/6/24 00:45, Roman Kiryanov wrote: > to use the QEMU headers with a C++ compiler. > > Google-Bug-Id: 331190993 > Change-Id: I785f2e65d192287f1f964d2840131b653755648c > Signed-off-by: Roman Kiryanov <rkir@google.com> > --- > include/exec/memop.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> and queued, thanks!
On 19/6/24 12:40, Philippe Mathieu-Daudé wrote: > On 19/6/24 00:45, Roman Kiryanov wrote: >> to use the QEMU headers with a C++ compiler. >> >> Google-Bug-Id: 331190993 I searched for this on https://developers.google.com/issue-tracker/concepts/searches but no hit, is this public information? >> Change-Id: I785f2e65d192287f1f964d2840131b653755648c >> Signed-off-by: Roman Kiryanov <rkir@google.com> >> --- >> include/exec/memop.h | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) > > Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> > > and queued, thanks!
diff --git a/include/exec/memop.h b/include/exec/memop.h index 06417ff361..f881fe7af4 100644 --- a/include/exec/memop.h +++ b/include/exec/memop.h @@ -161,7 +161,7 @@ static inline MemOp size_memop(unsigned size) /* Power of 2 up to 8. */ assert((size & (size - 1)) == 0 && size >= 1 && size <= 8); #endif - return ctz32(size); + return (MemOp)ctz32(size); } /* Big endianness from MemOp. */
to use the QEMU headers with a C++ compiler. Google-Bug-Id: 331190993 Change-Id: I785f2e65d192287f1f964d2840131b653755648c Signed-off-by: Roman Kiryanov <rkir@google.com> --- include/exec/memop.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)