Add automatic generation of headers

- The 'stripdecls.py' script replaces declarations in all headers by includes to
  generated headers.
  `ag '#\s*if(?!ndef NEOVIM_).*((?!#\s*endif).*\n)*#ifdef INCLUDE_GENERATED'`
  was used for this.
- Add and integrate gendeclarations.lua into the build system to generate the
  required includes.
- Add -Wno-unused-function
- Made a bunch of old-style definitions ANSI

This adds a requirement: all type and structure definitions must be present
before INCLUDE_GENERATED_DECLARATIONS-protected include.

Warning: mch_expandpath (path.h.generated.h) was moved manually. So far it is
the only exception.
This commit is contained in:
ZyX
2014-05-10 17:24:13 +04:00
committed by Thiago de Arruda
parent 880957ad4e
commit 70929f7e16
154 changed files with 2190 additions and 6184 deletions

View File

@@ -1,33 +1,7 @@
#ifndef NVIM_SPELL_H
#define NVIM_SPELL_H
int spell_check(win_T *wp, char_u *ptr, hlf_T *attrp, int *capcol,
int docount);
int spell_move_to(win_T *wp, int dir, int allwords, int curline,
hlf_T *attrp);
void spell_cat_line(char_u *buf, char_u *line, int maxlen);
char_u *did_set_spelllang(win_T *wp);
void spell_delete_wordlist(void);
void spell_free_all(void);
void spell_reload(void);
int spell_check_msm(void);
void ex_mkspell(exarg_T *eap);
void ex_spell(exarg_T *eap);
void spell_add_word(char_u *word, int len, int bad, int idx, int undo);
void init_spell_chartab(void);
int spell_check_sps(void);
void spell_suggest(int count);
void ex_spellrepall(exarg_T *eap);
void spell_suggest_list(garray_T *gap, char_u *word, int maxcount,
int need_cap,
int interactive);
char_u *eval_soundfold(char_u *word);
void ex_spellinfo(exarg_T *eap);
void ex_spelldump(exarg_T *eap);
void spell_dump_compl(char_u *pat, int ic, int *dir, int dumpflags_arg);
char_u *spell_to_word_end(char_u *start, win_T *win);
int spell_word_start(int startcol);
void spell_expand_check_cap(colnr_T col);
int expand_spelling(linenr_T lnum, char_u *pat, char_u ***matchp);
#ifdef INCLUDE_GENERATED_DECLARATIONS
# include "spell.h.generated.h"
#endif
#endif // NVIM_SPELL_H