X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=specs%2Fscripts%2Fglspec.py;h=f21b08d5bf82f6670ecea07a44a77d537cfc4f24;hb=db3491e272f3754676673d52c89238e9cc43b7ad;hp=ab5957a7d19d4dba78d849cfd366743503cf295d;hpb=44756655362254679ae8b6ecad66104175b5e773;p=apitrace diff --git a/specs/scripts/glspec.py b/specs/scripts/glspec.py index ab5957a..f21b08d 100755 --- a/specs/scripts/glspec.py +++ b/specs/scripts/glspec.py @@ -235,12 +235,16 @@ class SpecParser(LineParser): try: int(length) except ValueError: - length = "%s" % length + length = '"%s"' % length arg_type = '%s(%s, %s)' % (constructor, base_type, length) else: - length = length.replace("COMPSIZE", "__%s_size" % function_name) - length = length.replace("/", ", ") - arg_type = 'Opaque%s(%s, %s)' % (constructor, base_type, length) + if length == "COMPSIZE(pname)": + length = "_gl_param_size(pname)" + arg_type = '%s(%s, "%s")' % (constructor, base_type, length) + else: + length = length.replace("COMPSIZE", "_%s_size" % function_name) + length = length.replace("/", ", ") + arg_type = 'Opaque%s(%s, "%s")' % (constructor, base_type, length) else: assert False