132 - New ErrorCode and WSI Loader Library
Channel: StableCoder
Date: 2021-09-20

This session focuses on create a new C-compatible error code type, and a library that can be used to load different WSI implementation libraries at runtime.

The new foeErrorCode type is needed since the move more towards using C-style APIs for libraries. Returning C++-specific std::error_code types is something that can't be used moving forward. As such, creating a struct type that has all the information required to easily reconstruct the std::error_code type after the data is passed through the C-API.

As for the WSI loader, an inflection point has been reached where the macOS and Windows linkers are having problems properly linking the WSI libraries, especially for the imgui variant, as it expects implementations to be available, but implementations are meant to be capable of being separate and loaded at runtime. For this, a new intermediate 'loader' library is created that is linkable, but allows for loading actual implementations at runtime.

2021/09/18