~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to storage/innobase/pars/lexyy.c

  • Committer: Eric Herman
  • Date: 2008-12-06 19:42:46 UTC
  • mto: (656.1.6 devel)
  • mto: This revision was merged to the branch mainline in revision 665.
  • Revision ID: eric@mysql.com-20081206194246-5cdexuu81i366eek
removed trailing whitespace with simple script:

for file in $(find . -name "*.c") $(find . -name "*.cc") $(find . -name "*.h"); do ruby -pe 'gsub(/\s+$/, $/)' < $file > $file.out; mv $file.out $file; done;

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
typedef signed char flex_int8_t;
45
45
typedef short int flex_int16_t;
46
46
typedef int flex_int32_t;
47
 
typedef unsigned char flex_uint8_t; 
 
47
typedef unsigned char flex_uint8_t;
48
48
typedef unsigned short int flex_uint16_t;
49
49
typedef unsigned int flex_uint32_t;
50
50
#endif /* ! C99 */
148
148
#define EOB_ACT_LAST_MATCH 2
149
149
 
150
150
    #define YY_LESS_LINENO(n)
151
 
    
 
151
 
152
152
/* Return all but the first "n" matched characters back to the input stream. */
153
153
#define yyless(n) \
154
154
        do \
215
215
 
216
216
    int yy_bs_lineno; /**< The line count. */
217
217
    int yy_bs_column; /**< The column count. */
218
 
    
 
218
 
219
219
        /* Whether to try to fill the input buffer when we reach the
220
220
         * end of it.
221
221
         */
904
904
        register yy_state_type yy_current_state;
905
905
        register char *yy_cp, *yy_bp;
906
906
        register int yy_act;
907
 
    
 
907
 
908
908
#line 92 "pars0lex.l"
909
909
 
910
910
 
2184
2184
{
2185
2185
        register yy_state_type yy_current_state;
2186
2186
        register char *yy_cp;
2187
 
    
 
2187
 
2188
2188
        yy_current_state = (yy_start);
2189
2189
 
2190
2190
        for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp )
2244
2244
 
2245
2245
{
2246
2246
        int c;
2247
 
    
 
2247
 
2248
2248
        *(yy_c_buf_p) = (yy_hold_char);
2249
2249
 
2250
2250
        if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR )
2311
2311
 
2312
2312
/** Immediately switch to a different input stream.
2313
2313
 * @param input_file A readable stream.
2314
 
 * 
 
2314
 *
2315
2315
 * @note This function does not reset the start condition to @c INITIAL .
2316
2316
 */
2317
2317
    static void yyrestart  (FILE * input_file )
