Index: trunk/extensions/VisualEditor/modules/parser/pegParser.pegjs.txt |
— | — | @@ -622,7 +622,7 @@ |
623 | 623 | & { return setFlag('h'); } |
624 | 624 | c:inlineline |
625 | 625 | e:'='+ |
626 | | - spc:(space / comment)* |
| 626 | + spc:(sp:space+ { return {type: 'TEXT', value: sp.join('') } } / comment)* |
627 | 627 | &eolf |
628 | 628 | { |
629 | 629 | clearFlag('h'); |
— | — | @@ -637,7 +637,7 @@ |
638 | 638 | } |
639 | 639 | } |
640 | 640 | if(e.length > level) { |
641 | | - var extras = e.substr(0, s.length - level), |
| 641 | + var extras = e.substr(0, e.length - level), |
642 | 642 | lastElem = c[c.length - 1]; |
643 | 643 | if(lastElem.type == 'TEXT') { |
644 | 644 | lastElem.value = lastElem.value + extras; |
— | — | @@ -647,7 +647,7 @@ |
648 | 648 | } |
649 | 649 | |
650 | 650 | return [{type: 'TAG', name: 'h' + level}] |
651 | | - .concat(c, [{type: 'ENDTAG', name: 'h' + level}]); |
| 651 | + .concat(c, [{type: 'ENDTAG', name: 'h' + level}, spc]); |
652 | 652 | } |
653 | 653 | / & { dp('nomatch exit h'); clearFlag('h'); return false } { return null } |
654 | 654 | ) { return r } |