You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "Christine Poerschke (Jira)" <ji...@apache.org> on 2021/07/13 11:07:00 UTC

[jira] [Updated] (SOLR-15485) remove Collections.singleton.forEach use

     [ https://issues.apache.org/jira/browse/SOLR-15485?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christine Poerschke updated SOLR-15485:
---------------------------------------
    Summary: remove Collections.singleton.forEach use  (was: discourage Collections.singleton.forEach use)

> remove Collections.singleton.forEach use
> ----------------------------------------
>
>                 Key: SOLR-15485
>                 URL: https://issues.apache.org/jira/browse/SOLR-15485
>             Project: Solr
>          Issue Type: Task
>            Reporter: Christine Poerschke
>            Assignee: Christine Poerschke
>            Priority: Minor
>             Fix For: main (9.0), 8.10
>
>          Time Spent: 50m
>  Remaining Estimate: 0h
>
> For example
> {code}
> Collections.singleton(foo).parallelStream().forEach(c -> { c.bar(); });
> {code}
> or
> {code}
> Collections.singleton(foo).stream().forEach(c -> { c.bar(); });
> {code}
> should typically be equivalent to
> {code}
> foo.bar();
> {code}
> which is more concise.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org