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
d679811f
Commit
d679811f
authored
Mar 24, 2014
by
Victor Stinner
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #21036: Fix typo in macro name
_PY_HASHTABLE_ENTRY_DATA => _Py_HASHTABLE_ENTRY_DATA
parent
09ef03b5
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
6 deletions
+6
-6
Modules/_tracemalloc.c
Modules/_tracemalloc.c
+1
-1
Modules/hashtable.c
Modules/hashtable.c
+2
-2
Modules/hashtable.h
Modules/hashtable.h
+3
-3
No files found.
Modules/_tracemalloc.c
View file @
d679811f
...
...
@@ -1052,7 +1052,7 @@ tracemalloc_get_traces_fill(_Py_hashtable_entry_t *entry, void *user_data)
PyObject
*
tracemalloc_obj
;
int
res
;
trace
=
(
trace_t
*
)
_P
Y
_HASHTABLE_ENTRY_DATA
(
entry
);
trace
=
(
trace_t
*
)
_P
y
_HASHTABLE_ENTRY_DATA
(
entry
);
tracemalloc_obj
=
trace_to_pyobject
(
trace
,
get_traces
->
tracebacks
);
if
(
tracemalloc_obj
==
NULL
)
...
...
Modules/hashtable.c
View file @
d679811f
...
...
@@ -326,7 +326,7 @@ _Py_hashtable_set(_Py_hashtable_t *ht, const void *key,
entry
->
key_hash
=
key_hash
;
assert
(
data_size
==
ht
->
data_size
);
memcpy
(
_P
Y
_HASHTABLE_ENTRY_DATA
(
entry
),
data
,
data_size
);
memcpy
(
_P
y
_HASHTABLE_ENTRY_DATA
(
entry
),
data
,
data_size
);
_Py_slist_prepend
(
&
ht
->
buckets
[
index
],
(
_Py_slist_item_t
*
)
entry
);
ht
->
entries
++
;
...
...
@@ -504,7 +504,7 @@ _Py_hashtable_copy(_Py_hashtable_t *src)
err
=
1
;
}
else
{
data
=
_P
Y
_HASHTABLE_ENTRY_DATA
(
entry
);
data
=
_P
y
_HASHTABLE_ENTRY_DATA
(
entry
);
err
=
_Py_hashtable_set
(
dst
,
entry
->
key
,
data
,
src
->
data_size
);
}
if
(
err
)
{
...
...
Modules/hashtable.h
View file @
d679811f
...
...
@@ -26,16 +26,16 @@ typedef struct {
/* data follows */
}
_Py_hashtable_entry_t
;
#define _P
Y
_HASHTABLE_ENTRY_DATA(ENTRY) \
#define _P
y
_HASHTABLE_ENTRY_DATA(ENTRY) \
((char *)(ENTRY) + sizeof(_Py_hashtable_entry_t))
#define _Py_HASHTABLE_ENTRY_DATA_AS_VOID_P(ENTRY) \
(*(void **)_P
Y
_HASHTABLE_ENTRY_DATA(ENTRY))
(*(void **)_P
y
_HASHTABLE_ENTRY_DATA(ENTRY))
#define _Py_HASHTABLE_ENTRY_READ_DATA(TABLE, DATA, DATA_SIZE, ENTRY) \
do { \
assert((DATA_SIZE) == (TABLE)->data_size); \
memcpy(DATA, _P
Y
_HASHTABLE_ENTRY_DATA(ENTRY), DATA_SIZE); \
memcpy(DATA, _P
y
_HASHTABLE_ENTRY_DATA(ENTRY), DATA_SIZE); \
} while (0)
typedef
Py_uhash_t
(
*
_Py_hashtable_hash_func
)
(
const
void
*
key
);
...
...
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