Skip to content

Commit

Permalink
Do not create types for arrays
Browse files Browse the repository at this point in the history
  • Loading branch information
RobDangerous committed Oct 18, 2024
1 parent 59d5a27 commit 2c2afbe
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Sources/integrations/kope.c
Original file line number Diff line number Diff line change
Expand Up @@ -591,10 +591,13 @@ void kope_export(char *directory, api_kind api) {

for (global_id i = 0; get_global(i) != NULL && get_global(i)->type != NO_TYPE; ++i) {
global *g = get_global(i);
if (is_texture(g->type) || g->type == sampler_type_id) {

type_id base_type = get_type(g->type)->kind == TYPE_ARRAY ? get_type(g->type)->array.base : g->type;

if (is_texture(base_type) || base_type == sampler_type_id) {
}
else if (!get_type(g->type)->built_in) {
type *t = get_type(g->type);
else if (!get_type(base_type)->built_in) {
type *t = get_type(base_type);

char name[256];
if (t->name != NO_NAME) {
Expand Down

0 comments on commit 2c2afbe

Please sign in to comment.