Skip to content

Commit

Permalink
JNI: fix declaration of ElementType in QJniArray::makeObjectArray
Browse files Browse the repository at this point in the history
List might be a reference type, in which case it won't have any members.

Pick-to: 6.7
Change-Id: Iac2c08c42f31ebc67b31be157f73ae318d328a18
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
  • Loading branch information
vohi committed Jan 31, 2024
1 parent 43f66e6 commit ddc67dc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/corelib/kernel/qjniarray.h
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ auto QJniArrayBase::makeArray(List &&list, NewFn &&newArray, SetFn &&setRegion)
template <typename List>
auto QJniArrayBase::makeObjectArray(List &&list)
{
using ElementType = typename List::value_type;
using ElementType = typename q20::remove_cvref_t<List>::value_type;
if (list.isEmpty())
return QJniArray<jobject>();

Expand Down

0 comments on commit ddc67dc

Please sign in to comment.