uschindler commented on code in PR #15821:
URL: https://github.com/apache/lucene/pull/15821#discussion_r2942373216
##########
lucene/core/src/java/org/apache/lucene/search/BooleanQuery.java:
##########
@@ -129,7 +128,7 @@ public BooleanQuery build() {
private BooleanQuery(int minimumNumberShouldMatch, BooleanClause[] clauses) {
this.minimumNumberShouldMatch = minimumNumberShouldMatch;
- this.clauses = Collections.unmodifiableList(Arrays.asList(clauses));
+ this.clauses = List.of(clauses);
Review Comment:
it is a varargs parameter and based on the types the compiler will guess to
use the List.of() with the varrags array, because otherwise the types won't fit.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]