Browse Source

Change to use 'strict' void style fn decls

master
cancel 6 years ago
parent
commit
9b81391d76
  1. 2
      cli_main.c
  2. 10
      term_util.h
  3. 2
      tool
  4. 8
      tui_main.c

2
cli_main.c

@ -5,7 +5,7 @@
#include "sim.h" #include "sim.h"
#include <getopt.h> #include <getopt.h>
static void usage() { static void usage(void) {
// clang-format off // clang-format off
fprintf(stderr, fprintf(stderr,
"Usage: cli [options] infile\n\n" "Usage: cli [options] infile\n\n"

10
term_util.h

@ -37,7 +37,7 @@ int fg_bg(Color_name fg, Color_name bg) {
return COLOR_PAIR(1 + fg * Colors_count + bg); return COLOR_PAIR(1 + fg * Colors_count + bg);
} }
void term_util_init_colors(); void term_util_init_colors(void);
typedef enum { typedef enum {
Qblock_type_qmsg, Qblock_type_qmsg,
@ -88,10 +88,10 @@ typedef union {
Qmenu_action_picked picked; Qmenu_action_picked picked;
} Qmenu_action; } Qmenu_action;
void qnav_init(); void qnav_init(void);
void qnav_deinit(); void qnav_deinit(void);
Qblock* qnav_top_block(); Qblock* qnav_top_block(void);
void qnav_stack_pop(); void qnav_stack_pop(void);
void qblock_print_frame(Qblock* qb, bool active); void qblock_print_frame(Qblock* qb, bool active);
void qblock_set_title(Qblock* qb, char const* title); void qblock_set_title(Qblock* qb, char const* title);

2
tool

@ -181,7 +181,7 @@ build_target() {
local libraries=() local libraries=()
local source_files=() local source_files=()
local out_exe local out_exe
add cc_flags -std=c99 -pipe -finput-charset=UTF-8 -Wall -Wpedantic -Wextra -Wconversion -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion add cc_flags -std=c99 -pipe -finput-charset=UTF-8 -Wall -Wpedantic -Wextra -Wconversion -Wstrict-prototypes -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion
if [[ $lld_detected = 1 ]]; then if [[ $lld_detected = 1 ]]; then
add cc_flags -fuse-ld=lld add cc_flags -fuse-ld=lld
fi fi

8
tui_main.c

@ -13,7 +13,7 @@
#include "sokol_time.h" #include "sokol_time.h"
#undef SOKOL_IMPL #undef SOKOL_IMPL
static void usage() { static void usage(void) {
// clang-format off // clang-format off
fprintf(stderr, fprintf(stderr,
"Usage: orca [options] [file]\n\n" "Usage: orca [options] [file]\n\n"
@ -1495,7 +1495,7 @@ enum {
Main_menu_about, Main_menu_about,
}; };
void push_main_menu() { void push_main_menu(void) {
Qmenu* qm = qmenu_create(Main_menu_id); Qmenu* qm = qmenu_create(Main_menu_id);
qmenu_add_choice(qm, "Save", Main_menu_save); qmenu_add_choice(qm, "Save", Main_menu_save);
qmenu_add_choice(qm, "Save As...", Main_menu_save_as); qmenu_add_choice(qm, "Save As...", Main_menu_save_as);
@ -1508,7 +1508,7 @@ void push_main_menu() {
qblock_set_title(&qm->qblock, "ORCA"); qblock_set_title(&qm->qblock, "ORCA");
} }
void push_about_msg() { void push_about_msg(void) {
// clang-format off // clang-format off
static char const* logo[] = { static char const* logo[] = {
"lqqqk|lqqqk|lqqqk|lqqqk", "lqqqk|lqqqk|lqqqk|lqqqk",
@ -1553,7 +1553,7 @@ void push_about_msg() {
wprintw(w, footer); wprintw(w, footer);
} }
void push_controls_msg() { void push_controls_msg(void) {
struct Ctrl_item { struct Ctrl_item {
char const* input; char const* input;
char const* desc; char const* desc;

Loading…
Cancel
Save