2318
2318
{
2319
 
    
 
2319
 
2320
2320
        if ( ! YY_CURRENT_BUFFER ){
2321
2321
        yyensure_buffer_stack ();
2322
2322
                YY_CURRENT_BUFFER_LVALUE =
2329
2329
 
2330
2330
/** Switch to a different input buffer.
2331
2331
 * @param new_buffer The new input buffer.
2332
 
 * 
 
2332
 *
2333
2333
 */
2334
2334
    __attribute__((unused)) static void yy_switch_to_buffer  (YY_BUFFER_STATE  new_buffer )
2335
2335
{
2336
 
    
 
2336
 
2337
2337
        /* TODO. We should be able to replace this entire function body
2338
2338
         * with
2339
2339
         *              yypop_buffer_state();
2373
2373
/** Allocate and initialize an input buffer state.
2374
2374
 * @param file A readable stream.
2375
2375
 * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE.
2376
 
 * 
 
2376
 *
2377
2377
 * @return the allocated buffer state.
2378
2378
 */
2379
2379
    static YY_BUFFER_STATE yy_create_buffer  (FILE * file, int  size )
2380
2380
{
2381
2381
        YY_BUFFER_STATE b;
2382
 
    
 
2382
 
2383
2383
        b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state )  );
2384
2384
        if ( ! b )
2385
2385
                YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
2402
2402
 
2403
2403
/** Destroy the buffer.
2404
2404
 * @param b a buffer created with yy_create_buffer()
2405
 
 * 
 
2405
 *
2406
2406
 */
2407
2407
    static void yy_delete_buffer (YY_BUFFER_STATE  b )
2408
2408
{
2409
 
    
 
2409
 
2410
2410
        if ( ! b )
2411
2411
                return;
2412
2412
 
2427
2427
 
2428
2428
{
2429
2429
        int oerrno = errno;
2430
 
    
 
2430
 
2431
2431
        yy_flush_buffer(b );
2432
2432
 
2433
2433
        b->yy_input_file = file;
2443
2443
    }
2444
2444
 
2445
2445
        b->yy_is_interactive = 0;
2446
 
    
 
2446
 
2447
2447
        errno = oerrno;
2448
2448
}
2449
2449
 
2450
2450
/** Discard all buffered characters. On the next scan, YY_INPUT will be called.
2451
2451
 * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
2452
 
 * 
 
2452
 *
2453
2453
 */
2454
2454
    static void yy_flush_buffer (YY_BUFFER_STATE  b )
2455
2455
{
2478
2478
 *  the current state. This function will allocate the stack
2479
2479
 *  if necessary.
2480
2480
 *  @param new_buffer The new state.
2481
 
 *  
 
2481
 *
2482
2482
 */
2483
2483
__attribute__((unused)) static void yypush_buffer_state (YY_BUFFER_STATE new_buffer )
2484
2484
{
2508
2508
 
2509
2509
/** Removes and deletes the top of the stack, if present.
2510
2510
 *  The next element becomes the new top.
2511
 
 *  
 
2511
 *
2512
2512
 */
2513
2513
__attribute__((unused)) static void yypop_buffer_state (void)
2514
2514
{
2532
2532
static void yyensure_buffer_stack (void)
2533
2533
{
2534
2534
        int num_to_alloc;
2535
 
    
 
2535
 
2536
2536
        if (!(yy_buffer_stack)) {
2537
2537
 
2538
2538
                /* First allocation is just for 2 elements, since we don't know if this
2543
2543
                (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc
2544
2544
                                                                (num_to_alloc * sizeof(struct yy_buffer_state*)
2545
2545
                                                                );
2546
 
                
 
2546
 
2547
2547
                memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*));
2548
 
                                
 
2548
 
2549
2549
                (yy_buffer_stack_max) = num_to_alloc;
2550
2550
                (yy_buffer_stack_top) = 0;
2551
2551
                return;
2598
2598
/* Accessor  methods (get/set functions) to struct members. */
2599
2599
 
2600
2600
/** Get the current line number.
2601
 
 * 
 
2601
 *
2602
2602
 */
2603
2603
__attribute__((unused)) static int yyget_lineno  (void)
2604
2604
{
2605
 
        
 
2605
 
2606
2606
    return yylineno;
2607
2607
}
2608
2608
 
2609
2609
/** Get the input stream.
2610
 
 * 
 
2610
 *
2611
2611
 */
2612
2612
__attribute__((unused)) static FILE *yyget_in  (void)
2613
2613
{
2615
2615
}
2616
2616
 
2617
2617
/** Get the output stream.
2618
 
 * 
 
2618
 *
2619
2619
 */
2620
2620
__attribute__((unused)) static FILE *yyget_out  (void)
2621
2621
{
2623
2623
}
2624
2624
 
2625
2625
/** Get the length of the current token.
2626
 
 * 
 
2626
 *
2627
2627
 */
2628
2628
__attribute__((unused)) static int yyget_leng  (void)
2629
2629
{
2631
2631
}
2632
2632
 
2633
2633
/** Get the current token.
2634
 
 * 
 
2634
 *
2635
2635
 */
2636
2636
 
2637
2637
__attribute__((unused)) static char *yyget_text  (void)
2641
2641
 
2642
2642
/** Set the current line number.
2643
2643
 * @param line_number
2644
 
 * 
 
2644
 *
2645
2645
 */
2646
2646
__attribute__((unused)) static void yyset_lineno (int  line_number )
2647
2647
{
2648
 
    
 
2648
 
2649
2649
    yylineno = line_number;
2650
2650
}
2651
2651
 
2652
2652
/** Set the input stream. This does not discard the current
2653
2653
 * input buffer.
2654
2654
 * @param in_str A readable stream.
2655
 
 * 
 
2655
 *
2656
2656
 * @see yy_switch_to_buffer
2657
2657
 */
2658
2658
__attribute__((unused)) static void yyset_in (FILE *  in_str )
2678
2678
/* yylex_destroy is for both reentrant and non-reentrant scanners. */
2679
2679
__attribute__((unused)) static int yylex_destroy  (void)
2680
2680
{
2681
 
    
 
2681
 
2682
2682
    /* Pop the buffer stack, destroying each element. */
2683
2683
        while(YY_CURRENT_BUFFER){
2684
2684
                yy_delete_buffer(YY_CURRENT_BUFFER  );