X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-psi;a=blobdiff_plain;f=src%2Fparser_scan.re;h=f280b86ba03f4491d75cdc5b00ff816a8d7cd2b4;hp=7ba49b2764010025ef992ccd2a6077cb8ea5023d;hb=44bd65fe60fb83fa4c3bbb0d4c679d2b70a096df;hpb=a7ac1c0a3c855321f21682c127a4b707de33a303 diff --git a/src/parser_scan.re b/src/parser_scan.re index 7ba49b2..f280b86 100644 --- a/src/parser_scan.re +++ b/src/parser_scan.re @@ -23,10 +23,15 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *******************************************************************************/ -#include +#ifdef HAVE_CONFIG_H +# include "config.h" +#else +# include "php_config.h" +#endif #include "parser.h" #include "plist.h" +#include "debug.h" /*!max:re2c*/ #ifndef YYMAXFILL @@ -48,8 +53,10 @@ size_t psi_parser_maxfill(void) { token = psi_token_init(t, tok, cur - tok, tok - eol + 1, I->lines, I->file); \ } \ tokens = psi_plist_add(tokens, &token); \ - PSI_DEBUG_PRINT(P, "PSI: scanned < "); \ - PSI_DEBUG_DUMP(P, psi_token_dump, token); \ + PSI_DEBUG_LOCK(P, \ + PSI_DEBUG_PRINT(P, "PSI: scanned < "); \ + PSI_DEBUG_DUMP(P, psi_token_dump, token); \ + ); \ } while(0) #define CHECKEOF() if (cur >= lim - YYMAXFILL) goto done