test(old): emulate test_override('char_avail') using FFI

Add a non-static variable for this, otherwise it'll be really hacky.
This avoid having to rewrite many incsearch tests in Lua.

(cherry picked from commit c925e7b8ba)
This commit is contained in:
zeertzjq
2025-07-03 21:23:26 +08:00
committed by github-actions[bot]
parent f0f163b267
commit d1214da08f
9 changed files with 106 additions and 107 deletions

View File

@@ -17,6 +17,8 @@ typedef enum {
enum { NSCRIPT = 15, }; ///< Maximum number of streams to read script from
EXTERN bool disable_char_avail_for_testing INIT( = false);
#ifdef INCLUDE_GENERATED_DECLARATIONS
# include "getchar.h.generated.h"
#endif