[Python-projects] nice-to-have: analyze (some) strings for variable use
skip at pobox.com
skip at pobox.com
Wed Jul 8 12:58:31 CEST 2009
In this function pylint complains that a and b are unused:
def f(a):
b = "some var"
return "%(a)s, %(b)s" % locals()
It would be nice if it noticed literal % locals() structure and treated
variable references within the string as actual usage.
Thx,
--
Skip Montanaro - skip at pobox.com - http://www.smontanaro.net/
when i wake up with a heart rate below 40, i head right for the espresso
machine. -- chaos @ forums.usms.org
More information about the Python-Projects
mailing list