diff options
author | Ryan <fauxpark@gmail.com> | 2023-01-21 03:21:17 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-20 16:21:17 +0000 |
commit | cf935d97ae479e7a1e1f2f2f248b93e52e4cc69e (patch) | |
tree | cb7dc41b774171ce7036f963941ce801e868d8cd /quantum | |
parent | 0f77ae6a20652c11bc252548bd28fd64f5fb6b97 (diff) |
Fix functions with empty params (#19647)
* Fix functions with empty params
* Found a bunch more
Diffstat (limited to 'quantum')
-rw-r--r-- | quantum/action.c | 2 | ||||
-rw-r--r-- | quantum/action_util.c | 4 | ||||
-rw-r--r-- | quantum/audio/audio.c | 4 | ||||
-rw-r--r-- | quantum/audio/voices.c | 4 | ||||
-rw-r--r-- | quantum/joystick.c | 2 | ||||
-rw-r--r-- | quantum/keyboard.c | 2 | ||||
-rw-r--r-- | quantum/process_keycode/process_audio.c | 4 | ||||
-rw-r--r-- | quantum/process_keycode/process_auto_shift.c | 4 | ||||
-rw-r--r-- | quantum/process_keycode/process_music.c | 6 | ||||
-rw-r--r-- | quantum/process_keycode/process_steno.c | 2 | ||||
-rw-r--r-- | quantum/process_keycode/process_tap_dance.c | 2 | ||||
-rw-r--r-- | quantum/quantum.c | 8 |
12 files changed, 22 insertions, 22 deletions
diff --git a/quantum/action.c b/quantum/action.c index 79ea2b7635..6b5660af8b 100644 --- a/quantum/action.c +++ b/quantum/action.c @@ -1050,7 +1050,7 @@ void clear_keyboard_but_mods(void) { * * FIXME: Needs documentation. */ -void clear_keyboard_but_mods_and_keys() { +void clear_keyboard_but_mods_and_keys(void) { #ifdef EXTRAKEY_ENABLE host_system_send(0); host_consumer_send(0); diff --git a/quantum/action_util.c b/quantum/action_util.c index 738410a4ac..7f7d32887b 100644 --- a/quantum/action_util.c +++ b/quantum/action_util.c @@ -98,12 +98,12 @@ enum { # if (defined(ONESHOT_TIMEOUT) && (ONESHOT_TIMEOUT > 0)) static uint16_t oneshot_layer_time = 0; -inline bool has_oneshot_layer_timed_out() { +inline bool has_oneshot_layer_timed_out(void) { return TIMER_DIFF_16(timer_read(), oneshot_layer_time) >= ONESHOT_TIMEOUT && !(get_oneshot_layer_state() & ONESHOT_TOGGLED); } # ifdef SWAP_HANDS_ENABLE static uint16_t oneshot_swaphands_time = 0; -inline bool has_oneshot_swaphands_timed_out() { +inline bool has_oneshot_swaphands_timed_out(void) { return TIMER_DIFF_16(timer_read(), oneshot_swaphands_time) >= ONESHOT_TIMEOUT && (swap_hands_oneshot == SHO_ACTIVE); } # endif diff --git a/quantum/audio/audio.c b/quantum/audio/audio.c index c6523b908c..ca78a483ad 100644 --- a/quantum/audio/audio.c +++ b/quantum/audio/audio.c @@ -112,7 +112,7 @@ static bool audio_initialized = false; static bool audio_driver_stopped = true; audio_config_t audio_config; -void audio_init() { +void audio_init(void) { if (audio_initialized) { return; } @@ -185,7 +185,7 @@ bool audio_is_on(void) { return (audio_config.enable != 0); } -void audio_stop_all() { +void audio_stop_all(void) { if (audio_driver_stopped) { return; } diff --git a/quantum/audio/voices.c b/quantum/audio/voices.c index 1c08a3af36..01f257f4d4 100644 --- a/quantum/audio/voices.c +++ b/quantum/audio/voices.c @@ -36,11 +36,11 @@ void set_voice(voice_type v) { voice = v; } -void voice_iterate() { +void voice_iterate(void) { voice = (voice + 1) % number_of_voices; } -void voice_deiterate() { +void voice_deiterate(void) { voice = (voice - 1 + number_of_voices) % number_of_voices; } diff --git a/quantum/joystick.c b/quantum/joystick.c index 057a018dff..02818e4acd 100644 --- a/quantum/joystick.c +++ b/quantum/joystick.c @@ -111,7 +111,7 @@ int16_t joystick_read_axis(uint8_t axis) { return ranged_val; } -void joystick_read_axes() { +void joystick_read_axes(void) { #if JOYSTICK_AXIS_COUNT > 0 for (int i = 0; i < JOYSTICK_AXIS_COUNT; ++i) { if (joystick_axes[i].input_pin == JS_VIRTUAL_AXIS) { diff --git a/quantum/keyboard.c b/quantum/keyboard.c index 37675ded0b..1de5f1cd0c 100644 --- a/quantum/keyboard.c +++ b/quantum/keyboard.c @@ -238,7 +238,7 @@ __attribute__((weak)) void keyboard_pre_init_kb(void) { * FIXME: needs doc */ -__attribute__((weak)) void keyboard_post_init_user() {} +__attribute__((weak)) void keyboard_post_init_user(void) {} /** \brief keyboard_post_init_kb * diff --git a/quantum/process_keycode/process_audio.c b/quantum/process_keycode/process_audio.c index 03b0af9277..c189dd02b7 100644 --- a/quantum/process_keycode/process_audio.c +++ b/quantum/process_keycode/process_audio.c @@ -62,5 +62,5 @@ void process_audio_all_notes_off(void) { stop_all_notes(); } -__attribute__((weak)) void audio_on_user() {} -__attribute__((weak)) void audio_off_user() {} +__attribute__((weak)) void audio_on_user(void) {} +__attribute__((weak)) void audio_off_user(void) {} diff --git a/quantum/process_keycode/process_auto_shift.c b/quantum/process_keycode/process_auto_shift.c index aaf0cf9142..aad1a164ae 100644 --- a/quantum/process_keycode/process_auto_shift.c +++ b/quantum/process_keycode/process_auto_shift.c @@ -344,7 +344,7 @@ bool get_autoshift_state(void) { return autoshift_flags.enabled; } -uint16_t get_generic_autoshift_timeout() { +uint16_t get_generic_autoshift_timeout(void) { return autoshift_timeout; } __attribute__((weak)) uint16_t get_autoshift_timeout(uint16_t keycode, keyrecord_t *record) { @@ -484,7 +484,7 @@ void retroshift_poll_time(keyevent_t *event) { retroshift_time = timer_read(); } // Used to swap the times of Retro Shifted key and Auto Shift key that interrupted it. -void retroshift_swap_times() { +void retroshift_swap_times(void) { if (last_retroshift_time != 0 && autoshift_flags.in_progress) { uint16_t temp = retroshift_time; retroshift_time = last_retroshift_time; diff --git a/quantum/process_keycode/process_music.c b/quantum/process_keycode/process_music.c index ee697a0cc6..7c572079a7 100644 --- a/quantum/process_keycode/process_music.c +++ b/quantum/process_keycode/process_music.c @@ -317,10 +317,10 @@ void music_task(void) { } } -__attribute__((weak)) void music_on_user() {} +__attribute__((weak)) void music_on_user(void) {} -__attribute__((weak)) void midi_on_user() {} +__attribute__((weak)) void midi_on_user(void) {} -__attribute__((weak)) void music_scale_user() {} +__attribute__((weak)) void music_scale_user(void) {} #endif // defined(AUDIO_ENABLE) || (defined(MIDI_ENABLE) && defined(MIDI_BASIC)) diff --git a/quantum/process_keycode/process_steno.c b/quantum/process_keycode/process_steno.c index 30a0d4056f..8ba98bd4bb 100644 --- a/quantum/process_keycode/process_steno.c +++ b/quantum/process_keycode/process_steno.c @@ -127,7 +127,7 @@ static const uint16_t combinedmap_second[] PROGMEM = {STN_S2, STN_KL, STN_WL, ST #endif #ifdef STENO_ENABLE_ALL -void steno_init() { +void steno_init(void) { if (!eeconfig_is_enabled()) { eeconfig_init(); } diff --git a/quantum/process_keycode/process_tap_dance.c b/quantum/process_keycode/process_tap_dance.c index fbe4ce1d33..706f5cddbb 100644 --- a/quantum/process_keycode/process_tap_dance.c +++ b/quantum/process_keycode/process_tap_dance.c @@ -162,7 +162,7 @@ bool process_tap_dance(uint16_t keycode, keyrecord_t *record) { return true; } -void tap_dance_task() { +void tap_dance_task(void) { tap_dance_action_t *action; if (!active_td || timer_elapsed(last_tap_time) <= GET_TAPPING_TERM(active_td, &(keyrecord_t){})) return; diff --git a/quantum/quantum.c b/quantum/quantum.c index 0fe54c60a7..0e69246f41 100644 --- a/quantum/quantum.c +++ b/quantum/quantum.c @@ -454,10 +454,10 @@ void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3) { } // TODO: remove legacy api -void matrix_init_quantum() { +void matrix_init_quantum(void) { matrix_init_kb(); } -void matrix_scan_quantum() { +void matrix_scan_quantum(void) { matrix_scan_kb(); } @@ -465,9 +465,9 @@ void matrix_scan_quantum() { // Override these functions in your keymap file to play different tunes on // different events such as startup and bootloader jump -__attribute__((weak)) void startup_user() {} +__attribute__((weak)) void startup_user(void) {} -__attribute__((weak)) void shutdown_user() {} +__attribute__((weak)) void shutdown_user(void) {} void suspend_power_down_quantum(void) { suspend_power_down_kb(); |