Use C++ style comments consistently in SDL source code

Implemented using this script:

find . -type f -exec sed -i'' -e 's,/\* *\([^*]*\)\*/ *$,// \1,' -e 's, \+$,,' {} \;
git checkout \
    core/linux/SDL_evdev_kbd_default_keymap.h \
    events/imKStoUCS.* \
    hidapi \
    joystick/controller_type.c \
    joystick/controller_type.h \
    joystick/hidapi/steam/controller_constants.h \
    joystick/hidapi/steam/controller_structs.h \
    joystick/SDL_gamepad_db.h \
    libm \
    render/*/*Shader*.h \
    render/vitagxm/SDL_render_vita_gxm_shaders.h \
    render/metal/SDL_shaders_metal_*.h \
    stdlib/SDL_malloc.c \
    stdlib/SDL_qsort.c \
    stdlib/SDL_strtokr.c \
    test/ \
    video/directx/SDL_d3d12_xbox_cmacros.h \
    video/directx/d3d12.h \
    video/directx/d3d12sdklayers.h \
    video/khronos \
    video/x11/edid-parse.c \
    video/x11/xsettings-client.* \
    video/yuv2rgb
sed -i'' -e 's,/\* *\([^*]*\)\*/ *$,// \1,' -e 's, \+$,,' hidapi/SDL_hidapi.c
This commit is contained in:
Sam Lantinga 2024-08-22 10:30:45 -07:00
parent 658fc3db0f
commit 6501e90018
743 changed files with 11882 additions and 11882 deletions

View file

@ -35,7 +35,7 @@
updated SDL can transparently take advantage of them, but your program will
not without this feature. Think hard before turning it off.
*/
#ifdef SDL_DYNAMIC_API /* Tried to force it on the command line? */
#ifdef SDL_DYNAMIC_API // Tried to force it on the command line?
#error Nope, you have to edit this file to force this off.
#endif
@ -43,33 +43,33 @@
#include "TargetConditionals.h"
#endif
#if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE /* probably not useful on iOS. */
#if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE // probably not useful on iOS.
#define SDL_DYNAMIC_API 0
#elif defined(SDL_PLATFORM_ANDROID) /* probably not useful on Android. */
#elif defined(SDL_PLATFORM_ANDROID) // probably not useful on Android.
#define SDL_DYNAMIC_API 0
#elif defined(SDL_PLATFORM_EMSCRIPTEN) /* probably not useful on Emscripten. */
#elif defined(SDL_PLATFORM_EMSCRIPTEN) // probably not useful on Emscripten.
#define SDL_DYNAMIC_API 0
#elif defined(SDL_BUILDING_WINRT) && SDL_BUILDING_WINRT /* probably not useful on WinRT, given current .dll loading restrictions */
#elif defined(SDL_BUILDING_WINRT) && SDL_BUILDING_WINRT // probably not useful on WinRT, given current .dll loading restrictions
#define SDL_DYNAMIC_API 0
#elif defined(SDL_PLATFORM_PS2) && SDL_PLATFORM_PS2
#define SDL_DYNAMIC_API 0
#elif defined(SDL_PLATFORM_PSP) && SDL_PLATFORM_PSP
#define SDL_DYNAMIC_API 0
#elif defined(SDL_PLATFORM_RISCOS) /* probably not useful on RISC OS, since dlopen() can't be used when using static linking. */
#elif defined(SDL_PLATFORM_RISCOS) // probably not useful on RISC OS, since dlopen() can't be used when using static linking.
#define SDL_DYNAMIC_API 0
#elif defined(__clang_analyzer__) || defined(__INTELLISENSE__) || defined(SDL_THREAD_SAFETY_ANALYSIS)
#define SDL_DYNAMIC_API 0 /* Turn off for static analysis, so reports are more clear. */
#define SDL_DYNAMIC_API 0 // Turn off for static analysis, so reports are more clear.
#elif defined(SDL_PLATFORM_VITA)
#define SDL_DYNAMIC_API 0 /* vitasdk doesn't support dynamic linking */
#define SDL_DYNAMIC_API 0 // vitasdk doesn't support dynamic linking
#elif defined(SDL_PLATFORM_NGAGE)
#define SDL_DYNAMIC_API 0 /* The N-Gage doesn't support dynamic linking either */
#define SDL_DYNAMIC_API 0 // The N-Gage doesn't support dynamic linking either
#elif defined(SDL_PLATFORM_3DS)
#define SDL_DYNAMIC_API 0 /* devkitARM doesn't support dynamic linking */
#define SDL_DYNAMIC_API 0 // devkitARM doesn't support dynamic linking
#elif defined(DYNAPI_NEEDS_DLOPEN) && !defined(HAVE_DLOPEN)
#define SDL_DYNAMIC_API 0 /* we need dlopen(), but don't have it.... */
#define SDL_DYNAMIC_API 0 // we need dlopen(), but don't have it....
#endif
/* everyone else. This is where we turn on the API if nothing forced it off. */
// everyone else. This is where we turn on the API if nothing forced it off.
#ifndef SDL_DYNAMIC_API
#define SDL_DYNAMIC_API 1
#endif