mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 02:48:06 +02:00
glapi: Implement SET_xxx as inline functions instead of macros.
In order to have the benefit of type checking, and detect missing GLAPIENTRY keywords on public entrypoints.
This commit is contained in:
parent
f4a9868811
commit
ec4dfc2aad
2 changed files with 3716 additions and 929 deletions
|
|
@ -171,7 +171,10 @@ class PrintRemapTable(gl_XML.gl_print_base):
|
|||
|
||||
print '#define CALL_%s(disp, parameters) CALL_by_offset(disp, (%s), _gloffset_%s, parameters)' % (f.name, cast, f.name)
|
||||
print '#define GET_%s(disp) GET_by_offset(disp, _gloffset_%s)' % (f.name, f.name)
|
||||
print '#define SET_%s(disp, fn) SET_by_offset(disp, _gloffset_%s, fn)' % (f.name, f.name)
|
||||
print 'static void INLINE SET_%s(struct _glapi_table *disp, %s (GLAPIENTRYP fn)(%s)) {' % (f.name, f.return_type, arg_string)
|
||||
print ' SET_by_offset(disp, _gloffset_%s, fn);' % (f.name)
|
||||
print '}'
|
||||
print
|
||||
|
||||
if alias_functions:
|
||||
print ''
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
Loading…
Add table
Reference in a new issue