From 85c82693e89a76f17257a2ef8256ca22e5192289 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Tue, 23 May 2023 01:54:46 -0700 Subject: Use the macros to declare the indirect context thunks --- al/direct_defs.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'al/direct_defs.h') diff --git a/al/direct_defs.h b/al/direct_defs.h index d8946eb4..7526b611 100644 --- a/al/direct_defs.h +++ b/al/direct_defs.h @@ -116,4 +116,12 @@ R AL_APIENTRY Name##Ext(T1 a, T2 b, T3 c, T4 d, T5 e, T6 f) noexcept \ return Name##Direct##Ext(context.get(), a, b, c, d, e, f); \ } +#define DECL_FUNCEXT8(R, Name,Ext, T1, T2, T3, T4, T5, T6, T7, T8) \ +R AL_APIENTRY Name##Ext(T1 a, T2 b, T3 c, T4 d, T5 e, T6 f, T7 g, T8 h) noexcept \ +{ \ + auto context = GetContextRef(); \ + if(!context) UNLIKELY return detail_::DefaultVal(); \ + return Name##Direct##Ext(context.get(), a, b, c, d, e, f, g, h); \ +} + #endif /* AL_DIRECT_DEFS_H */ -- cgit v1.2.3