Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pybind11
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
pybind11
Commits
e0b8bbbc
Commit
e0b8bbbc
authored
May 15, 2019
by
Dan
Committed by
Wenzel Jakob
Jun 11, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use a file-local constant for non-prefixing nodes.
parent
2c8c5c4e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletions
+5
-1
tools/mkdoc.py
+5
-1
No files found.
tools/mkdoc.py
100644 → 100755
View file @
e0b8bbbc
...
@@ -41,6 +41,10 @@ PRINT_LIST = [
...
@@ -41,6 +41,10 @@ PRINT_LIST = [
CursorKind
.
FIELD_DECL
CursorKind
.
FIELD_DECL
]
]
PREFIX_BLACKLIST
=
[
CursorKind
.
TRANSLATION_UNIT
]
CPP_OPERATORS
=
{
CPP_OPERATORS
=
{
'<='
:
'le'
,
'>='
:
'ge'
,
'=='
:
'eq'
,
'!='
:
'ne'
,
'[]'
:
'array'
,
'<='
:
'le'
,
'>='
:
'ge'
,
'=='
:
'eq'
,
'!='
:
'ne'
,
'[]'
:
'array'
,
'+='
:
'iadd'
,
'-='
:
'isub'
,
'*='
:
'imul'
,
'/='
:
'idiv'
,
'
%
='
:
'+='
:
'iadd'
,
'-='
:
'isub'
,
'*='
:
'imul'
,
'/='
:
'idiv'
,
'
%
='
:
...
@@ -192,7 +196,7 @@ def extract(filename, node, prefix, output):
...
@@ -192,7 +196,7 @@ def extract(filename, node, prefix, output):
return
0
return
0
if
node
.
kind
in
RECURSE_LIST
:
if
node
.
kind
in
RECURSE_LIST
:
sub_prefix
=
prefix
sub_prefix
=
prefix
if
node
.
kind
!=
CursorKind
.
TRANSLATION_UNI
T
:
if
node
.
kind
not
in
PREFIX_BLACKLIS
T
:
if
len
(
sub_prefix
)
>
0
:
if
len
(
sub_prefix
)
>
0
:
sub_prefix
+=
'_'
sub_prefix
+=
'_'
sub_prefix
+=
d
(
node
.
spelling
)
sub_prefix
+=
d
(
node
.
spelling
)
...
...
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