Changeset 4204


Ignore:
Timestamp:
Oct 2, 2014, 3:24:38 PM (5 years ago)
Author:
cameron
Message:

Reps have nullable components if ub != lb

File:
1 edited

Legend:

Unmodified
Added
Removed
  • proto/RE/Haskell/Nullable.hs

    r3901 r4204  
    8585  | hasNullablePrefix(a)   = True
    8686  | otherwise              = hasNullablePrefix (Alt as)
    87 hasNullablePrefix (Rep(r, lb, ub)) = hasNullablePrefix(r)
     87hasNullablePrefix (Rep(r, lb, ub))
     88  | lb == ub   = hasNullablePrefix(r)
     89  | otherwise  = True
    8890hasNullablePrefix r = False
    8991
     
    9799  | hasNullableSuffix(a)   = True
    98100  | otherwise              = hasNullableSuffix (Alt as)
    99 hasNullableSuffix (Rep(r, lb, ub)) = hasNullableSuffix(r)
     101hasNullableSuffix (Rep(r, lb, ub))
     102  | lb == ub   = hasNullableSuffix(r)
     103  | otherwise  = True
    100104hasNullableSuffix r = False
Note: See TracChangeset for help on using the changeset viewer.