Rev 70779 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
tre-config.h contains additional defines that their configure puts inconfig.h.We have remapped the POSIX entry points with a tre_ suffix: withoutit there was confusion with entry points in OS libraries on some OSes(e.g. macOS).alloca has been disabled: the declarations used do not work onWindows, and most likely not on FreeBSD.The way we compile it, TRE works internally in one of three modesSTR_BYTE, using bytesSTR_MBS , using wchar_t for matching, I/O in MBCSSTR_WIDE, using wchar_tWe've added interfaces tre_regcompb, tre_regncompb, tre_regexecb,tre_regnexecb and regaexecb to force STR_BYTE. Unless forced, bytesare used in a single-byte locale and wchar_t in a MBCS. We need toforce for useBytes=TRUE, for support for UTF-8 encoded stringsin a single-byte locale (principally on Windows) and when dealing withraw vectors. You do need to ensure that regcomp and regexec use thesame type.The offsets in the regmatch_t structure are in characters forSTR_WIDE, bytes for the other two modes.On Windows (MinGW?), iswctype is missing 'blank'.REG_LITERAL was not matching "" in some cases, hence a change atline 1652 of tre-parse.c.We fixed stack trampling in tre_tnfa_run_approx() and convertedtre_ast_to_tnfa() from recursion to iteration over a TRE stack.We commented out in tre-match-approx.c/* These seem compiler/OS-specific, but unexplainedOn Linux the first is intended to be used only with GCC.#define __USE_STRING_INLINES#undef __NO_INLINE__*/since it failed on clanghttps://stat.ethz.ch/pipermail/r-devel/2010-February/056728.htmlNov 2011: incorporated minor fixes from https://github.com/GerHobbelt/libtre(see http://laurikari.net/tre/website-issues-and-future-plans/#comments).Oct 2014: fixed R bug PR#16009 by copying the class member of a LITERALin tre_copy_ast.Nov 2014: changed tre_version() to report this is a modified version.