Title: ast module docs document private attribute
Type: behavior Stage:
Components: None, Documentation Versions: Python 3.0, Python 2.6
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: georg.brandl Nosy List: brett.cannon, georg.brandl, loewis, rhettinger
Priority: critical Keywords: 26backport, easy

Created on 2008-06-20 20:36 by brett.cannon, last changed 2008-06-20 21:59 by loewis. This issue is now closed.

Messages (4)
msg68473 - (view) Author: Brett Cannon (brett.cannon) * (Python committer) Date: 2008-06-20 20:36
The docs for the ast module document the '_fields' attribute on AST
instances. Either that documentation needs to go away or the attribute
needs to be renamed as the leading underscore means it is private to the
internal API.
msg68474 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2008-06-20 20:41
I disagree. The AST classes are auto-generated, the leading underscore
of _fields is there to avoid clashes with field names from the AST types.

This is similar to
which shouldn't be renamed, but isn't private either.
msg68476 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2008-06-20 21:04
This is consistent with the methods in named tuples (also to avoid name 
msg68480 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2008-06-20 21:59
I agree with Georg and Raymond, closing this as "won't fix".
Date User Action Args
2008-06-20 21:59:49loewissetstatus: open -> closed
nosy: + loewis
resolution: wont fix
messages: + msg68480
2008-06-20 21:04:27rhettingersetkeywords: + 26backport
nosy: + rhettinger
messages: + msg68476
components: + None
2008-06-20 20:41:32georg.brandlsetmessages: + msg68474
2008-06-20 20:36:33brett.cannoncreate