yylex_destroy is for both reentrant and non-reentrant scanners. */
| 2428 | |
| 2429 | /* yylex_destroy is for both reentrant and non-reentrant scanners. */ |
| 2430 | int yylex_destroy (yyscan_t yyscanner) |
| 2431 | { |
| 2432 | struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; |
| 2433 | |
| 2434 | /* Pop the buffer stack, destroying each element. */ |
| 2435 | while(YY_CURRENT_BUFFER){ |
| 2436 | yy_delete_buffer( YY_CURRENT_BUFFER , yyscanner ); |
| 2437 | YY_CURRENT_BUFFER_LVALUE = NULL; |
| 2438 | yypop_buffer_state(yyscanner); |
| 2439 | } |
| 2440 | |
| 2441 | /* Destroy the stack itself. */ |
| 2442 | yyfree(yyg->yy_buffer_stack , yyscanner); |
| 2443 | yyg->yy_buffer_stack = NULL; |
| 2444 | |
| 2445 | /* Destroy the start condition stack. */ |
| 2446 | yyfree( yyg->yy_start_stack , yyscanner ); |
| 2447 | yyg->yy_start_stack = NULL; |
| 2448 | |
| 2449 | /* Reset the globals. This is important in a non-reentrant scanner so the next time |
| 2450 | * yylex() is called, initialization will occur. */ |
| 2451 | yy_init_globals( yyscanner); |
| 2452 | |
| 2453 | /* Destroy the main struct (reentrant only). */ |
| 2454 | yyfree ( yyscanner , yyscanner ); |
| 2455 | yyscanner = NULL; |
| 2456 | return 0; |
| 2457 | } |
| 2458 | |
| 2459 | /* |
| 2460 | * Internal utility routines. |
no test coverage detected