forked from Dav1dde/glad
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
parse: honors api in require instruction
The API in the require was honored before, but when the symbol from one API require referenced the symbol from a different API require through an alias, it was still brought in. gh: Dav1dde#281
- Loading branch information
Showing
4 changed files
with
65 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* | ||
* VK_NV_ray_tracing depends on a type which depends on an aliased type. | ||
* The aliased type is not part of the feature set. | ||
* Make sure the aliased type is part generated, since the alias is done through a typedef. | ||
* | ||
* GLAD: $GLAD --out-path=$tmp --api="vulkan=1.1" --extensions="VK_NV_ray_tracing" c | ||
* COMPILE: $GCC $test -o $tmp/test -I$tmp/include $tmp/src/vulkan.c -ldl | ||
* RUN: $tmp/test | ||
*/ | ||
|
||
#include <glad/vulkan.h> | ||
|
||
int main(void) { | ||
/* make sure something is referenced so stuff doesn't just get optimized away */ | ||
VkAccelerationStructureMemoryRequirementsInfoNV unused; | ||
(void) unused; | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* | ||
* The GL_KHR_debug has suffixed symbols for GLES but symbols without suffix for GL. | ||
* Make sure only the suffixed symbols appear in the generated output for gles. | ||
* Related Issues: #281 | ||
* | ||
* See also: 004 | ||
* | ||
* GLAD: $GLAD --out-path=$tmp --api="gles2=3.1" --extensions="GL_KHR_debug" c | ||
* COMPILE: ! $GCC $test -o $tmp/test -I$tmp/include $tmp/src/gles2.c -ldl | ||
* RUN: true | ||
*/ | ||
|
||
#include <glad/gles2.h> | ||
|
||
int main(void) { | ||
(void) glObjectLabel; | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* | ||
* The GL_KHR_debug has suffixed symbols for GLES but symbols without suffix for GL. | ||
* Make sure only the symbols without suffix appear in the generated output for gl. | ||
* Related Issues: #281 | ||
* | ||
* See also: 003 | ||
* | ||
* GLAD: $GLAD --out-path=$tmp --api="gl:core=3.3" --extensions="GL_KHR_debug" c | ||
* COMPILE: ! $GCC $test -o $tmp/test -I$tmp/include $tmp/src/gl.c -ldl | ||
* RUN: true | ||
*/ | ||
|
||
#include <glad/gl.h> | ||
|
||
int main(void) { | ||
(void) glObjectLabelKHR; | ||
return 0; | ||
} |