This commit is contained in:
kornerr committed 2026-11-12 16:25:44 +03:00
1 parent 79c9e1dfbf
commit ba2867e560
3 files changed
+7 -3

No files matched your search

+3 -1
View File
@@ -5,7 +5,9 @@
#include <libEGL/libEGL.h>
#include <libGLESv2/GLES/gl.h>
#elif defined(_WIN32)
// EGL's native handle typedefs require Windows definitions first
// Initialize Windows SDK architecture macros before including windef.h
#include <windows.h>
// Expose native handle typedefs to Swift's Clang importer before EGL
#include <windef.h>
#include <EGL/egl.h>
#endif
+2 -1
View File
@@ -274,7 +274,8 @@ while EGL uses it; pointer extraction does not transfer ownership.
includes for iOS, and `<EGL/egl.h>` for Windows. Common attributes request an ES3
window surface with RGBA8/depth16 and an ES3 context. The arrays are declared
extern and defined only under `GLBRI_CONST_IMPLEMENTATION`.
The Windows branch directly includes windef.h before EGL/egl.h so Swift's Clang
The Windows branch includes windows.h first to initialize the SDK architecture
macros. It explicitly includes windef.h before EGL/egl.h so Swift's Clang
module importer can see HDC and the other native handle types used by ANGLE.
This dependency order takes precedence over alphabetical include sorting.
+2 -1
View File
@@ -323,7 +323,8 @@ Sort equivalent functions/methods alphabetically, leaving constructors first.
Use at most one consecutive blank line everywhere. Match counterpart function
block spacing, comments and direct assignments when behavior is the same. Code
comments do not end in a dot. Compiler-required include order overrides sorting:
Windows windef.h precedes EGL/egl.h so the Clang importer sees EGL's native handles.
Windows windows.h initializes the SDK architecture macros before windef.h.
Keep windef.h explicit before EGL/egl.h so the Clang importer sees EGL's native handles.
Do not move or reorder implementation macros independently of their includes.
Match build boundaries rather than copying dependencies from every target.