Skip to content

Files

Latest commit

 

History

History
12 lines (7 loc) · 425 Bytes

modifies-value-receiver.md

File metadata and controls

12 lines (7 loc) · 425 Bytes

Pattern: Method modifies value receiver

Issue: -

Description

A method that modifies its receiver value can have undesired behavior. The modification can be also the root of a bug because the actual value receiver could be a copy of that used at the calling site. This rule warns when a method modifies its receiver.

Further Reading