summaryrefslogtreecommitdiff
path: root/quantum/process_keycode
diff options
context:
space:
mode:
authorTed M Lin <tedmlin@gmail.com>2020-02-06 20:53:43 -0500
committerFlorian Didron <fdidron@users.noreply.github.com>2020-02-26 10:15:12 +0900
commit0631d666801cfbbf0842f056a9ba68edeb4b6edc (patch)
tree19474f38714d232940c7c66150ae33df46c6c0ee /quantum/process_keycode
parentb0896a3b356cdbe7eddc96c4f88b6f56a3125aa7 (diff)
Use function for KEYCODE2 routines instead of macro. (#8101)
* Option to use function for KEYCODE2 routines. Convert the KEYCODE2SYSTEM and KEYCODE2CONSUMER macros to functions, defaulting to using the macros. The function form allows the compiler to optimize the switch statement itself, over the macro nested ternaries. To enable this feature, #define USE_KEYCODE2_FUNCTION. Testing against a random selection of avr-based keyboards, this increased available flash by ~500 bytes. For arm-based keyboards, the available flash increased by ~400 bytes. * Replace macro with function entirely. As zvecr states, go bold and just commit to using the function instead of the macro. * Reformat whitespace now that functional review is done Verified against clang-format output.
Diffstat (limited to 'quantum/process_keycode')
0 files changed, 0 insertions, 0 deletions