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

@ -31,12 +31,12 @@ int SDL_DrawPoint(SDL_Surface *dst, int x, int y, Uint32 color)
return SDL_InvalidParamError("SDL_DrawPoint(): dst");
}
/* This function doesn't work on surfaces < 8 bpp */
// This function doesn't work on surfaces < 8 bpp
if (dst->internal->format->bits_per_pixel < 8) {
return SDL_SetError("SDL_DrawPoint(): Unsupported surface format");
}
/* Perform clipping */
// Perform clipping
if (x < dst->internal->clip_rect.x || y < dst->internal->clip_rect.y ||
x >= (dst->internal->clip_rect.x + dst->internal->clip_rect.w) ||
y >= (dst->internal->clip_rect.y + dst->internal->clip_rect.h)) {
@ -71,7 +71,7 @@ int SDL_DrawPoints(SDL_Surface *dst, const SDL_Point *points, int count,
return SDL_InvalidParamError("SDL_DrawPoints(): dst");
}
/* This function doesn't work on surfaces < 8 bpp */
// This function doesn't work on surfaces < 8 bpp
if (dst->internal->format->bits_per_pixel < 8) {
return SDL_SetError("SDL_DrawPoints(): Unsupported surface format");
}
@ -106,4 +106,4 @@ int SDL_DrawPoints(SDL_Surface *dst, const SDL_Point *points, int count,
return 0;
}
#endif /* SDL_VIDEO_RENDER_SW */
#endif // SDL_VIDEO_RENDER_SW