Ignore:
Timestamp:
Aug 11, 2010, 10:28:37 AM (9 years ago)
Author:
lindanl
Message:

error check for empty PI names

File:
1 edited

Legend:

Unmodified
Added
Removed
  • proto/parabix2/parabix2_compilable.py

    r567 r570  
    212212        CD_ends = 0
    213213        CtCDPI_starts = 0
     214        PI_namestarts = 0
    214215        PI_name_ends = 0
    215216
     
    237238                #PI_Cursor = bitutil.ScanThru(PI_Cursor, PI_end_scan)
    238239                PI_Cursor = bitutil.Advance(PI_Cursor)
     240                PI_namestarts |= PI_Cursor
    239241                PI_name_end = bitutil.ScanThru(PI_Cursor, lex.NameScan)
    240242                PI_name_ends |= PI_name_end
     
    254256        CT_callouts.error = Ct_ends & ~lex.RAngle | Ct_starts & ~ lex.Hyphen
    255257        CT_callouts.error |= bitutil.Advance(PI_name_ends & ~ lex.WS) & ~ lex.PI_end
     258        CT_callouts.error |= PI_namestarts & PI_name_ends
    256259        # If any of the Comment, CDATA or PI markups are unterminated, it is an error.
    257260        CT_callouts.error |= CT_callouts.CtCDPI_mask &~ EOF_mask
Note: See TracChangeset for help on using the changeset viewer.