Inspectopedia
 
2024.3

'this' reference escaped in object construction

Warning
New
Last modified: 03 December 2024

Reports possible escapes of this during the object initialization. The escapes occur when this is used as a method argument or an object of assignment in a constructor or initializer. Such escapes may result in subtle bugs, as the object is now available in the context where it is not guaranteed to be initialized.

Example: