print
def retraceFunctionBody(self, function):
- if not function.sideeffects:
- print ' (void)call;'
- return
+ assert function.sideeffects
self.deserializeArgs(function)
self.swizzleValues(function)
def retraceInterfaceMethodBody(self, interface, method):
- if not method.sideeffects:
- print ' (void)call;'
- return
+ assert method.sideeffects
self.deserializeThisPointer(interface)
functions = filter(self.filterFunction, api.functions)
for function in functions:
- self.retraceFunction(function)
+ if function.sideeffects:
+ self.retraceFunction(function)
interfaces = api.getAllInterfaces()
for interface in interfaces:
for method in interface.iterMethods():
- self.retraceInterfaceMethod(interface, method)
+ if method.sideeffects:
+ self.retraceInterfaceMethod(interface, method)
print 'const retrace::Entry %s[] = {' % self.table_name
for function in functions:
- print ' {"%s", &retrace_%s},' % (function.name, function.name)
+ if function.sideeffects:
+ print ' {"%s", &retrace_%s},' % (function.name, function.name)
+ else:
+ print ' {"%s", &retrace::ignore},' % (function.name,)
for interface in interfaces:
- for method in interface.iterMethods():
- print ' {"%s::%s", &retrace_%s__%s},' % (interface.name, method.name, interface.name, method.name)
+ for method in interface.iterMethods():
+ if method.sideeffects:
+ print ' {"%s::%s", &retrace_%s__%s},' % (interface.name, method.name, interface.name, method.name)
+ else:
+ print ' {"%s::%s", &retrace::ignore},' % (interface.name, method.name)
print ' {NULL, NULL}'
print '};'
print