mirror of
https://github.com/neovim/neovim.git
synced 2024-09-17 20:58:20 -04:00
refactor: combine regexp files
regext_bt.c and regexp_nfa.c are inlined into regexp.c instead of included as a header. This makes developer tools like clang-tidy and clangd be able to understand the code better.
This commit is contained in:
parent
92e99bb105
commit
4d757bbfbb
@ -19,7 +19,6 @@ Checks: >
|
||||
-bugprone-not-null-terminated-result,
|
||||
-bugprone-reserved-identifier,
|
||||
-bugprone-sizeof-expression,
|
||||
-bugprone-suspicious-include,
|
||||
-bugprone-suspicious-memory-comparison,
|
||||
-bugprone-swapped-arguments,
|
||||
-bugprone-switch-missing-default-case,
|
||||
|
@ -178,7 +178,6 @@
|
||||
{ include: [ '"os/mem.h.generated.h"', private, '"nvim/os/os.h"', public ] },
|
||||
{ include: [ '"os/stdpaths.h.generated.h"', private, '"nvim/os/os.h"', public ] },
|
||||
{ include: [ '"os/users.h.generated.h"', private, '"nvim/os/os.h"', public ] },
|
||||
{ include: [ '"regexp_bt.h.generated.h"', private, '"nvim/regexp.h"', public ] },
|
||||
{ include: [ '"ui_events_call.h.generated.h"', private, '"nvim/ui.h"', public ] },
|
||||
{ include: [ '"ui_events_client.h.generated.h"', private, '"nvim/ui_client.h"', public ] },
|
||||
{ include: [ '"ui_events_remote.generated.h"', private, '"nvim/api/ui.h"', public ] },
|
||||
|
@ -362,12 +362,6 @@ list(APPEND LINT_NVIM_SOURCES ${NVIM_SOURCES} ${NVIM_HEADERS})
|
||||
|
||||
foreach(sfile ${NVIM_SOURCES})
|
||||
get_filename_component(f ${sfile} NAME)
|
||||
if(${f} MATCHES "^(regexp_nfa.c)$")
|
||||
list(APPEND to_remove ${sfile})
|
||||
endif()
|
||||
if(${f} MATCHES "^(regexp_bt.c)$")
|
||||
list(APPEND to_remove ${sfile})
|
||||
endif()
|
||||
if(WIN32 AND ${f} MATCHES "^(pty_process_unix.c)$")
|
||||
list(APPEND to_remove ${sfile})
|
||||
endif()
|
||||
@ -456,8 +450,6 @@ set(LUA_GEN_DEPS ${GENERATOR_PRELOAD} $<TARGET_FILE:nlua0>)
|
||||
# NVIM_GENERATED_SOURCES: generated source files
|
||||
# These lists must be mutually exclusive.
|
||||
foreach(sfile ${NVIM_SOURCES}
|
||||
"${CMAKE_CURRENT_LIST_DIR}/regexp_bt.c"
|
||||
"${CMAKE_CURRENT_LIST_DIR}/regexp_nfa.c"
|
||||
${GENERATED_API_DISPATCH}
|
||||
"${GENERATED_UI_EVENTS_CALL}"
|
||||
"${GENERATED_UI_EVENTS_REMOTE}"
|
||||
|
13277
src/nvim/regexp.c
13277
src/nvim/regexp.c
File diff suppressed because it is too large
Load Diff
@ -17,12 +17,8 @@
|
||||
#define REX_USE 2 ///< to allow \z\1 et al.
|
||||
#define REX_ALL (REX_SET | REX_USE)
|
||||
|
||||
// regexp.c
|
||||
// uncrustify:off
|
||||
#ifdef INCLUDE_GENERATED_DECLARATIONS
|
||||
# include "regexp.h.generated.h"
|
||||
# include "regexp_bt.h.generated.h"
|
||||
#endif
|
||||
// uncrustify:on
|
||||
|
||||
#endif // NVIM_REGEXP_H
|
||||
|
5662
src/nvim/regexp_bt.c
5662
src/nvim/regexp_bt.c
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user