comparison lwasm/lwasm.c @ 581:10f8fc64481d

Fix a slight error in cases where 0b is present but not followed by 0 or 1 This fixes an error where 0b is not followed by 0 or 1. In that case, the 0b prefix should not be consumed but the code which attempted to not consume it failed to actually update the parse pointer correctly.
author William Astle <lost@l-w.ca>
date Thu, 08 Aug 2024 13:40:00 -0600
parents 40edb7de3857
children 1ede8f8621cf
comparison
equal deleted inserted replaced
580:27f4ec60a52d 581:10f8fc64481d
647 // binary constant 647 // binary constant
648 (*p) += 2; 648 (*p) += 2;
649 649
650 if (**p != '0' && **p != '1') 650 if (**p != '0' && **p != '1')
651 { 651 {
652 (*p)-2; 652 (*p) -= 2;
653 return NULL; 653 return NULL;
654 } 654 }
655 655
656 while (**p && (**p == '0' || **p == '1')) 656 while (**p && (**p == '0' || **p == '1'))
657 { 657 {