make the API for indexing in the parser and the linearizer public since it will be needed in the Haskell binding

This commit is contained in:
Krasimir Angelov
2017-09-14 18:11:24 +02:00
parent 0d42eed7b6
commit bcb97a336e
4 changed files with 15 additions and 15 deletions

View File

@@ -351,4 +351,16 @@ struct PgfCCat {
GuFinalizer fin[0];
};
PGF_API_DECL void
pgf_parser_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,
GuPool *pool);
PGF_API_DECL void
pgf_lzr_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,
GuPool *pool);
#endif

View File

@@ -30,7 +30,7 @@ pgf_lzr_add_overl_entry(PgfCncOverloadMap* overl_table,
gu_buf_push(entries, void*, entry);
}
PGF_INTERNAL void
PGF_API void
pgf_lzr_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,

View File

@@ -2504,7 +2504,7 @@ pgf_lookup_word_prefix(PgfConcr *concr, GuString prefix,
return &state->en;
}
PGF_INTERNAL void
PGF_API void
pgf_parser_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,

View File

@@ -936,18 +936,6 @@ pgf_read_pargs(PgfReader* rdr, PgfConcr* concr)
return pargs;
}
extern void
pgf_parser_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,
GuPool *pool);
extern void
pgf_lzr_index(PgfConcr* concr,
PgfCCat* ccat, PgfProduction prod,
bool is_lexical,
GuPool *pool);
static bool
pgf_production_is_lexical(PgfReader* rdr, PgfProductionApply *papp)
{
@@ -1075,7 +1063,7 @@ pgf_read_cnccat(PgfReader* rdr, PgfAbstr* abstr, PgfConcr* concr, PgfCId name)
int len = last + 1 - first;
cnccat->cats = gu_new_seq(PgfCCat*, len, rdr->opool);
for (int i = 0; i < len; i++) {
int fid = first + i;
PgfCCat* ccat = gu_map_get(concr->ccats, &fid, PgfCCat*);