You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "naren2605 (via GitHub)" <gi...@apache.org> on 2026/01/05 05:08:57 UTC
[PR] #8519 | adding warning messages on mutable methods initialised from List.of [netbeans]
naren2605 opened a new pull request, #9124:
URL: https://github.com/apache/netbeans/pull/9124
`warning hints on mutable methods used with immutable collections`
---
**warning hints on mutable methods used with immutable collections**
<details open>
it would be good to have hints showing some warning message("mutable method xyz cannot be used on immutable collection") when immutable collections are used with mutable methods.
example:
```
var immutableList = List.of(10,20);
immutableList.add(20);
```
```
var immutableList = List.of(10,20);
immutableList.remove(20);
```
@mbien as [8519](https://github.com/apache/netbeans/issues/8519) has been closed earlier with the reasons you have mentioned, i just want to bring up this pr once again and see if this meets the requirements or if still you see if this won't be possible, let me know.
cc: @lahodaj @jlahoda
</details>
--
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: notifications-unsubscribe@netbeans.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists