Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.StringJoiner;

import org.jspecify.annotations.Nullable;

import org.springframework.util.Assert;
import org.springframework.util.ClassUtils;
import org.springframework.util.StringUtils;

/**
* {@link LinkedHashMap} subclass representing annotation attribute
Expand Down Expand Up @@ -396,8 +396,13 @@ private String valueToString(@Nullable Object value) {
if (value == this) {
return "(this Map)";
}
if (value instanceof Object[] objects) {
return "[" + StringUtils.arrayToDelimitedString(objects, ", ") + "]";
if (value != null && value.getClass().isArray()) {
int length = Array.getLength(value);
StringJoiner sj = new StringJoiner(", ", "[", "]");
for (int i = 0; i < length; i++) {
sj.add(valueToString(Array.get(value, i)));
}
return sj.toString();
}
return String.valueOf(value);
}
Expand Down
Loading