Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
62c2fac9
Commit
62c2fac9
authored
Oct 24, 2005
by
Neal Norwitz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not pollute name block_ty, prefix with _Py_
parent
6ab080cd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
Include/symtable.h
Include/symtable.h
+3
-3
Python/symtable.c
Python/symtable.c
+3
-3
No files found.
Include/symtable.h
View file @
62c2fac9
...
...
@@ -5,7 +5,7 @@ extern "C" {
#endif
typedef
enum
_block_type
{
FunctionBlock
,
ClassBlock
,
ModuleBlock
}
block_ty
;
_Py_
block_ty
;
struct
_symtable_entry
;
...
...
@@ -29,7 +29,7 @@ typedef struct _symtable_entry {
PyObject
*
ste_name
;
/* string: name of block */
PyObject
*
ste_varnames
;
/* list of variable names */
PyObject
*
ste_children
;
/* list of child ids */
block_ty
ste_type
;
/* module, class, or function */
_Py_block_ty
ste_type
;
/* module, class, or function */
int
ste_unoptimized
;
/* false if namespace is optimized */
int
ste_nested
:
1
;
/* true if block is nested */
int
ste_free
:
1
;
/* true if block has free variables */
...
...
@@ -49,7 +49,7 @@ PyAPI_DATA(PyTypeObject) PySTEntry_Type;
#define PySTEntry_Check(op) ((op)->ob_type == &PySTEntry_Type)
PyAPI_FUNC
(
PySTEntryObject
*
)
\
PySTEntry_New
(
struct
symtable
*
,
identifier
,
block_ty
,
void
*
,
int
);
PySTEntry_New
(
struct
symtable
*
,
identifier
,
_Py_
block_ty
,
void
*
,
int
);
PyAPI_FUNC
(
int
)
PyST_GetScope
(
PySTEntryObject
*
,
PyObject
*
);
PyAPI_FUNC
(
struct
symtable
*
)
PySymtable_Build
(
mod_ty
,
const
char
*
,
...
...
Python/symtable.c
View file @
62c2fac9
...
...
@@ -12,7 +12,7 @@
"name '%.400s' is used prior to global declaration"
PySTEntryObject
*
PySTEntry_New
(
struct
symtable
*
st
,
identifier
name
,
block_ty
block
,
PySTEntry_New
(
struct
symtable
*
st
,
identifier
name
,
_Py_
block_ty
block
,
void
*
key
,
int
lineno
)
{
PySTEntryObject
*
ste
=
NULL
;
...
...
@@ -153,7 +153,7 @@ PyTypeObject PySTEntry_Type = {
static
int
symtable_analyze
(
struct
symtable
*
st
);
static
int
symtable_warn
(
struct
symtable
*
st
,
char
*
msg
);
static
int
symtable_enter_block
(
struct
symtable
*
st
,
identifier
name
,
block_ty
block
,
void
*
ast
,
int
lineno
);
_Py_
block_ty
block
,
void
*
ast
,
int
lineno
);
static
int
symtable_exit_block
(
struct
symtable
*
st
,
void
*
ast
);
static
int
symtable_visit_stmt
(
struct
symtable
*
st
,
stmt_ty
s
);
static
int
symtable_visit_expr
(
struct
symtable
*
st
,
expr_ty
s
);
...
...
@@ -711,7 +711,7 @@ symtable_exit_block(struct symtable *st, void *ast)
}
static
int
symtable_enter_block
(
struct
symtable
*
st
,
identifier
name
,
block_ty
block
,
symtable_enter_block
(
struct
symtable
*
st
,
identifier
name
,
_Py_
block_ty
block
,
void
*
ast
,
int
lineno
)
{
PySTEntryObject
*
prev
=
NULL
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment