pylint #7394 W0212 (access to protected member) not emited on assigments [validation pending]
Paul `Satoshi' Hachmann :Inline interpreted text or phrase reference start-string without end-string.
In the following code, the '_secret' protected member of SomeClass is accessed twice; once to set it and another to print it:
class SomeClass(object): def __init__(self): self._secret = 3 obj = SomeClass() obj._secret = 1 # Doesn't catch this! print "I am accessing", obj._secret # Produces W0212, as expected
However, the assignment statement by itself doesn't generate a W0212.
|closed by||#40de65ba89b2 Add checking for protected attribute assignement, closes #7394.|