From c8666b3bec6513f6235e174fa8ad5c866bcdf7da Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Mon, 20 Jun 2022 22:36:15 -0700 Subject: [PATCH] dlwrap: allow usage with -std=cXX typeof is not available. __typeof__ is as a GNU extension. --- test/dlwrap.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/dlwrap.h b/test/dlwrap.h index 39ec9ec9..8e94da95 100644 --- a/test/dlwrap.h +++ b/test/dlwrap.h @@ -56,7 +56,7 @@ dlwrap_real_dlsym(void *handle, const char *symbol); #define DEFER_TO_GL(library, func, name, args) \ ({ \ void *lib = dlwrap_real_dlopen(library, RTLD_LAZY | RTLD_LOCAL); \ - typeof(&func) real_func = dlwrap_real_dlsym(lib, name); \ + __typeof__(&func) real_func = dlwrap_real_dlsym(lib, name); \ /* gcc extension -- func's return value is the return value of \ * the statement. \ */ \