Add "Suspicious collection reassignment" inspection #KT-20626 Fixed
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
<html>
|
||||
<body>
|
||||
This inspection reports non-mutable <b>Collection</b> augmented assignment creates a new <b>Collection</b> under the hood.
|
||||
Example:
|
||||
<br /><br />
|
||||
|
||||
<pre>
|
||||
<b>var</b> list = listOf(1, 2, 3)
|
||||
list <b>+=</b> 4 // A new list is created
|
||||
</pre>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user