diff options
author | Ivan Maidanski <ivmai@mail.ru> | 2022-04-18 09:49:13 +0300 |
---|---|---|
committer | Ivan Maidanski <ivmai@mail.ru> | 2022-04-18 09:49:13 +0300 |
commit | 9d77d70bed28887d4b965d1d85db6e95059952d3 (patch) | |
tree | aa19ca913466943a737e84368a7804068893f2f5 /cord | |
parent | ad916805e21835a728f4f055196f264180cf4ab3 (diff) | |
download | bdwgc-9d77d70bed28887d4b965d1d85db6e95059952d3.tar.gz |
Adjust indentation in C preprocessor directives
(reformatting)
* cord/tests/de.c: Adjust indentation in directives.
* cord/tests/de_win.c: Likewise.
* dbg_mlc.c: Likewise.
* dyn_load.c: Likewise.
* extra/AmigaOS.c: Likewise.
* include/gc/ec.h: Likewise.
* include/gc/gc_tiny_fl.h: Likewise.
* include/private/gc_locks.h: Likewise.
* include/private/gc_priv.h: Likewise.
* include/private/gcconfig.h: Likewise.
* include/private/thread_local_alloc.h: Likewise.
* malloc.c: Likewise.
* mark.c: Likewise.
* os_dep.c: Likewise.
* ptr_chck.c: Likewise.
* reclaim.c: Likewise.
* tests/gctest.c: Likewise.
* tools/threadlibs.c: Likewise.
Diffstat (limited to 'cord')
-rw-r--r-- | cord/tests/de.c | 52 | ||||
-rw-r--r-- | cord/tests/de_win.c | 54 |
2 files changed, 53 insertions, 53 deletions
diff --git a/cord/tests/de.c b/cord/tests/de.c index 4a30863b..6ad38b47 100644 --- a/cord/tests/de.c +++ b/cord/tests/de.c @@ -45,33 +45,33 @@ #endif #if defined(WIN32) -# ifndef WIN32_LEAN_AND_MEAN -# define WIN32_LEAN_AND_MEAN 1 -# endif -# define NOSERVICE -# include <windows.h> -# include "de_win.h" +# ifndef WIN32_LEAN_AND_MEAN +# define WIN32_LEAN_AND_MEAN 1 +# endif +# define NOSERVICE +# include <windows.h> +# include "de_win.h" #elif defined(MACINTOSH) -# include <console.h> +# include <console.h> /* curses emulation. */ -# define initscr() -# define endwin() -# define nonl() -# define noecho() csetmode(C_NOECHO, stdout) -# define cbreak() csetmode(C_CBREAK, stdout) -# define refresh() -# define addch(c) putchar(c) -# define standout() cinverse(1, stdout) -# define standend() cinverse(0, stdout) -# define move(line,col) cgotoxy(col + 1, line + 1, stdout) -# define clrtoeol() ccleol(stdout) -# define de_error(s) { fprintf(stderr, s); getchar(); } -# define LINES 25 -# define COLS 80 +# define initscr() +# define endwin() +# define nonl() +# define noecho() csetmode(C_NOECHO, stdout) +# define cbreak() csetmode(C_CBREAK, stdout) +# define refresh() +# define addch(c) putchar(c) +# define standout() cinverse(1, stdout) +# define standend() cinverse(0, stdout) +# define move(line,col) cgotoxy(col + 1, line + 1, stdout) +# define clrtoeol() ccleol(stdout) +# define de_error(s) { fprintf(stderr, s); getchar(); } +# define LINES 25 +# define COLS 80 #else -# include <curses.h> -# include <unistd.h> /* for sleep() */ -# define de_error(s) { fprintf(stderr, s); sleep(2); } +# include <curses.h> +# include <unistd.h> /* for sleep() */ +# define de_error(s) { fprintf(stderr, s); sleep(2); } #endif #include "de_cmds.h" @@ -383,9 +383,9 @@ void fix_pos(void) } #if defined(WIN32) -# define beep() Beep(1000 /* Hz */, 300 /* ms */) +# define beep() Beep(1000 /* Hz */, 300 /* ms */) #elif defined(MACINTOSH) -# define beep() SysBeep(1) +# define beep() SysBeep(1) #else /* * beep() is part of some curses packages and not others. diff --git a/cord/tests/de_win.c b/cord/tests/de_win.c index 878cae2a..9ba4c462 100644 --- a/cord/tests/de_win.c +++ b/cord/tests/de_win.c @@ -49,21 +49,21 @@ void de_error(const char *s) int APIENTRY WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR command_line, int nCmdShow) { - MSG msg; - WNDCLASS wndclass; - HACCEL hAccel; + MSG msg; + WNDCLASS wndclass; + HACCEL hAccel; - GC_set_find_leak(0); - GC_INIT(); -# ifndef NO_INCREMENTAL + GC_set_find_leak(0); + GC_INIT(); +# ifndef NO_INCREMENTAL GC_enable_incremental(); -# endif -# if defined(CPPCHECK) +# endif +# if defined(CPPCHECK) GC_noop1((GC_word)&WinMain); -# endif +# endif - if (!hPrevInstance) - { + if (!hPrevInstance) + { wndclass.style = CS_HREDRAW | CS_VREDRAW; wndclass.lpfnWndProc = WndProc; wndclass.cbClsExtra = 0; @@ -79,28 +79,28 @@ int APIENTRY WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, de_error("RegisterClass error"); return(0); } - } + } - /* Empirically, the command line does not include the command name ... - if (command_line != 0) { + /* Empirically, the command line does not include the command name ... + if (command_line != 0) { while (isspace(*command_line)) command_line++; while (*command_line != 0 && !isspace(*command_line)) command_line++; while (isspace(*command_line)) command_line++; - } */ + } */ - if (command_line == 0 || *command_line == 0) { + if (command_line == 0 || *command_line == 0) { de_error("File name argument required"); return( 0 ); - } else { + } else { char *p = command_line; while (*p != 0 && !isspace(*(unsigned char *)p)) p++; arg_file_name = CORD_to_char_star( CORD_substr(command_line, 0, p - command_line)); - } + } - hwnd = CreateWindow (szAppName, + hwnd = CreateWindow(szAppName, TEXT("Demonstration Editor"), WS_OVERLAPPEDWINDOW | WS_CAPTION, /* Window style */ CW_USEDEFAULT, 0, /* default pos. */ @@ -108,24 +108,24 @@ int APIENTRY WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, NULL, /* No parent */ NULL, /* Window class menu */ hInstance, NULL); - if (hwnd == NULL) { + if (hwnd == NULL) { de_error("CreateWindow error"); return(0); - } + } - ShowWindow (hwnd, nCmdShow); + ShowWindow (hwnd, nCmdShow); - hAccel = LoadAccelerators( hInstance, szAppName ); + hAccel = LoadAccelerators( hInstance, szAppName ); - while (GetMessage (&msg, NULL, 0, 0)) - { + while (GetMessage (&msg, NULL, 0, 0)) + { if( !TranslateAccelerator( hwnd, hAccel, &msg ) ) { TranslateMessage (&msg); DispatchMessage (&msg); } - } - return (int)msg.wParam; + } + return (int)msg.wParam; } /* Return the argument with all control characters replaced by blanks. */ |