From e59190d35314b7743f1594540203e2a504691182 Mon Sep 17 00:00:00 2001 From: Alessandro Mauri Date: Wed, 11 Mar 2026 17:17:22 +0100 Subject: [PATCH] update deprecations for c3 0.7.9 --- sdl3_gpu.c3i | 8 ++++---- sdl3_keycode.c3i | 2 +- sdl3_pen.c3i | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sdl3_gpu.c3i b/sdl3_gpu.c3i index 203f446..c981547 100644 --- a/sdl3_gpu.c3i +++ b/sdl3_gpu.c3i @@ -171,7 +171,7 @@ enum GPUTextureFormat : inline CInt { GPU_TEXTUREFORMAT_ASTC_12X12_FLOAT } -typedef GPUTextureUsageFlags = uint; +typedef GPUTextureUsageFlags @constinit = uint; const GPUTextureUsageFlags GPU_TEXTUREUSAGE_SAMPLER @builtin = (1 << 0); const GPUTextureUsageFlags GPU_TEXTUREUSAGE_COLOR_TARGET @builtin = (1 << 1); @@ -205,7 +205,7 @@ enum GPUCubeMapFace : inline CInt { GPU_CUBEMAPFACE_NEGATIVEZ } -typedef GPUBufferUsageFlags = uint; +typedef GPUBufferUsageFlags @constinit = uint; const GPUBufferUsageFlags GPU_BUFFERUSAGE_VERTEX @builtin = (1 << 0); const GPUBufferUsageFlags GPU_BUFFERUSAGE_INDEX @builtin = (1 << 1); @@ -225,7 +225,7 @@ enum GPUShaderStage : inline CInt { GPU_SHADERSTAGE_FRAGMENT } -typedef GPUShaderFormat = uint; +typedef GPUShaderFormat @constinit = uint; const GPUShaderFormat GPU_SHADERFORMAT_INVALID @builtin = 0; const GPUShaderFormat GPU_SHADERFORMAT_PRIVATE @builtin = (1 << 0); const GPUShaderFormat GPU_SHADERFORMAT_SPIRV @builtin = (1 << 1); @@ -364,7 +364,7 @@ enum GPUBlendFactor : inline CInt { GPU_BLENDFACTOR_SRC_ALPHA_SATURATE } -typedef GPUColorComponentFlags = char; +typedef GPUColorComponentFlags @constinit = char; const GPUColorComponentFlags GPU_COLORCOMPONENT_R @builtin = (1 << 0); const GPUColorComponentFlags GPU_COLORCOMPONENT_G @builtin = (1 << 1); const GPUColorComponentFlags GPU_COLORCOMPONENT_B @builtin = (1 << 2); diff --git a/sdl3_keycode.c3i b/sdl3_keycode.c3i index 67e35dd..5ab9674 100644 --- a/sdl3_keycode.c3i +++ b/sdl3_keycode.c3i @@ -1,6 +1,6 @@ module sdl3::sdl; -typedef Keycode = uint; +typedef Keycode @constinit = uint; const Keycode K_EXTENDED_MASK @builtin = (1 << 29); diff --git a/sdl3_pen.c3i b/sdl3_pen.c3i index 756aa92..3b7a724 100644 --- a/sdl3_pen.c3i +++ b/sdl3_pen.c3i @@ -5,7 +5,7 @@ typedef PenID = uint; const MouseID PEN_MOUSEID @builtin = ((MouseID)-2); const TouchID PEN_TOUCHID @builtin = ((TouchID)-2); -typedef PenInputFlags = uint; +typedef PenInputFlags @constinit = uint; const PenInputFlags PEN_INPUT_DOWN @builtin = (1 << 0); const PenInputFlags PEN_INPUT_BUTTON_1 @builtin = (1 << 1);