]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Make _symtable_entry.ste_type's comment consistent wit _Py_block_ty (#92414)
authorzikcheng <surfingbyte@gmail.com>
Fri, 7 Oct 2022 17:53:07 +0000 (01:53 +0800)
committerGitHub <noreply@github.com>
Fri, 7 Oct 2022 17:53:07 +0000 (10:53 -0700)
_Py_block_ty defines four types of block, FunctionBlock, ClassBlock, ModuleBlock and AnnotationBlock.
But _symtable_entry.ste_type only comments three of them, I think it's better both sides are consistent.

Include/internal/pycore_symtable.h

index 2d64aba22ff9052289679a23dcc254d6ad554562..8532646ce7d95cb372b5eeefe28d6c489e9414e6 100644 (file)
@@ -49,7 +49,7 @@ typedef struct _symtable_entry {
     PyObject *ste_varnames;  /* list of function parameters */
     PyObject *ste_children;  /* list of child blocks */
     PyObject *ste_directives;/* locations of global and nonlocal statements */
-    _Py_block_ty ste_type;   /* module, class or function */
+    _Py_block_ty ste_type;   /* module, class, function or annotation */
     int ste_nested;      /* true if block is nested */
     unsigned ste_free : 1;        /* true if block has free variables */
     unsigned ste_child_free : 1;  /* true if a child block has free vars,