Skip to content

Commit f37a868

Browse files
authored
Fix links to commands in API specification (KhronosGroup#1179)
Links were not created for commands defined by extensions. With this changes all uses of e.g. {clCreateSemaphoreWithPropertiesKHR} link to the definition of the command which makes navigating the specification much easier. Change-Id: I4a9458609f4ba3229b66e3d169a68cb4564e2538 Signed-off-by: Kevin Petit <kevin.petit@arm.com>
1 parent 13ecb48 commit f37a868

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

scripts/gen_dictionaries.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def GetFooter():
9999

100100
numberOfFuncs = numberOfFuncs + 1
101101

102-
# Add extension API functions without links:
102+
# Add extension API functions with and without links:
103103
for extension in spec.findall('extensions/extension/require'):
104104
for api in extension.findall('command'):
105105
name = api.get('name')
@@ -110,7 +110,8 @@ def GetFooter():
110110
# // clGetGLObjectInfo
111111
# :clGetGLObjectInfo: pass:q[*clGetGLObjectInfo*]
112112
apiLinkFile.write('// ' + name + '\n')
113-
apiLinkFile.write(':' + name + ': pass:q[*' + name + '*]\n')
113+
apiLinkFile.write(':' + name + '_label: pass:q[*' + name + '*]\n')
114+
apiLinkFile.write(':' + name + ': <<' + name + ',{' + name + '_label}>>\n')
114115
apiLinkFile.write('\n')
115116

116117
apiNoLinkFile.write('// ' + name + '\n')

0 commit comments

Comments
 (0)