Skip to content

Commit 08aecce

Browse files
authored
Add some docs to gen_sig_info.py. NFC (#23281)
1 parent d640c42 commit 08aecce

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tools/maint/gen_sig_info.py

+6
Original file line numberDiff line numberDiff line change
@@ -166,10 +166,16 @@
166166

167167

168168
def ignore_symbol(s, cxx):
169+
# We need to ignore certain symbols here. Specifically, any symbol that is not
170+
# pre-declared in a C/C++ header need to be ignored, otherwise the generated
171+
# file will fail to compile.
169172
if s.startswith('$'):
170173
return True
171174
if s in {'SDL_GetKeyState'}:
172175
return True
176+
# Symbols that start with `emscripten_gl` or `emscripten_alc` are auto-generated
177+
# wrappers around GL and OpenGL symbols. Since they inherit their signature they
178+
# don't need to be auto-generated.
173179
if s.startswith('emscripten_gl') or s.startswith('emscripten_alc'):
174180
return True
175181
if s.startswith('gl') and any(s.endswith(x) for x in ('NV', 'EXT', 'WEBGL', 'ARB', 'ANGLE')):

0 commit comments

Comments
 (0)