blob: 4cbdcadaa747f56cc6f33f60cab5c05286c0afbe [file] [log] [blame]
Robert Sloan8ff03552017-06-14 12:40:58 -07001package main
2
3import (
4 "fmt"
5 "math"
6 "sort"
7 "strconv"
8)
9
10const endSymbol rune = 1114112
11
12/* The rule types inferred from the grammar are below. */
13type pegRule uint8
14
15const (
16 ruleUnknown pegRule = iota
17 ruleAsmFile
18 ruleStatement
19 ruleGlobalDirective
20 ruleDirective
21 ruleDirectiveName
22 ruleLocationDirective
23 ruleArgs
24 ruleArg
25 ruleQuotedArg
26 ruleQuotedText
27 ruleLabelContainingDirective
28 ruleLabelContainingDirectiveName
29 ruleSymbolArgs
30 ruleSymbolArg
31 ruleSymbolType
32 ruleDot
33 ruleTCMarker
34 ruleEscapedChar
35 ruleWS
36 ruleComment
37 ruleLabel
38 ruleSymbolName
39 ruleLocalSymbol
40 ruleLocalLabel
41 ruleLocalLabelRef
42 ruleInstruction
43 ruleInstructionName
44 ruleInstructionArg
45 ruleTOCRefHigh
46 ruleTOCRefLow
47 ruleIndirectionIndicator
48 ruleRegisterOrConstant
49 ruleMemoryRef
50 ruleSymbolRef
51 ruleBaseIndexScale
52 ruleOperator
53 ruleOffset
54 ruleSection
55 ruleSegmentRegister
56)
57
58var rul3s = [...]string{
59 "Unknown",
60 "AsmFile",
61 "Statement",
62 "GlobalDirective",
63 "Directive",
64 "DirectiveName",
65 "LocationDirective",
66 "Args",
67 "Arg",
68 "QuotedArg",
69 "QuotedText",
70 "LabelContainingDirective",
71 "LabelContainingDirectiveName",
72 "SymbolArgs",
73 "SymbolArg",
74 "SymbolType",
75 "Dot",
76 "TCMarker",
77 "EscapedChar",
78 "WS",
79 "Comment",
80 "Label",
81 "SymbolName",
82 "LocalSymbol",
83 "LocalLabel",
84 "LocalLabelRef",
85 "Instruction",
86 "InstructionName",
87 "InstructionArg",
88 "TOCRefHigh",
89 "TOCRefLow",
90 "IndirectionIndicator",
91 "RegisterOrConstant",
92 "MemoryRef",
93 "SymbolRef",
94 "BaseIndexScale",
95 "Operator",
96 "Offset",
97 "Section",
98 "SegmentRegister",
99}
100
101type token32 struct {
102 pegRule
103 begin, end uint32
104}
105
106func (t *token32) String() string {
107 return fmt.Sprintf("\x1B[34m%v\x1B[m %v %v", rul3s[t.pegRule], t.begin, t.end)
108}
109
110type node32 struct {
111 token32
112 up, next *node32
113}
114
115func (node *node32) print(pretty bool, buffer string) {
116 var print func(node *node32, depth int)
117 print = func(node *node32, depth int) {
118 for node != nil {
119 for c := 0; c < depth; c++ {
120 fmt.Printf(" ")
121 }
122 rule := rul3s[node.pegRule]
123 quote := strconv.Quote(string(([]rune(buffer)[node.begin:node.end])))
124 if !pretty {
125 fmt.Printf("%v %v\n", rule, quote)
126 } else {
127 fmt.Printf("\x1B[34m%v\x1B[m %v\n", rule, quote)
128 }
129 if node.up != nil {
130 print(node.up, depth+1)
131 }
132 node = node.next
133 }
134 }
135 print(node, 0)
136}
137
138func (node *node32) Print(buffer string) {
139 node.print(false, buffer)
140}
141
142func (node *node32) PrettyPrint(buffer string) {
143 node.print(true, buffer)
144}
145
146type tokens32 struct {
147 tree []token32
148}
149
150func (t *tokens32) Trim(length uint32) {
151 t.tree = t.tree[:length]
152}
153
154func (t *tokens32) Print() {
155 for _, token := range t.tree {
156 fmt.Println(token.String())
157 }
158}
159
160func (t *tokens32) AST() *node32 {
161 type element struct {
162 node *node32
163 down *element
164 }
165 tokens := t.Tokens()
166 var stack *element
167 for _, token := range tokens {
168 if token.begin == token.end {
169 continue
170 }
171 node := &node32{token32: token}
172 for stack != nil && stack.node.begin >= token.begin && stack.node.end <= token.end {
173 stack.node.next = node.up
174 node.up = stack.node
175 stack = stack.down
176 }
177 stack = &element{node: node, down: stack}
178 }
179 if stack != nil {
180 return stack.node
181 }
182 return nil
183}
184
185func (t *tokens32) PrintSyntaxTree(buffer string) {
186 t.AST().Print(buffer)
187}
188
189func (t *tokens32) PrettyPrintSyntaxTree(buffer string) {
190 t.AST().PrettyPrint(buffer)
191}
192
193func (t *tokens32) Add(rule pegRule, begin, end, index uint32) {
194 if tree := t.tree; int(index) >= len(tree) {
195 expanded := make([]token32, 2*len(tree))
196 copy(expanded, tree)
197 t.tree = expanded
198 }
199 t.tree[index] = token32{
200 pegRule: rule,
201 begin: begin,
202 end: end,
203 }
204}
205
206func (t *tokens32) Tokens() []token32 {
207 return t.tree
208}
209
210type Asm struct {
211 Buffer string
212 buffer []rune
213 rules [40]func() bool
214 parse func(rule ...int) error
215 reset func()
216 Pretty bool
217 tokens32
218}
219
220func (p *Asm) Parse(rule ...int) error {
221 return p.parse(rule...)
222}
223
224func (p *Asm) Reset() {
225 p.reset()
226}
227
228type textPosition struct {
229 line, symbol int
230}
231
232type textPositionMap map[int]textPosition
233
234func translatePositions(buffer []rune, positions []int) textPositionMap {
235 length, translations, j, line, symbol := len(positions), make(textPositionMap, len(positions)), 0, 1, 0
236 sort.Ints(positions)
237
238search:
239 for i, c := range buffer {
240 if c == '\n' {
241 line, symbol = line+1, 0
242 } else {
243 symbol++
244 }
245 if i == positions[j] {
246 translations[positions[j]] = textPosition{line, symbol}
247 for j++; j < length; j++ {
248 if i != positions[j] {
249 continue search
250 }
251 }
252 break search
253 }
254 }
255
256 return translations
257}
258
259type parseError struct {
260 p *Asm
261 max token32
262}
263
264func (e *parseError) Error() string {
265 tokens, error := []token32{e.max}, "\n"
266 positions, p := make([]int, 2*len(tokens)), 0
267 for _, token := range tokens {
268 positions[p], p = int(token.begin), p+1
269 positions[p], p = int(token.end), p+1
270 }
271 translations := translatePositions(e.p.buffer, positions)
272 format := "parse error near %v (line %v symbol %v - line %v symbol %v):\n%v\n"
273 if e.p.Pretty {
274 format = "parse error near \x1B[34m%v\x1B[m (line %v symbol %v - line %v symbol %v):\n%v\n"
275 }
276 for _, token := range tokens {
277 begin, end := int(token.begin), int(token.end)
278 error += fmt.Sprintf(format,
279 rul3s[token.pegRule],
280 translations[begin].line, translations[begin].symbol,
281 translations[end].line, translations[end].symbol,
282 strconv.Quote(string(e.p.buffer[begin:end])))
283 }
284
285 return error
286}
287
288func (p *Asm) PrintSyntaxTree() {
289 if p.Pretty {
290 p.tokens32.PrettyPrintSyntaxTree(p.Buffer)
291 } else {
292 p.tokens32.PrintSyntaxTree(p.Buffer)
293 }
294}
295
296func (p *Asm) Init() {
297 var (
298 max token32
299 position, tokenIndex uint32
300 buffer []rune
301 )
302 p.reset = func() {
303 max = token32{}
304 position, tokenIndex = 0, 0
305
306 p.buffer = []rune(p.Buffer)
307 if len(p.buffer) == 0 || p.buffer[len(p.buffer)-1] != endSymbol {
308 p.buffer = append(p.buffer, endSymbol)
309 }
310 buffer = p.buffer
311 }
312 p.reset()
313
314 _rules := p.rules
315 tree := tokens32{tree: make([]token32, math.MaxInt16)}
316 p.parse = func(rule ...int) error {
317 r := 1
318 if len(rule) > 0 {
319 r = rule[0]
320 }
321 matches := p.rules[r]()
322 p.tokens32 = tree
323 if matches {
324 p.Trim(tokenIndex)
325 return nil
326 }
327 return &parseError{p, max}
328 }
329
330 add := func(rule pegRule, begin uint32) {
331 tree.Add(rule, begin, position, tokenIndex)
332 tokenIndex++
333 if begin != position && position > max.end {
334 max = token32{rule, begin, position}
335 }
336 }
337
338 matchDot := func() bool {
339 if buffer[position] != endSymbol {
340 position++
341 return true
342 }
343 return false
344 }
345
346 /*matchChar := func(c byte) bool {
347 if buffer[position] == c {
348 position++
349 return true
350 }
351 return false
352 }*/
353
354 /*matchRange := func(lower byte, upper byte) bool {
355 if c := buffer[position]; c >= lower && c <= upper {
356 position++
357 return true
358 }
359 return false
360 }*/
361
362 _rules = [...]func() bool{
363 nil,
364 /* 0 AsmFile <- <(Statement* !.)> */
365 func() bool {
366 position0, tokenIndex0 := position, tokenIndex
367 {
368 position1 := position
369 l2:
370 {
371 position3, tokenIndex3 := position, tokenIndex
372 if !_rules[ruleStatement]() {
373 goto l3
374 }
375 goto l2
376 l3:
377 position, tokenIndex = position3, tokenIndex3
378 }
379 {
380 position4, tokenIndex4 := position, tokenIndex
381 if !matchDot() {
382 goto l4
383 }
384 goto l0
385 l4:
386 position, tokenIndex = position4, tokenIndex4
387 }
388 add(ruleAsmFile, position1)
389 }
390 return true
391 l0:
392 position, tokenIndex = position0, tokenIndex0
393 return false
394 },
395 /* 1 Statement <- <(WS? (Label / ((GlobalDirective / LocationDirective / LabelContainingDirective / Instruction / Directive / Comment / ) WS? ((Comment? '\n') / ';'))))> */
396 func() bool {
397 position5, tokenIndex5 := position, tokenIndex
398 {
399 position6 := position
400 {
401 position7, tokenIndex7 := position, tokenIndex
402 if !_rules[ruleWS]() {
403 goto l7
404 }
405 goto l8
406 l7:
407 position, tokenIndex = position7, tokenIndex7
408 }
409 l8:
410 {
411 position9, tokenIndex9 := position, tokenIndex
412 if !_rules[ruleLabel]() {
413 goto l10
414 }
415 goto l9
416 l10:
417 position, tokenIndex = position9, tokenIndex9
418 {
419 position11, tokenIndex11 := position, tokenIndex
420 if !_rules[ruleGlobalDirective]() {
421 goto l12
422 }
423 goto l11
424 l12:
425 position, tokenIndex = position11, tokenIndex11
426 if !_rules[ruleLocationDirective]() {
427 goto l13
428 }
429 goto l11
430 l13:
431 position, tokenIndex = position11, tokenIndex11
432 if !_rules[ruleLabelContainingDirective]() {
433 goto l14
434 }
435 goto l11
436 l14:
437 position, tokenIndex = position11, tokenIndex11
438 if !_rules[ruleInstruction]() {
439 goto l15
440 }
441 goto l11
442 l15:
443 position, tokenIndex = position11, tokenIndex11
444 if !_rules[ruleDirective]() {
445 goto l16
446 }
447 goto l11
448 l16:
449 position, tokenIndex = position11, tokenIndex11
450 if !_rules[ruleComment]() {
451 goto l17
452 }
453 goto l11
454 l17:
455 position, tokenIndex = position11, tokenIndex11
456 }
457 l11:
458 {
459 position18, tokenIndex18 := position, tokenIndex
460 if !_rules[ruleWS]() {
461 goto l18
462 }
463 goto l19
464 l18:
465 position, tokenIndex = position18, tokenIndex18
466 }
467 l19:
468 {
469 position20, tokenIndex20 := position, tokenIndex
470 {
471 position22, tokenIndex22 := position, tokenIndex
472 if !_rules[ruleComment]() {
473 goto l22
474 }
475 goto l23
476 l22:
477 position, tokenIndex = position22, tokenIndex22
478 }
479 l23:
480 if buffer[position] != rune('\n') {
481 goto l21
482 }
483 position++
484 goto l20
485 l21:
486 position, tokenIndex = position20, tokenIndex20
487 if buffer[position] != rune(';') {
488 goto l5
489 }
490 position++
491 }
492 l20:
493 }
494 l9:
495 add(ruleStatement, position6)
496 }
497 return true
498 l5:
499 position, tokenIndex = position5, tokenIndex5
500 return false
501 },
502 /* 2 GlobalDirective <- <((('.' ('g' / 'G') ('l' / 'L') ('o' / 'O') ('b' / 'B') ('a' / 'A') ('l' / 'L')) / ('.' ('g' / 'G') ('l' / 'L') ('o' / 'O') ('b' / 'B') ('l' / 'L'))) WS SymbolName)> */
503 func() bool {
504 position24, tokenIndex24 := position, tokenIndex
505 {
506 position25 := position
507 {
508 position26, tokenIndex26 := position, tokenIndex
509 if buffer[position] != rune('.') {
510 goto l27
511 }
512 position++
513 {
514 position28, tokenIndex28 := position, tokenIndex
515 if buffer[position] != rune('g') {
516 goto l29
517 }
518 position++
519 goto l28
520 l29:
521 position, tokenIndex = position28, tokenIndex28
522 if buffer[position] != rune('G') {
523 goto l27
524 }
525 position++
526 }
527 l28:
528 {
529 position30, tokenIndex30 := position, tokenIndex
530 if buffer[position] != rune('l') {
531 goto l31
532 }
533 position++
534 goto l30
535 l31:
536 position, tokenIndex = position30, tokenIndex30
537 if buffer[position] != rune('L') {
538 goto l27
539 }
540 position++
541 }
542 l30:
543 {
544 position32, tokenIndex32 := position, tokenIndex
545 if buffer[position] != rune('o') {
546 goto l33
547 }
548 position++
549 goto l32
550 l33:
551 position, tokenIndex = position32, tokenIndex32
552 if buffer[position] != rune('O') {
553 goto l27
554 }
555 position++
556 }
557 l32:
558 {
559 position34, tokenIndex34 := position, tokenIndex
560 if buffer[position] != rune('b') {
561 goto l35
562 }
563 position++
564 goto l34
565 l35:
566 position, tokenIndex = position34, tokenIndex34
567 if buffer[position] != rune('B') {
568 goto l27
569 }
570 position++
571 }
572 l34:
573 {
574 position36, tokenIndex36 := position, tokenIndex
575 if buffer[position] != rune('a') {
576 goto l37
577 }
578 position++
579 goto l36
580 l37:
581 position, tokenIndex = position36, tokenIndex36
582 if buffer[position] != rune('A') {
583 goto l27
584 }
585 position++
586 }
587 l36:
588 {
589 position38, tokenIndex38 := position, tokenIndex
590 if buffer[position] != rune('l') {
591 goto l39
592 }
593 position++
594 goto l38
595 l39:
596 position, tokenIndex = position38, tokenIndex38
597 if buffer[position] != rune('L') {
598 goto l27
599 }
600 position++
601 }
602 l38:
603 goto l26
604 l27:
605 position, tokenIndex = position26, tokenIndex26
606 if buffer[position] != rune('.') {
607 goto l24
608 }
609 position++
610 {
611 position40, tokenIndex40 := position, tokenIndex
612 if buffer[position] != rune('g') {
613 goto l41
614 }
615 position++
616 goto l40
617 l41:
618 position, tokenIndex = position40, tokenIndex40
619 if buffer[position] != rune('G') {
620 goto l24
621 }
622 position++
623 }
624 l40:
625 {
626 position42, tokenIndex42 := position, tokenIndex
627 if buffer[position] != rune('l') {
628 goto l43
629 }
630 position++
631 goto l42
632 l43:
633 position, tokenIndex = position42, tokenIndex42
634 if buffer[position] != rune('L') {
635 goto l24
636 }
637 position++
638 }
639 l42:
640 {
641 position44, tokenIndex44 := position, tokenIndex
642 if buffer[position] != rune('o') {
643 goto l45
644 }
645 position++
646 goto l44
647 l45:
648 position, tokenIndex = position44, tokenIndex44
649 if buffer[position] != rune('O') {
650 goto l24
651 }
652 position++
653 }
654 l44:
655 {
656 position46, tokenIndex46 := position, tokenIndex
657 if buffer[position] != rune('b') {
658 goto l47
659 }
660 position++
661 goto l46
662 l47:
663 position, tokenIndex = position46, tokenIndex46
664 if buffer[position] != rune('B') {
665 goto l24
666 }
667 position++
668 }
669 l46:
670 {
671 position48, tokenIndex48 := position, tokenIndex
672 if buffer[position] != rune('l') {
673 goto l49
674 }
675 position++
676 goto l48
677 l49:
678 position, tokenIndex = position48, tokenIndex48
679 if buffer[position] != rune('L') {
680 goto l24
681 }
682 position++
683 }
684 l48:
685 }
686 l26:
687 if !_rules[ruleWS]() {
688 goto l24
689 }
690 if !_rules[ruleSymbolName]() {
691 goto l24
692 }
693 add(ruleGlobalDirective, position25)
694 }
695 return true
696 l24:
697 position, tokenIndex = position24, tokenIndex24
698 return false
699 },
700 /* 3 Directive <- <('.' DirectiveName (WS Args)?)> */
701 func() bool {
702 position50, tokenIndex50 := position, tokenIndex
703 {
704 position51 := position
705 if buffer[position] != rune('.') {
706 goto l50
707 }
708 position++
709 if !_rules[ruleDirectiveName]() {
710 goto l50
711 }
712 {
713 position52, tokenIndex52 := position, tokenIndex
714 if !_rules[ruleWS]() {
715 goto l52
716 }
717 if !_rules[ruleArgs]() {
718 goto l52
719 }
720 goto l53
721 l52:
722 position, tokenIndex = position52, tokenIndex52
723 }
724 l53:
725 add(ruleDirective, position51)
726 }
727 return true
728 l50:
729 position, tokenIndex = position50, tokenIndex50
730 return false
731 },
732 /* 4 DirectiveName <- <([a-z] / [A-Z] / ([0-9] / [0-9]) / '_')+> */
733 func() bool {
734 position54, tokenIndex54 := position, tokenIndex
735 {
736 position55 := position
737 {
738 position58, tokenIndex58 := position, tokenIndex
739 if c := buffer[position]; c < rune('a') || c > rune('z') {
740 goto l59
741 }
742 position++
743 goto l58
744 l59:
745 position, tokenIndex = position58, tokenIndex58
746 if c := buffer[position]; c < rune('A') || c > rune('Z') {
747 goto l60
748 }
749 position++
750 goto l58
751 l60:
752 position, tokenIndex = position58, tokenIndex58
753 {
754 position62, tokenIndex62 := position, tokenIndex
755 if c := buffer[position]; c < rune('0') || c > rune('9') {
756 goto l63
757 }
758 position++
759 goto l62
760 l63:
761 position, tokenIndex = position62, tokenIndex62
762 if c := buffer[position]; c < rune('0') || c > rune('9') {
763 goto l61
764 }
765 position++
766 }
767 l62:
768 goto l58
769 l61:
770 position, tokenIndex = position58, tokenIndex58
771 if buffer[position] != rune('_') {
772 goto l54
773 }
774 position++
775 }
776 l58:
777 l56:
778 {
779 position57, tokenIndex57 := position, tokenIndex
780 {
781 position64, tokenIndex64 := position, tokenIndex
782 if c := buffer[position]; c < rune('a') || c > rune('z') {
783 goto l65
784 }
785 position++
786 goto l64
787 l65:
788 position, tokenIndex = position64, tokenIndex64
789 if c := buffer[position]; c < rune('A') || c > rune('Z') {
790 goto l66
791 }
792 position++
793 goto l64
794 l66:
795 position, tokenIndex = position64, tokenIndex64
796 {
797 position68, tokenIndex68 := position, tokenIndex
798 if c := buffer[position]; c < rune('0') || c > rune('9') {
799 goto l69
800 }
801 position++
802 goto l68
803 l69:
804 position, tokenIndex = position68, tokenIndex68
805 if c := buffer[position]; c < rune('0') || c > rune('9') {
806 goto l67
807 }
808 position++
809 }
810 l68:
811 goto l64
812 l67:
813 position, tokenIndex = position64, tokenIndex64
814 if buffer[position] != rune('_') {
815 goto l57
816 }
817 position++
818 }
819 l64:
820 goto l56
821 l57:
822 position, tokenIndex = position57, tokenIndex57
823 }
824 add(ruleDirectiveName, position55)
825 }
826 return true
827 l54:
828 position, tokenIndex = position54, tokenIndex54
829 return false
830 },
831 /* 5 LocationDirective <- <((('.' ('f' / 'F') ('i' / 'I') ('l' / 'L') ('e' / 'E')) / ('.' ('l' / 'L') ('o' / 'O') ('c' / 'C'))) WS (!('#' / '\n') .)+)> */
832 func() bool {
833 position70, tokenIndex70 := position, tokenIndex
834 {
835 position71 := position
836 {
837 position72, tokenIndex72 := position, tokenIndex
838 if buffer[position] != rune('.') {
839 goto l73
840 }
841 position++
842 {
843 position74, tokenIndex74 := position, tokenIndex
844 if buffer[position] != rune('f') {
845 goto l75
846 }
847 position++
848 goto l74
849 l75:
850 position, tokenIndex = position74, tokenIndex74
851 if buffer[position] != rune('F') {
852 goto l73
853 }
854 position++
855 }
856 l74:
857 {
858 position76, tokenIndex76 := position, tokenIndex
859 if buffer[position] != rune('i') {
860 goto l77
861 }
862 position++
863 goto l76
864 l77:
865 position, tokenIndex = position76, tokenIndex76
866 if buffer[position] != rune('I') {
867 goto l73
868 }
869 position++
870 }
871 l76:
872 {
873 position78, tokenIndex78 := position, tokenIndex
874 if buffer[position] != rune('l') {
875 goto l79
876 }
877 position++
878 goto l78
879 l79:
880 position, tokenIndex = position78, tokenIndex78
881 if buffer[position] != rune('L') {
882 goto l73
883 }
884 position++
885 }
886 l78:
887 {
888 position80, tokenIndex80 := position, tokenIndex
889 if buffer[position] != rune('e') {
890 goto l81
891 }
892 position++
893 goto l80
894 l81:
895 position, tokenIndex = position80, tokenIndex80
896 if buffer[position] != rune('E') {
897 goto l73
898 }
899 position++
900 }
901 l80:
902 goto l72
903 l73:
904 position, tokenIndex = position72, tokenIndex72
905 if buffer[position] != rune('.') {
906 goto l70
907 }
908 position++
909 {
910 position82, tokenIndex82 := position, tokenIndex
911 if buffer[position] != rune('l') {
912 goto l83
913 }
914 position++
915 goto l82
916 l83:
917 position, tokenIndex = position82, tokenIndex82
918 if buffer[position] != rune('L') {
919 goto l70
920 }
921 position++
922 }
923 l82:
924 {
925 position84, tokenIndex84 := position, tokenIndex
926 if buffer[position] != rune('o') {
927 goto l85
928 }
929 position++
930 goto l84
931 l85:
932 position, tokenIndex = position84, tokenIndex84
933 if buffer[position] != rune('O') {
934 goto l70
935 }
936 position++
937 }
938 l84:
939 {
940 position86, tokenIndex86 := position, tokenIndex
941 if buffer[position] != rune('c') {
942 goto l87
943 }
944 position++
945 goto l86
946 l87:
947 position, tokenIndex = position86, tokenIndex86
948 if buffer[position] != rune('C') {
949 goto l70
950 }
951 position++
952 }
953 l86:
954 }
955 l72:
956 if !_rules[ruleWS]() {
957 goto l70
958 }
959 {
960 position90, tokenIndex90 := position, tokenIndex
961 {
962 position91, tokenIndex91 := position, tokenIndex
963 if buffer[position] != rune('#') {
964 goto l92
965 }
966 position++
967 goto l91
968 l92:
969 position, tokenIndex = position91, tokenIndex91
970 if buffer[position] != rune('\n') {
971 goto l90
972 }
973 position++
974 }
975 l91:
976 goto l70
977 l90:
978 position, tokenIndex = position90, tokenIndex90
979 }
980 if !matchDot() {
981 goto l70
982 }
983 l88:
984 {
985 position89, tokenIndex89 := position, tokenIndex
986 {
987 position93, tokenIndex93 := position, tokenIndex
988 {
989 position94, tokenIndex94 := position, tokenIndex
990 if buffer[position] != rune('#') {
991 goto l95
992 }
993 position++
994 goto l94
995 l95:
996 position, tokenIndex = position94, tokenIndex94
997 if buffer[position] != rune('\n') {
998 goto l93
999 }
1000 position++
1001 }
1002 l94:
1003 goto l89
1004 l93:
1005 position, tokenIndex = position93, tokenIndex93
1006 }
1007 if !matchDot() {
1008 goto l89
1009 }
1010 goto l88
1011 l89:
1012 position, tokenIndex = position89, tokenIndex89
1013 }
1014 add(ruleLocationDirective, position71)
1015 }
1016 return true
1017 l70:
1018 position, tokenIndex = position70, tokenIndex70
1019 return false
1020 },
1021 /* 6 Args <- <(Arg (WS? ',' WS? Arg)*)> */
1022 func() bool {
1023 position96, tokenIndex96 := position, tokenIndex
1024 {
1025 position97 := position
1026 if !_rules[ruleArg]() {
1027 goto l96
1028 }
1029 l98:
1030 {
1031 position99, tokenIndex99 := position, tokenIndex
1032 {
1033 position100, tokenIndex100 := position, tokenIndex
1034 if !_rules[ruleWS]() {
1035 goto l100
1036 }
1037 goto l101
1038 l100:
1039 position, tokenIndex = position100, tokenIndex100
1040 }
1041 l101:
1042 if buffer[position] != rune(',') {
1043 goto l99
1044 }
1045 position++
1046 {
1047 position102, tokenIndex102 := position, tokenIndex
1048 if !_rules[ruleWS]() {
1049 goto l102
1050 }
1051 goto l103
1052 l102:
1053 position, tokenIndex = position102, tokenIndex102
1054 }
1055 l103:
1056 if !_rules[ruleArg]() {
1057 goto l99
1058 }
1059 goto l98
1060 l99:
1061 position, tokenIndex = position99, tokenIndex99
1062 }
1063 add(ruleArgs, position97)
1064 }
1065 return true
1066 l96:
1067 position, tokenIndex = position96, tokenIndex96
1068 return false
1069 },
1070 /* 7 Arg <- <(QuotedArg / ([0-9] / [0-9] / ([a-z] / [A-Z]) / '%' / '+' / '-' / '_' / '@' / '.')*)> */
1071 func() bool {
1072 {
1073 position105 := position
1074 {
1075 position106, tokenIndex106 := position, tokenIndex
1076 if !_rules[ruleQuotedArg]() {
1077 goto l107
1078 }
1079 goto l106
1080 l107:
1081 position, tokenIndex = position106, tokenIndex106
1082 l108:
1083 {
1084 position109, tokenIndex109 := position, tokenIndex
1085 {
1086 position110, tokenIndex110 := position, tokenIndex
1087 if c := buffer[position]; c < rune('0') || c > rune('9') {
1088 goto l111
1089 }
1090 position++
1091 goto l110
1092 l111:
1093 position, tokenIndex = position110, tokenIndex110
1094 if c := buffer[position]; c < rune('0') || c > rune('9') {
1095 goto l112
1096 }
1097 position++
1098 goto l110
1099 l112:
1100 position, tokenIndex = position110, tokenIndex110
1101 {
1102 position114, tokenIndex114 := position, tokenIndex
1103 if c := buffer[position]; c < rune('a') || c > rune('z') {
1104 goto l115
1105 }
1106 position++
1107 goto l114
1108 l115:
1109 position, tokenIndex = position114, tokenIndex114
1110 if c := buffer[position]; c < rune('A') || c > rune('Z') {
1111 goto l113
1112 }
1113 position++
1114 }
1115 l114:
1116 goto l110
1117 l113:
1118 position, tokenIndex = position110, tokenIndex110
1119 if buffer[position] != rune('%') {
1120 goto l116
1121 }
1122 position++
1123 goto l110
1124 l116:
1125 position, tokenIndex = position110, tokenIndex110
1126 if buffer[position] != rune('+') {
1127 goto l117
1128 }
1129 position++
1130 goto l110
1131 l117:
1132 position, tokenIndex = position110, tokenIndex110
1133 if buffer[position] != rune('-') {
1134 goto l118
1135 }
1136 position++
1137 goto l110
1138 l118:
1139 position, tokenIndex = position110, tokenIndex110
1140 if buffer[position] != rune('_') {
1141 goto l119
1142 }
1143 position++
1144 goto l110
1145 l119:
1146 position, tokenIndex = position110, tokenIndex110
1147 if buffer[position] != rune('@') {
1148 goto l120
1149 }
1150 position++
1151 goto l110
1152 l120:
1153 position, tokenIndex = position110, tokenIndex110
1154 if buffer[position] != rune('.') {
1155 goto l109
1156 }
1157 position++
1158 }
1159 l110:
1160 goto l108
1161 l109:
1162 position, tokenIndex = position109, tokenIndex109
1163 }
1164 }
1165 l106:
1166 add(ruleArg, position105)
1167 }
1168 return true
1169 },
1170 /* 8 QuotedArg <- <('"' QuotedText '"')> */
1171 func() bool {
1172 position121, tokenIndex121 := position, tokenIndex
1173 {
1174 position122 := position
1175 if buffer[position] != rune('"') {
1176 goto l121
1177 }
1178 position++
1179 if !_rules[ruleQuotedText]() {
1180 goto l121
1181 }
1182 if buffer[position] != rune('"') {
1183 goto l121
1184 }
1185 position++
1186 add(ruleQuotedArg, position122)
1187 }
1188 return true
1189 l121:
1190 position, tokenIndex = position121, tokenIndex121
1191 return false
1192 },
1193 /* 9 QuotedText <- <(EscapedChar / (!'"' .))*> */
1194 func() bool {
1195 {
1196 position124 := position
1197 l125:
1198 {
1199 position126, tokenIndex126 := position, tokenIndex
1200 {
1201 position127, tokenIndex127 := position, tokenIndex
1202 if !_rules[ruleEscapedChar]() {
1203 goto l128
1204 }
1205 goto l127
1206 l128:
1207 position, tokenIndex = position127, tokenIndex127
1208 {
1209 position129, tokenIndex129 := position, tokenIndex
1210 if buffer[position] != rune('"') {
1211 goto l129
1212 }
1213 position++
1214 goto l126
1215 l129:
1216 position, tokenIndex = position129, tokenIndex129
1217 }
1218 if !matchDot() {
1219 goto l126
1220 }
1221 }
1222 l127:
1223 goto l125
1224 l126:
1225 position, tokenIndex = position126, tokenIndex126
1226 }
1227 add(ruleQuotedText, position124)
1228 }
1229 return true
1230 },
1231 /* 10 LabelContainingDirective <- <(LabelContainingDirectiveName WS SymbolArgs)> */
1232 func() bool {
1233 position130, tokenIndex130 := position, tokenIndex
1234 {
1235 position131 := position
1236 if !_rules[ruleLabelContainingDirectiveName]() {
1237 goto l130
1238 }
1239 if !_rules[ruleWS]() {
1240 goto l130
1241 }
1242 if !_rules[ruleSymbolArgs]() {
1243 goto l130
1244 }
1245 add(ruleLabelContainingDirective, position131)
1246 }
1247 return true
1248 l130:
1249 position, tokenIndex = position130, tokenIndex130
1250 return false
1251 },
1252 /* 11 LabelContainingDirectiveName <- <(('.' ('l' / 'L') ('o' / 'O') ('n' / 'N') ('g' / 'G')) / ('.' ('s' / 'S') ('e' / 'E') ('t' / 'T')) / ('.' '8' ('b' / 'B') ('y' / 'Y') ('t' / 'T') ('e' / 'E')) / ('.' '4' ('b' / 'B') ('y' / 'Y') ('t' / 'T') ('e' / 'E')) / ('.' ('q' / 'Q') ('u' / 'U') ('a' / 'A') ('d' / 'D')) / ('.' ('t' / 'T') ('c' / 'C')) / ('.' ('l' / 'L') ('o' / 'O') ('c' / 'C') ('a' / 'A') ('l' / 'L') ('e' / 'E') ('n' / 'N') ('t' / 'T') ('r' / 'R') ('y' / 'Y')) / ('.' ('s' / 'S') ('i' / 'I') ('z' / 'Z') ('e' / 'E')) / ('.' ('t' / 'T') ('y' / 'Y') ('p' / 'P') ('e' / 'E')))> */
1253 func() bool {
1254 position132, tokenIndex132 := position, tokenIndex
1255 {
1256 position133 := position
1257 {
1258 position134, tokenIndex134 := position, tokenIndex
1259 if buffer[position] != rune('.') {
1260 goto l135
1261 }
1262 position++
1263 {
1264 position136, tokenIndex136 := position, tokenIndex
1265 if buffer[position] != rune('l') {
1266 goto l137
1267 }
1268 position++
1269 goto l136
1270 l137:
1271 position, tokenIndex = position136, tokenIndex136
1272 if buffer[position] != rune('L') {
1273 goto l135
1274 }
1275 position++
1276 }
1277 l136:
1278 {
1279 position138, tokenIndex138 := position, tokenIndex
1280 if buffer[position] != rune('o') {
1281 goto l139
1282 }
1283 position++
1284 goto l138
1285 l139:
1286 position, tokenIndex = position138, tokenIndex138
1287 if buffer[position] != rune('O') {
1288 goto l135
1289 }
1290 position++
1291 }
1292 l138:
1293 {
1294 position140, tokenIndex140 := position, tokenIndex
1295 if buffer[position] != rune('n') {
1296 goto l141
1297 }
1298 position++
1299 goto l140
1300 l141:
1301 position, tokenIndex = position140, tokenIndex140
1302 if buffer[position] != rune('N') {
1303 goto l135
1304 }
1305 position++
1306 }
1307 l140:
1308 {
1309 position142, tokenIndex142 := position, tokenIndex
1310 if buffer[position] != rune('g') {
1311 goto l143
1312 }
1313 position++
1314 goto l142
1315 l143:
1316 position, tokenIndex = position142, tokenIndex142
1317 if buffer[position] != rune('G') {
1318 goto l135
1319 }
1320 position++
1321 }
1322 l142:
1323 goto l134
1324 l135:
1325 position, tokenIndex = position134, tokenIndex134
1326 if buffer[position] != rune('.') {
1327 goto l144
1328 }
1329 position++
1330 {
1331 position145, tokenIndex145 := position, tokenIndex
1332 if buffer[position] != rune('s') {
1333 goto l146
1334 }
1335 position++
1336 goto l145
1337 l146:
1338 position, tokenIndex = position145, tokenIndex145
1339 if buffer[position] != rune('S') {
1340 goto l144
1341 }
1342 position++
1343 }
1344 l145:
1345 {
1346 position147, tokenIndex147 := position, tokenIndex
1347 if buffer[position] != rune('e') {
1348 goto l148
1349 }
1350 position++
1351 goto l147
1352 l148:
1353 position, tokenIndex = position147, tokenIndex147
1354 if buffer[position] != rune('E') {
1355 goto l144
1356 }
1357 position++
1358 }
1359 l147:
1360 {
1361 position149, tokenIndex149 := position, tokenIndex
1362 if buffer[position] != rune('t') {
1363 goto l150
1364 }
1365 position++
1366 goto l149
1367 l150:
1368 position, tokenIndex = position149, tokenIndex149
1369 if buffer[position] != rune('T') {
1370 goto l144
1371 }
1372 position++
1373 }
1374 l149:
1375 goto l134
1376 l144:
1377 position, tokenIndex = position134, tokenIndex134
1378 if buffer[position] != rune('.') {
1379 goto l151
1380 }
1381 position++
1382 if buffer[position] != rune('8') {
1383 goto l151
1384 }
1385 position++
1386 {
1387 position152, tokenIndex152 := position, tokenIndex
1388 if buffer[position] != rune('b') {
1389 goto l153
1390 }
1391 position++
1392 goto l152
1393 l153:
1394 position, tokenIndex = position152, tokenIndex152
1395 if buffer[position] != rune('B') {
1396 goto l151
1397 }
1398 position++
1399 }
1400 l152:
1401 {
1402 position154, tokenIndex154 := position, tokenIndex
1403 if buffer[position] != rune('y') {
1404 goto l155
1405 }
1406 position++
1407 goto l154
1408 l155:
1409 position, tokenIndex = position154, tokenIndex154
1410 if buffer[position] != rune('Y') {
1411 goto l151
1412 }
1413 position++
1414 }
1415 l154:
1416 {
1417 position156, tokenIndex156 := position, tokenIndex
1418 if buffer[position] != rune('t') {
1419 goto l157
1420 }
1421 position++
1422 goto l156
1423 l157:
1424 position, tokenIndex = position156, tokenIndex156
1425 if buffer[position] != rune('T') {
1426 goto l151
1427 }
1428 position++
1429 }
1430 l156:
1431 {
1432 position158, tokenIndex158 := position, tokenIndex
1433 if buffer[position] != rune('e') {
1434 goto l159
1435 }
1436 position++
1437 goto l158
1438 l159:
1439 position, tokenIndex = position158, tokenIndex158
1440 if buffer[position] != rune('E') {
1441 goto l151
1442 }
1443 position++
1444 }
1445 l158:
1446 goto l134
1447 l151:
1448 position, tokenIndex = position134, tokenIndex134
1449 if buffer[position] != rune('.') {
1450 goto l160
1451 }
1452 position++
1453 if buffer[position] != rune('4') {
1454 goto l160
1455 }
1456 position++
1457 {
1458 position161, tokenIndex161 := position, tokenIndex
1459 if buffer[position] != rune('b') {
1460 goto l162
1461 }
1462 position++
1463 goto l161
1464 l162:
1465 position, tokenIndex = position161, tokenIndex161
1466 if buffer[position] != rune('B') {
1467 goto l160
1468 }
1469 position++
1470 }
1471 l161:
1472 {
1473 position163, tokenIndex163 := position, tokenIndex
1474 if buffer[position] != rune('y') {
1475 goto l164
1476 }
1477 position++
1478 goto l163
1479 l164:
1480 position, tokenIndex = position163, tokenIndex163
1481 if buffer[position] != rune('Y') {
1482 goto l160
1483 }
1484 position++
1485 }
1486 l163:
1487 {
1488 position165, tokenIndex165 := position, tokenIndex
1489 if buffer[position] != rune('t') {
1490 goto l166
1491 }
1492 position++
1493 goto l165
1494 l166:
1495 position, tokenIndex = position165, tokenIndex165
1496 if buffer[position] != rune('T') {
1497 goto l160
1498 }
1499 position++
1500 }
1501 l165:
1502 {
1503 position167, tokenIndex167 := position, tokenIndex
1504 if buffer[position] != rune('e') {
1505 goto l168
1506 }
1507 position++
1508 goto l167
1509 l168:
1510 position, tokenIndex = position167, tokenIndex167
1511 if buffer[position] != rune('E') {
1512 goto l160
1513 }
1514 position++
1515 }
1516 l167:
1517 goto l134
1518 l160:
1519 position, tokenIndex = position134, tokenIndex134
1520 if buffer[position] != rune('.') {
1521 goto l169
1522 }
1523 position++
1524 {
1525 position170, tokenIndex170 := position, tokenIndex
1526 if buffer[position] != rune('q') {
1527 goto l171
1528 }
1529 position++
1530 goto l170
1531 l171:
1532 position, tokenIndex = position170, tokenIndex170
1533 if buffer[position] != rune('Q') {
1534 goto l169
1535 }
1536 position++
1537 }
1538 l170:
1539 {
1540 position172, tokenIndex172 := position, tokenIndex
1541 if buffer[position] != rune('u') {
1542 goto l173
1543 }
1544 position++
1545 goto l172
1546 l173:
1547 position, tokenIndex = position172, tokenIndex172
1548 if buffer[position] != rune('U') {
1549 goto l169
1550 }
1551 position++
1552 }
1553 l172:
1554 {
1555 position174, tokenIndex174 := position, tokenIndex
1556 if buffer[position] != rune('a') {
1557 goto l175
1558 }
1559 position++
1560 goto l174
1561 l175:
1562 position, tokenIndex = position174, tokenIndex174
1563 if buffer[position] != rune('A') {
1564 goto l169
1565 }
1566 position++
1567 }
1568 l174:
1569 {
1570 position176, tokenIndex176 := position, tokenIndex
1571 if buffer[position] != rune('d') {
1572 goto l177
1573 }
1574 position++
1575 goto l176
1576 l177:
1577 position, tokenIndex = position176, tokenIndex176
1578 if buffer[position] != rune('D') {
1579 goto l169
1580 }
1581 position++
1582 }
1583 l176:
1584 goto l134
1585 l169:
1586 position, tokenIndex = position134, tokenIndex134
1587 if buffer[position] != rune('.') {
1588 goto l178
1589 }
1590 position++
1591 {
1592 position179, tokenIndex179 := position, tokenIndex
1593 if buffer[position] != rune('t') {
1594 goto l180
1595 }
1596 position++
1597 goto l179
1598 l180:
1599 position, tokenIndex = position179, tokenIndex179
1600 if buffer[position] != rune('T') {
1601 goto l178
1602 }
1603 position++
1604 }
1605 l179:
1606 {
1607 position181, tokenIndex181 := position, tokenIndex
1608 if buffer[position] != rune('c') {
1609 goto l182
1610 }
1611 position++
1612 goto l181
1613 l182:
1614 position, tokenIndex = position181, tokenIndex181
1615 if buffer[position] != rune('C') {
1616 goto l178
1617 }
1618 position++
1619 }
1620 l181:
1621 goto l134
1622 l178:
1623 position, tokenIndex = position134, tokenIndex134
1624 if buffer[position] != rune('.') {
1625 goto l183
1626 }
1627 position++
1628 {
1629 position184, tokenIndex184 := position, tokenIndex
1630 if buffer[position] != rune('l') {
1631 goto l185
1632 }
1633 position++
1634 goto l184
1635 l185:
1636 position, tokenIndex = position184, tokenIndex184
1637 if buffer[position] != rune('L') {
1638 goto l183
1639 }
1640 position++
1641 }
1642 l184:
1643 {
1644 position186, tokenIndex186 := position, tokenIndex
1645 if buffer[position] != rune('o') {
1646 goto l187
1647 }
1648 position++
1649 goto l186
1650 l187:
1651 position, tokenIndex = position186, tokenIndex186
1652 if buffer[position] != rune('O') {
1653 goto l183
1654 }
1655 position++
1656 }
1657 l186:
1658 {
1659 position188, tokenIndex188 := position, tokenIndex
1660 if buffer[position] != rune('c') {
1661 goto l189
1662 }
1663 position++
1664 goto l188
1665 l189:
1666 position, tokenIndex = position188, tokenIndex188
1667 if buffer[position] != rune('C') {
1668 goto l183
1669 }
1670 position++
1671 }
1672 l188:
1673 {
1674 position190, tokenIndex190 := position, tokenIndex
1675 if buffer[position] != rune('a') {
1676 goto l191
1677 }
1678 position++
1679 goto l190
1680 l191:
1681 position, tokenIndex = position190, tokenIndex190
1682 if buffer[position] != rune('A') {
1683 goto l183
1684 }
1685 position++
1686 }
1687 l190:
1688 {
1689 position192, tokenIndex192 := position, tokenIndex
1690 if buffer[position] != rune('l') {
1691 goto l193
1692 }
1693 position++
1694 goto l192
1695 l193:
1696 position, tokenIndex = position192, tokenIndex192
1697 if buffer[position] != rune('L') {
1698 goto l183
1699 }
1700 position++
1701 }
1702 l192:
1703 {
1704 position194, tokenIndex194 := position, tokenIndex
1705 if buffer[position] != rune('e') {
1706 goto l195
1707 }
1708 position++
1709 goto l194
1710 l195:
1711 position, tokenIndex = position194, tokenIndex194
1712 if buffer[position] != rune('E') {
1713 goto l183
1714 }
1715 position++
1716 }
1717 l194:
1718 {
1719 position196, tokenIndex196 := position, tokenIndex
1720 if buffer[position] != rune('n') {
1721 goto l197
1722 }
1723 position++
1724 goto l196
1725 l197:
1726 position, tokenIndex = position196, tokenIndex196
1727 if buffer[position] != rune('N') {
1728 goto l183
1729 }
1730 position++
1731 }
1732 l196:
1733 {
1734 position198, tokenIndex198 := position, tokenIndex
1735 if buffer[position] != rune('t') {
1736 goto l199
1737 }
1738 position++
1739 goto l198
1740 l199:
1741 position, tokenIndex = position198, tokenIndex198
1742 if buffer[position] != rune('T') {
1743 goto l183
1744 }
1745 position++
1746 }
1747 l198:
1748 {
1749 position200, tokenIndex200 := position, tokenIndex
1750 if buffer[position] != rune('r') {
1751 goto l201
1752 }
1753 position++
1754 goto l200
1755 l201:
1756 position, tokenIndex = position200, tokenIndex200
1757 if buffer[position] != rune('R') {
1758 goto l183
1759 }
1760 position++
1761 }
1762 l200:
1763 {
1764 position202, tokenIndex202 := position, tokenIndex
1765 if buffer[position] != rune('y') {
1766 goto l203
1767 }
1768 position++
1769 goto l202
1770 l203:
1771 position, tokenIndex = position202, tokenIndex202
1772 if buffer[position] != rune('Y') {
1773 goto l183
1774 }
1775 position++
1776 }
1777 l202:
1778 goto l134
1779 l183:
1780 position, tokenIndex = position134, tokenIndex134
1781 if buffer[position] != rune('.') {
1782 goto l204
1783 }
1784 position++
1785 {
1786 position205, tokenIndex205 := position, tokenIndex
1787 if buffer[position] != rune('s') {
1788 goto l206
1789 }
1790 position++
1791 goto l205
1792 l206:
1793 position, tokenIndex = position205, tokenIndex205
1794 if buffer[position] != rune('S') {
1795 goto l204
1796 }
1797 position++
1798 }
1799 l205:
1800 {
1801 position207, tokenIndex207 := position, tokenIndex
1802 if buffer[position] != rune('i') {
1803 goto l208
1804 }
1805 position++
1806 goto l207
1807 l208:
1808 position, tokenIndex = position207, tokenIndex207
1809 if buffer[position] != rune('I') {
1810 goto l204
1811 }
1812 position++
1813 }
1814 l207:
1815 {
1816 position209, tokenIndex209 := position, tokenIndex
1817 if buffer[position] != rune('z') {
1818 goto l210
1819 }
1820 position++
1821 goto l209
1822 l210:
1823 position, tokenIndex = position209, tokenIndex209
1824 if buffer[position] != rune('Z') {
1825 goto l204
1826 }
1827 position++
1828 }
1829 l209:
1830 {
1831 position211, tokenIndex211 := position, tokenIndex
1832 if buffer[position] != rune('e') {
1833 goto l212
1834 }
1835 position++
1836 goto l211
1837 l212:
1838 position, tokenIndex = position211, tokenIndex211
1839 if buffer[position] != rune('E') {
1840 goto l204
1841 }
1842 position++
1843 }
1844 l211:
1845 goto l134
1846 l204:
1847 position, tokenIndex = position134, tokenIndex134
1848 if buffer[position] != rune('.') {
1849 goto l132
1850 }
1851 position++
1852 {
1853 position213, tokenIndex213 := position, tokenIndex
1854 if buffer[position] != rune('t') {
1855 goto l214
1856 }
1857 position++
1858 goto l213
1859 l214:
1860 position, tokenIndex = position213, tokenIndex213
1861 if buffer[position] != rune('T') {
1862 goto l132
1863 }
1864 position++
1865 }
1866 l213:
1867 {
1868 position215, tokenIndex215 := position, tokenIndex
1869 if buffer[position] != rune('y') {
1870 goto l216
1871 }
1872 position++
1873 goto l215
1874 l216:
1875 position, tokenIndex = position215, tokenIndex215
1876 if buffer[position] != rune('Y') {
1877 goto l132
1878 }
1879 position++
1880 }
1881 l215:
1882 {
1883 position217, tokenIndex217 := position, tokenIndex
1884 if buffer[position] != rune('p') {
1885 goto l218
1886 }
1887 position++
1888 goto l217
1889 l218:
1890 position, tokenIndex = position217, tokenIndex217
1891 if buffer[position] != rune('P') {
1892 goto l132
1893 }
1894 position++
1895 }
1896 l217:
1897 {
1898 position219, tokenIndex219 := position, tokenIndex
1899 if buffer[position] != rune('e') {
1900 goto l220
1901 }
1902 position++
1903 goto l219
1904 l220:
1905 position, tokenIndex = position219, tokenIndex219
1906 if buffer[position] != rune('E') {
1907 goto l132
1908 }
1909 position++
1910 }
1911 l219:
1912 }
1913 l134:
1914 add(ruleLabelContainingDirectiveName, position133)
1915 }
1916 return true
1917 l132:
1918 position, tokenIndex = position132, tokenIndex132
1919 return false
1920 },
1921 /* 12 SymbolArgs <- <(SymbolArg (WS? ',' WS? SymbolArg)*)> */
1922 func() bool {
1923 position221, tokenIndex221 := position, tokenIndex
1924 {
1925 position222 := position
1926 if !_rules[ruleSymbolArg]() {
1927 goto l221
1928 }
1929 l223:
1930 {
1931 position224, tokenIndex224 := position, tokenIndex
1932 {
1933 position225, tokenIndex225 := position, tokenIndex
1934 if !_rules[ruleWS]() {
1935 goto l225
1936 }
1937 goto l226
1938 l225:
1939 position, tokenIndex = position225, tokenIndex225
1940 }
1941 l226:
1942 if buffer[position] != rune(',') {
1943 goto l224
1944 }
1945 position++
1946 {
1947 position227, tokenIndex227 := position, tokenIndex
1948 if !_rules[ruleWS]() {
1949 goto l227
1950 }
1951 goto l228
1952 l227:
1953 position, tokenIndex = position227, tokenIndex227
1954 }
1955 l228:
1956 if !_rules[ruleSymbolArg]() {
1957 goto l224
1958 }
1959 goto l223
1960 l224:
1961 position, tokenIndex = position224, tokenIndex224
1962 }
1963 add(ruleSymbolArgs, position222)
1964 }
1965 return true
1966 l221:
1967 position, tokenIndex = position221, tokenIndex221
1968 return false
1969 },
1970 /* 13 SymbolArg <- <(Offset / SymbolType / ((Offset / LocalSymbol / SymbolName / Dot) WS? Operator WS? (Offset / LocalSymbol / SymbolName)) / (LocalSymbol TCMarker?) / (SymbolName Offset) / (SymbolName TCMarker?))> */
1971 func() bool {
1972 position229, tokenIndex229 := position, tokenIndex
1973 {
1974 position230 := position
1975 {
1976 position231, tokenIndex231 := position, tokenIndex
1977 if !_rules[ruleOffset]() {
1978 goto l232
1979 }
1980 goto l231
1981 l232:
1982 position, tokenIndex = position231, tokenIndex231
1983 if !_rules[ruleSymbolType]() {
1984 goto l233
1985 }
1986 goto l231
1987 l233:
1988 position, tokenIndex = position231, tokenIndex231
1989 {
1990 position235, tokenIndex235 := position, tokenIndex
1991 if !_rules[ruleOffset]() {
1992 goto l236
1993 }
1994 goto l235
1995 l236:
1996 position, tokenIndex = position235, tokenIndex235
1997 if !_rules[ruleLocalSymbol]() {
1998 goto l237
1999 }
2000 goto l235
2001 l237:
2002 position, tokenIndex = position235, tokenIndex235
2003 if !_rules[ruleSymbolName]() {
2004 goto l238
2005 }
2006 goto l235
2007 l238:
2008 position, tokenIndex = position235, tokenIndex235
2009 if !_rules[ruleDot]() {
2010 goto l234
2011 }
2012 }
2013 l235:
2014 {
2015 position239, tokenIndex239 := position, tokenIndex
2016 if !_rules[ruleWS]() {
2017 goto l239
2018 }
2019 goto l240
2020 l239:
2021 position, tokenIndex = position239, tokenIndex239
2022 }
2023 l240:
2024 if !_rules[ruleOperator]() {
2025 goto l234
2026 }
2027 {
2028 position241, tokenIndex241 := position, tokenIndex
2029 if !_rules[ruleWS]() {
2030 goto l241
2031 }
2032 goto l242
2033 l241:
2034 position, tokenIndex = position241, tokenIndex241
2035 }
2036 l242:
2037 {
2038 position243, tokenIndex243 := position, tokenIndex
2039 if !_rules[ruleOffset]() {
2040 goto l244
2041 }
2042 goto l243
2043 l244:
2044 position, tokenIndex = position243, tokenIndex243
2045 if !_rules[ruleLocalSymbol]() {
2046 goto l245
2047 }
2048 goto l243
2049 l245:
2050 position, tokenIndex = position243, tokenIndex243
2051 if !_rules[ruleSymbolName]() {
2052 goto l234
2053 }
2054 }
2055 l243:
2056 goto l231
2057 l234:
2058 position, tokenIndex = position231, tokenIndex231
2059 if !_rules[ruleLocalSymbol]() {
2060 goto l246
2061 }
2062 {
2063 position247, tokenIndex247 := position, tokenIndex
2064 if !_rules[ruleTCMarker]() {
2065 goto l247
2066 }
2067 goto l248
2068 l247:
2069 position, tokenIndex = position247, tokenIndex247
2070 }
2071 l248:
2072 goto l231
2073 l246:
2074 position, tokenIndex = position231, tokenIndex231
2075 if !_rules[ruleSymbolName]() {
2076 goto l249
2077 }
2078 if !_rules[ruleOffset]() {
2079 goto l249
2080 }
2081 goto l231
2082 l249:
2083 position, tokenIndex = position231, tokenIndex231
2084 if !_rules[ruleSymbolName]() {
2085 goto l229
2086 }
2087 {
2088 position250, tokenIndex250 := position, tokenIndex
2089 if !_rules[ruleTCMarker]() {
2090 goto l250
2091 }
2092 goto l251
2093 l250:
2094 position, tokenIndex = position250, tokenIndex250
2095 }
2096 l251:
2097 }
2098 l231:
2099 add(ruleSymbolArg, position230)
2100 }
2101 return true
2102 l229:
2103 position, tokenIndex = position229, tokenIndex229
2104 return false
2105 },
2106 /* 14 SymbolType <- <(('@' 'f' 'u' 'n' 'c' 't' 'i' 'o' 'n') / ('@' 'o' 'b' 'j' 'e' 'c' 't'))> */
2107 func() bool {
2108 position252, tokenIndex252 := position, tokenIndex
2109 {
2110 position253 := position
2111 {
2112 position254, tokenIndex254 := position, tokenIndex
2113 if buffer[position] != rune('@') {
2114 goto l255
2115 }
2116 position++
2117 if buffer[position] != rune('f') {
2118 goto l255
2119 }
2120 position++
2121 if buffer[position] != rune('u') {
2122 goto l255
2123 }
2124 position++
2125 if buffer[position] != rune('n') {
2126 goto l255
2127 }
2128 position++
2129 if buffer[position] != rune('c') {
2130 goto l255
2131 }
2132 position++
2133 if buffer[position] != rune('t') {
2134 goto l255
2135 }
2136 position++
2137 if buffer[position] != rune('i') {
2138 goto l255
2139 }
2140 position++
2141 if buffer[position] != rune('o') {
2142 goto l255
2143 }
2144 position++
2145 if buffer[position] != rune('n') {
2146 goto l255
2147 }
2148 position++
2149 goto l254
2150 l255:
2151 position, tokenIndex = position254, tokenIndex254
2152 if buffer[position] != rune('@') {
2153 goto l252
2154 }
2155 position++
2156 if buffer[position] != rune('o') {
2157 goto l252
2158 }
2159 position++
2160 if buffer[position] != rune('b') {
2161 goto l252
2162 }
2163 position++
2164 if buffer[position] != rune('j') {
2165 goto l252
2166 }
2167 position++
2168 if buffer[position] != rune('e') {
2169 goto l252
2170 }
2171 position++
2172 if buffer[position] != rune('c') {
2173 goto l252
2174 }
2175 position++
2176 if buffer[position] != rune('t') {
2177 goto l252
2178 }
2179 position++
2180 }
2181 l254:
2182 add(ruleSymbolType, position253)
2183 }
2184 return true
2185 l252:
2186 position, tokenIndex = position252, tokenIndex252
2187 return false
2188 },
2189 /* 15 Dot <- <'.'> */
2190 func() bool {
2191 position256, tokenIndex256 := position, tokenIndex
2192 {
2193 position257 := position
2194 if buffer[position] != rune('.') {
2195 goto l256
2196 }
2197 position++
2198 add(ruleDot, position257)
2199 }
2200 return true
2201 l256:
2202 position, tokenIndex = position256, tokenIndex256
2203 return false
2204 },
2205 /* 16 TCMarker <- <('[' 'T' 'C' ']')> */
2206 func() bool {
2207 position258, tokenIndex258 := position, tokenIndex
2208 {
2209 position259 := position
2210 if buffer[position] != rune('[') {
2211 goto l258
2212 }
2213 position++
2214 if buffer[position] != rune('T') {
2215 goto l258
2216 }
2217 position++
2218 if buffer[position] != rune('C') {
2219 goto l258
2220 }
2221 position++
2222 if buffer[position] != rune(']') {
2223 goto l258
2224 }
2225 position++
2226 add(ruleTCMarker, position259)
2227 }
2228 return true
2229 l258:
2230 position, tokenIndex = position258, tokenIndex258
2231 return false
2232 },
2233 /* 17 EscapedChar <- <('\\' .)> */
2234 func() bool {
2235 position260, tokenIndex260 := position, tokenIndex
2236 {
2237 position261 := position
2238 if buffer[position] != rune('\\') {
2239 goto l260
2240 }
2241 position++
2242 if !matchDot() {
2243 goto l260
2244 }
2245 add(ruleEscapedChar, position261)
2246 }
2247 return true
2248 l260:
2249 position, tokenIndex = position260, tokenIndex260
2250 return false
2251 },
2252 /* 18 WS <- <(' ' / '\t')+> */
2253 func() bool {
2254 position262, tokenIndex262 := position, tokenIndex
2255 {
2256 position263 := position
2257 {
2258 position266, tokenIndex266 := position, tokenIndex
2259 if buffer[position] != rune(' ') {
2260 goto l267
2261 }
2262 position++
2263 goto l266
2264 l267:
2265 position, tokenIndex = position266, tokenIndex266
2266 if buffer[position] != rune('\t') {
2267 goto l262
2268 }
2269 position++
2270 }
2271 l266:
2272 l264:
2273 {
2274 position265, tokenIndex265 := position, tokenIndex
2275 {
2276 position268, tokenIndex268 := position, tokenIndex
2277 if buffer[position] != rune(' ') {
2278 goto l269
2279 }
2280 position++
2281 goto l268
2282 l269:
2283 position, tokenIndex = position268, tokenIndex268
2284 if buffer[position] != rune('\t') {
2285 goto l265
2286 }
2287 position++
2288 }
2289 l268:
2290 goto l264
2291 l265:
2292 position, tokenIndex = position265, tokenIndex265
2293 }
2294 add(ruleWS, position263)
2295 }
2296 return true
2297 l262:
2298 position, tokenIndex = position262, tokenIndex262
2299 return false
2300 },
2301 /* 19 Comment <- <('#' (!'\n' .)*)> */
2302 func() bool {
2303 position270, tokenIndex270 := position, tokenIndex
2304 {
2305 position271 := position
2306 if buffer[position] != rune('#') {
2307 goto l270
2308 }
2309 position++
2310 l272:
2311 {
2312 position273, tokenIndex273 := position, tokenIndex
2313 {
2314 position274, tokenIndex274 := position, tokenIndex
2315 if buffer[position] != rune('\n') {
2316 goto l274
2317 }
2318 position++
2319 goto l273
2320 l274:
2321 position, tokenIndex = position274, tokenIndex274
2322 }
2323 if !matchDot() {
2324 goto l273
2325 }
2326 goto l272
2327 l273:
2328 position, tokenIndex = position273, tokenIndex273
2329 }
2330 add(ruleComment, position271)
2331 }
2332 return true
2333 l270:
2334 position, tokenIndex = position270, tokenIndex270
2335 return false
2336 },
2337 /* 20 Label <- <((LocalSymbol / LocalLabel / SymbolName) ':')> */
2338 func() bool {
2339 position275, tokenIndex275 := position, tokenIndex
2340 {
2341 position276 := position
2342 {
2343 position277, tokenIndex277 := position, tokenIndex
2344 if !_rules[ruleLocalSymbol]() {
2345 goto l278
2346 }
2347 goto l277
2348 l278:
2349 position, tokenIndex = position277, tokenIndex277
2350 if !_rules[ruleLocalLabel]() {
2351 goto l279
2352 }
2353 goto l277
2354 l279:
2355 position, tokenIndex = position277, tokenIndex277
2356 if !_rules[ruleSymbolName]() {
2357 goto l275
2358 }
2359 }
2360 l277:
2361 if buffer[position] != rune(':') {
2362 goto l275
2363 }
2364 position++
2365 add(ruleLabel, position276)
2366 }
2367 return true
2368 l275:
2369 position, tokenIndex = position275, tokenIndex275
2370 return false
2371 },
2372 /* 21 SymbolName <- <(([a-z] / [A-Z] / '.' / '_') ([a-z] / [A-Z] / '.' / ([0-9] / [0-9]) / '$' / '_')*)> */
2373 func() bool {
2374 position280, tokenIndex280 := position, tokenIndex
2375 {
2376 position281 := position
2377 {
2378 position282, tokenIndex282 := position, tokenIndex
2379 if c := buffer[position]; c < rune('a') || c > rune('z') {
2380 goto l283
2381 }
2382 position++
2383 goto l282
2384 l283:
2385 position, tokenIndex = position282, tokenIndex282
2386 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2387 goto l284
2388 }
2389 position++
2390 goto l282
2391 l284:
2392 position, tokenIndex = position282, tokenIndex282
2393 if buffer[position] != rune('.') {
2394 goto l285
2395 }
2396 position++
2397 goto l282
2398 l285:
2399 position, tokenIndex = position282, tokenIndex282
2400 if buffer[position] != rune('_') {
2401 goto l280
2402 }
2403 position++
2404 }
2405 l282:
2406 l286:
2407 {
2408 position287, tokenIndex287 := position, tokenIndex
2409 {
2410 position288, tokenIndex288 := position, tokenIndex
2411 if c := buffer[position]; c < rune('a') || c > rune('z') {
2412 goto l289
2413 }
2414 position++
2415 goto l288
2416 l289:
2417 position, tokenIndex = position288, tokenIndex288
2418 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2419 goto l290
2420 }
2421 position++
2422 goto l288
2423 l290:
2424 position, tokenIndex = position288, tokenIndex288
2425 if buffer[position] != rune('.') {
2426 goto l291
2427 }
2428 position++
2429 goto l288
2430 l291:
2431 position, tokenIndex = position288, tokenIndex288
2432 {
2433 position293, tokenIndex293 := position, tokenIndex
2434 if c := buffer[position]; c < rune('0') || c > rune('9') {
2435 goto l294
2436 }
2437 position++
2438 goto l293
2439 l294:
2440 position, tokenIndex = position293, tokenIndex293
2441 if c := buffer[position]; c < rune('0') || c > rune('9') {
2442 goto l292
2443 }
2444 position++
2445 }
2446 l293:
2447 goto l288
2448 l292:
2449 position, tokenIndex = position288, tokenIndex288
2450 if buffer[position] != rune('$') {
2451 goto l295
2452 }
2453 position++
2454 goto l288
2455 l295:
2456 position, tokenIndex = position288, tokenIndex288
2457 if buffer[position] != rune('_') {
2458 goto l287
2459 }
2460 position++
2461 }
2462 l288:
2463 goto l286
2464 l287:
2465 position, tokenIndex = position287, tokenIndex287
2466 }
2467 add(ruleSymbolName, position281)
2468 }
2469 return true
2470 l280:
2471 position, tokenIndex = position280, tokenIndex280
2472 return false
2473 },
2474 /* 22 LocalSymbol <- <('.' 'L' ([a-z] / [A-Z] / '.' / ([0-9] / [0-9]) / '$' / '_')+)> */
2475 func() bool {
2476 position296, tokenIndex296 := position, tokenIndex
2477 {
2478 position297 := position
2479 if buffer[position] != rune('.') {
2480 goto l296
2481 }
2482 position++
2483 if buffer[position] != rune('L') {
2484 goto l296
2485 }
2486 position++
2487 {
2488 position300, tokenIndex300 := position, tokenIndex
2489 if c := buffer[position]; c < rune('a') || c > rune('z') {
2490 goto l301
2491 }
2492 position++
2493 goto l300
2494 l301:
2495 position, tokenIndex = position300, tokenIndex300
2496 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2497 goto l302
2498 }
2499 position++
2500 goto l300
2501 l302:
2502 position, tokenIndex = position300, tokenIndex300
2503 if buffer[position] != rune('.') {
2504 goto l303
2505 }
2506 position++
2507 goto l300
2508 l303:
2509 position, tokenIndex = position300, tokenIndex300
2510 {
2511 position305, tokenIndex305 := position, tokenIndex
2512 if c := buffer[position]; c < rune('0') || c > rune('9') {
2513 goto l306
2514 }
2515 position++
2516 goto l305
2517 l306:
2518 position, tokenIndex = position305, tokenIndex305
2519 if c := buffer[position]; c < rune('0') || c > rune('9') {
2520 goto l304
2521 }
2522 position++
2523 }
2524 l305:
2525 goto l300
2526 l304:
2527 position, tokenIndex = position300, tokenIndex300
2528 if buffer[position] != rune('$') {
2529 goto l307
2530 }
2531 position++
2532 goto l300
2533 l307:
2534 position, tokenIndex = position300, tokenIndex300
2535 if buffer[position] != rune('_') {
2536 goto l296
2537 }
2538 position++
2539 }
2540 l300:
2541 l298:
2542 {
2543 position299, tokenIndex299 := position, tokenIndex
2544 {
2545 position308, tokenIndex308 := position, tokenIndex
2546 if c := buffer[position]; c < rune('a') || c > rune('z') {
2547 goto l309
2548 }
2549 position++
2550 goto l308
2551 l309:
2552 position, tokenIndex = position308, tokenIndex308
2553 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2554 goto l310
2555 }
2556 position++
2557 goto l308
2558 l310:
2559 position, tokenIndex = position308, tokenIndex308
2560 if buffer[position] != rune('.') {
2561 goto l311
2562 }
2563 position++
2564 goto l308
2565 l311:
2566 position, tokenIndex = position308, tokenIndex308
2567 {
2568 position313, tokenIndex313 := position, tokenIndex
2569 if c := buffer[position]; c < rune('0') || c > rune('9') {
2570 goto l314
2571 }
2572 position++
2573 goto l313
2574 l314:
2575 position, tokenIndex = position313, tokenIndex313
2576 if c := buffer[position]; c < rune('0') || c > rune('9') {
2577 goto l312
2578 }
2579 position++
2580 }
2581 l313:
2582 goto l308
2583 l312:
2584 position, tokenIndex = position308, tokenIndex308
2585 if buffer[position] != rune('$') {
2586 goto l315
2587 }
2588 position++
2589 goto l308
2590 l315:
2591 position, tokenIndex = position308, tokenIndex308
2592 if buffer[position] != rune('_') {
2593 goto l299
2594 }
2595 position++
2596 }
2597 l308:
2598 goto l298
2599 l299:
2600 position, tokenIndex = position299, tokenIndex299
2601 }
2602 add(ruleLocalSymbol, position297)
2603 }
2604 return true
2605 l296:
2606 position, tokenIndex = position296, tokenIndex296
2607 return false
2608 },
2609 /* 23 LocalLabel <- <([0-9] ([0-9] / '$')*)> */
2610 func() bool {
2611 position316, tokenIndex316 := position, tokenIndex
2612 {
2613 position317 := position
2614 if c := buffer[position]; c < rune('0') || c > rune('9') {
2615 goto l316
2616 }
2617 position++
2618 l318:
2619 {
2620 position319, tokenIndex319 := position, tokenIndex
2621 {
2622 position320, tokenIndex320 := position, tokenIndex
2623 if c := buffer[position]; c < rune('0') || c > rune('9') {
2624 goto l321
2625 }
2626 position++
2627 goto l320
2628 l321:
2629 position, tokenIndex = position320, tokenIndex320
2630 if buffer[position] != rune('$') {
2631 goto l319
2632 }
2633 position++
2634 }
2635 l320:
2636 goto l318
2637 l319:
2638 position, tokenIndex = position319, tokenIndex319
2639 }
2640 add(ruleLocalLabel, position317)
2641 }
2642 return true
2643 l316:
2644 position, tokenIndex = position316, tokenIndex316
2645 return false
2646 },
2647 /* 24 LocalLabelRef <- <([0-9] ([0-9] / '$')* ('b' / 'f'))> */
2648 func() bool {
2649 position322, tokenIndex322 := position, tokenIndex
2650 {
2651 position323 := position
2652 if c := buffer[position]; c < rune('0') || c > rune('9') {
2653 goto l322
2654 }
2655 position++
2656 l324:
2657 {
2658 position325, tokenIndex325 := position, tokenIndex
2659 {
2660 position326, tokenIndex326 := position, tokenIndex
2661 if c := buffer[position]; c < rune('0') || c > rune('9') {
2662 goto l327
2663 }
2664 position++
2665 goto l326
2666 l327:
2667 position, tokenIndex = position326, tokenIndex326
2668 if buffer[position] != rune('$') {
2669 goto l325
2670 }
2671 position++
2672 }
2673 l326:
2674 goto l324
2675 l325:
2676 position, tokenIndex = position325, tokenIndex325
2677 }
2678 {
2679 position328, tokenIndex328 := position, tokenIndex
2680 if buffer[position] != rune('b') {
2681 goto l329
2682 }
2683 position++
2684 goto l328
2685 l329:
2686 position, tokenIndex = position328, tokenIndex328
2687 if buffer[position] != rune('f') {
2688 goto l322
2689 }
2690 position++
2691 }
2692 l328:
2693 add(ruleLocalLabelRef, position323)
2694 }
2695 return true
2696 l322:
2697 position, tokenIndex = position322, tokenIndex322
2698 return false
2699 },
Robert Sloan978112c2018-01-22 12:53:01 -08002700 /* 25 Instruction <- <(InstructionName (WS InstructionArg (WS? ',' WS? InstructionArg)*)? (WS? '{' InstructionArg '}')*)> */
Robert Sloan8ff03552017-06-14 12:40:58 -07002701 func() bool {
2702 position330, tokenIndex330 := position, tokenIndex
2703 {
2704 position331 := position
2705 if !_rules[ruleInstructionName]() {
2706 goto l330
2707 }
2708 {
2709 position332, tokenIndex332 := position, tokenIndex
2710 if !_rules[ruleWS]() {
2711 goto l332
2712 }
2713 if !_rules[ruleInstructionArg]() {
2714 goto l332
2715 }
2716 l334:
2717 {
2718 position335, tokenIndex335 := position, tokenIndex
2719 {
2720 position336, tokenIndex336 := position, tokenIndex
2721 if !_rules[ruleWS]() {
2722 goto l336
2723 }
2724 goto l337
2725 l336:
2726 position, tokenIndex = position336, tokenIndex336
2727 }
2728 l337:
2729 if buffer[position] != rune(',') {
2730 goto l335
2731 }
2732 position++
2733 {
2734 position338, tokenIndex338 := position, tokenIndex
2735 if !_rules[ruleWS]() {
2736 goto l338
2737 }
2738 goto l339
2739 l338:
2740 position, tokenIndex = position338, tokenIndex338
2741 }
2742 l339:
2743 if !_rules[ruleInstructionArg]() {
2744 goto l335
2745 }
2746 goto l334
2747 l335:
2748 position, tokenIndex = position335, tokenIndex335
2749 }
2750 goto l333
2751 l332:
2752 position, tokenIndex = position332, tokenIndex332
2753 }
2754 l333:
Robert Sloan978112c2018-01-22 12:53:01 -08002755 l340:
2756 {
2757 position341, tokenIndex341 := position, tokenIndex
2758 {
2759 position342, tokenIndex342 := position, tokenIndex
2760 if !_rules[ruleWS]() {
2761 goto l342
2762 }
2763 goto l343
2764 l342:
2765 position, tokenIndex = position342, tokenIndex342
2766 }
2767 l343:
2768 if buffer[position] != rune('{') {
2769 goto l341
2770 }
2771 position++
2772 if !_rules[ruleInstructionArg]() {
2773 goto l341
2774 }
2775 if buffer[position] != rune('}') {
2776 goto l341
2777 }
2778 position++
2779 goto l340
2780 l341:
2781 position, tokenIndex = position341, tokenIndex341
2782 }
Robert Sloan8ff03552017-06-14 12:40:58 -07002783 add(ruleInstruction, position331)
2784 }
2785 return true
2786 l330:
2787 position, tokenIndex = position330, tokenIndex330
2788 return false
2789 },
2790 /* 26 InstructionName <- <(([a-z] / [A-Z]) ([a-z] / [A-Z] / ([0-9] / [0-9]))* ('.' / '+' / '-')?)> */
2791 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08002792 position344, tokenIndex344 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002793 {
Robert Sloan978112c2018-01-22 12:53:01 -08002794 position345 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07002795 {
Robert Sloan978112c2018-01-22 12:53:01 -08002796 position346, tokenIndex346 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002797 if c := buffer[position]; c < rune('a') || c > rune('z') {
Robert Sloan978112c2018-01-22 12:53:01 -08002798 goto l347
Robert Sloan8ff03552017-06-14 12:40:58 -07002799 }
2800 position++
Robert Sloan978112c2018-01-22 12:53:01 -08002801 goto l346
2802 l347:
2803 position, tokenIndex = position346, tokenIndex346
Robert Sloan8ff03552017-06-14 12:40:58 -07002804 if c := buffer[position]; c < rune('A') || c > rune('Z') {
Robert Sloan978112c2018-01-22 12:53:01 -08002805 goto l344
Robert Sloan8ff03552017-06-14 12:40:58 -07002806 }
2807 position++
2808 }
Robert Sloan978112c2018-01-22 12:53:01 -08002809 l346:
2810 l348:
Robert Sloan8ff03552017-06-14 12:40:58 -07002811 {
Robert Sloan978112c2018-01-22 12:53:01 -08002812 position349, tokenIndex349 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002813 {
Robert Sloan978112c2018-01-22 12:53:01 -08002814 position350, tokenIndex350 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002815 if c := buffer[position]; c < rune('a') || c > rune('z') {
Robert Sloan8ff03552017-06-14 12:40:58 -07002816 goto l351
2817 }
2818 position++
Robert Sloan978112c2018-01-22 12:53:01 -08002819 goto l350
2820 l351:
2821 position, tokenIndex = position350, tokenIndex350
2822 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2823 goto l352
2824 }
2825 position++
2826 goto l350
2827 l352:
2828 position, tokenIndex = position350, tokenIndex350
2829 {
2830 position353, tokenIndex353 := position, tokenIndex
2831 if c := buffer[position]; c < rune('0') || c > rune('9') {
2832 goto l354
2833 }
2834 position++
2835 goto l353
2836 l354:
2837 position, tokenIndex = position353, tokenIndex353
2838 if c := buffer[position]; c < rune('0') || c > rune('9') {
2839 goto l349
2840 }
2841 position++
2842 }
2843 l353:
Robert Sloan8ff03552017-06-14 12:40:58 -07002844 }
Robert Sloan978112c2018-01-22 12:53:01 -08002845 l350:
2846 goto l348
2847 l349:
2848 position, tokenIndex = position349, tokenIndex349
Robert Sloan8ff03552017-06-14 12:40:58 -07002849 }
Robert Sloan978112c2018-01-22 12:53:01 -08002850 {
2851 position355, tokenIndex355 := position, tokenIndex
2852 {
2853 position357, tokenIndex357 := position, tokenIndex
2854 if buffer[position] != rune('.') {
2855 goto l358
2856 }
2857 position++
2858 goto l357
2859 l358:
2860 position, tokenIndex = position357, tokenIndex357
2861 if buffer[position] != rune('+') {
2862 goto l359
2863 }
2864 position++
2865 goto l357
2866 l359:
2867 position, tokenIndex = position357, tokenIndex357
2868 if buffer[position] != rune('-') {
2869 goto l355
2870 }
2871 position++
2872 }
2873 l357:
2874 goto l356
2875 l355:
2876 position, tokenIndex = position355, tokenIndex355
2877 }
2878 l356:
2879 add(ruleInstructionName, position345)
Robert Sloan8ff03552017-06-14 12:40:58 -07002880 }
2881 return true
Robert Sloan978112c2018-01-22 12:53:01 -08002882 l344:
2883 position, tokenIndex = position344, tokenIndex344
Robert Sloan8ff03552017-06-14 12:40:58 -07002884 return false
2885 },
2886 /* 27 InstructionArg <- <(IndirectionIndicator? (RegisterOrConstant / LocalLabelRef / TOCRefHigh / TOCRefLow / MemoryRef))> */
2887 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08002888 position360, tokenIndex360 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002889 {
Robert Sloan978112c2018-01-22 12:53:01 -08002890 position361 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07002891 {
Robert Sloan978112c2018-01-22 12:53:01 -08002892 position362, tokenIndex362 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002893 if !_rules[ruleIndirectionIndicator]() {
Robert Sloan8ff03552017-06-14 12:40:58 -07002894 goto l362
2895 }
Robert Sloan978112c2018-01-22 12:53:01 -08002896 goto l363
Robert Sloan8ff03552017-06-14 12:40:58 -07002897 l362:
Robert Sloan978112c2018-01-22 12:53:01 -08002898 position, tokenIndex = position362, tokenIndex362
2899 }
2900 l363:
2901 {
2902 position364, tokenIndex364 := position, tokenIndex
2903 if !_rules[ruleRegisterOrConstant]() {
2904 goto l365
2905 }
2906 goto l364
2907 l365:
2908 position, tokenIndex = position364, tokenIndex364
2909 if !_rules[ruleLocalLabelRef]() {
2910 goto l366
2911 }
2912 goto l364
2913 l366:
2914 position, tokenIndex = position364, tokenIndex364
Robert Sloan8ff03552017-06-14 12:40:58 -07002915 if !_rules[ruleTOCRefHigh]() {
Robert Sloan978112c2018-01-22 12:53:01 -08002916 goto l367
Robert Sloan8ff03552017-06-14 12:40:58 -07002917 }
Robert Sloan978112c2018-01-22 12:53:01 -08002918 goto l364
2919 l367:
2920 position, tokenIndex = position364, tokenIndex364
Robert Sloan8ff03552017-06-14 12:40:58 -07002921 if !_rules[ruleTOCRefLow]() {
Robert Sloan978112c2018-01-22 12:53:01 -08002922 goto l368
Robert Sloan8ff03552017-06-14 12:40:58 -07002923 }
Robert Sloan978112c2018-01-22 12:53:01 -08002924 goto l364
2925 l368:
2926 position, tokenIndex = position364, tokenIndex364
Robert Sloan8ff03552017-06-14 12:40:58 -07002927 if !_rules[ruleMemoryRef]() {
Robert Sloan978112c2018-01-22 12:53:01 -08002928 goto l360
Robert Sloan8ff03552017-06-14 12:40:58 -07002929 }
2930 }
Robert Sloan978112c2018-01-22 12:53:01 -08002931 l364:
2932 add(ruleInstructionArg, position361)
Robert Sloan8ff03552017-06-14 12:40:58 -07002933 }
2934 return true
Robert Sloan978112c2018-01-22 12:53:01 -08002935 l360:
2936 position, tokenIndex = position360, tokenIndex360
Robert Sloan8ff03552017-06-14 12:40:58 -07002937 return false
2938 },
2939 /* 28 TOCRefHigh <- <('.' 'T' 'O' 'C' '.' '-' (('0' 'b') / ('.' 'L' ([a-z] / [A-Z] / '_' / [0-9])+)) ('@' ('h' / 'H') ('a' / 'A')))> */
2940 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08002941 position369, tokenIndex369 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002942 {
Robert Sloan978112c2018-01-22 12:53:01 -08002943 position370 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07002944 if buffer[position] != rune('.') {
Robert Sloan978112c2018-01-22 12:53:01 -08002945 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002946 }
2947 position++
2948 if buffer[position] != rune('T') {
Robert Sloan978112c2018-01-22 12:53:01 -08002949 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002950 }
2951 position++
2952 if buffer[position] != rune('O') {
Robert Sloan978112c2018-01-22 12:53:01 -08002953 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002954 }
2955 position++
2956 if buffer[position] != rune('C') {
Robert Sloan978112c2018-01-22 12:53:01 -08002957 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002958 }
2959 position++
2960 if buffer[position] != rune('.') {
Robert Sloan978112c2018-01-22 12:53:01 -08002961 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002962 }
2963 position++
2964 if buffer[position] != rune('-') {
Robert Sloan978112c2018-01-22 12:53:01 -08002965 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002966 }
2967 position++
2968 {
Robert Sloan978112c2018-01-22 12:53:01 -08002969 position371, tokenIndex371 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07002970 if buffer[position] != rune('0') {
Robert Sloan978112c2018-01-22 12:53:01 -08002971 goto l372
Robert Sloan8ff03552017-06-14 12:40:58 -07002972 }
2973 position++
2974 if buffer[position] != rune('b') {
Robert Sloan978112c2018-01-22 12:53:01 -08002975 goto l372
Robert Sloan8ff03552017-06-14 12:40:58 -07002976 }
2977 position++
Robert Sloan978112c2018-01-22 12:53:01 -08002978 goto l371
2979 l372:
2980 position, tokenIndex = position371, tokenIndex371
Robert Sloan8ff03552017-06-14 12:40:58 -07002981 if buffer[position] != rune('.') {
Robert Sloan978112c2018-01-22 12:53:01 -08002982 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07002983 }
2984 position++
2985 if buffer[position] != rune('L') {
Robert Sloan8ff03552017-06-14 12:40:58 -07002986 goto l369
Robert Sloan978112c2018-01-22 12:53:01 -08002987 }
2988 position++
2989 {
2990 position375, tokenIndex375 := position, tokenIndex
2991 if c := buffer[position]; c < rune('a') || c > rune('z') {
2992 goto l376
2993 }
2994 position++
2995 goto l375
2996 l376:
2997 position, tokenIndex = position375, tokenIndex375
2998 if c := buffer[position]; c < rune('A') || c > rune('Z') {
2999 goto l377
3000 }
3001 position++
3002 goto l375
3003 l377:
3004 position, tokenIndex = position375, tokenIndex375
3005 if buffer[position] != rune('_') {
3006 goto l378
3007 }
3008 position++
3009 goto l375
3010 l378:
3011 position, tokenIndex = position375, tokenIndex375
3012 if c := buffer[position]; c < rune('0') || c > rune('9') {
3013 goto l369
3014 }
3015 position++
3016 }
3017 l375:
3018 l373:
3019 {
3020 position374, tokenIndex374 := position, tokenIndex
3021 {
3022 position379, tokenIndex379 := position, tokenIndex
3023 if c := buffer[position]; c < rune('a') || c > rune('z') {
3024 goto l380
3025 }
3026 position++
3027 goto l379
3028 l380:
3029 position, tokenIndex = position379, tokenIndex379
3030 if c := buffer[position]; c < rune('A') || c > rune('Z') {
3031 goto l381
3032 }
3033 position++
3034 goto l379
3035 l381:
3036 position, tokenIndex = position379, tokenIndex379
3037 if buffer[position] != rune('_') {
3038 goto l382
3039 }
3040 position++
3041 goto l379
3042 l382:
3043 position, tokenIndex = position379, tokenIndex379
3044 if c := buffer[position]; c < rune('0') || c > rune('9') {
3045 goto l374
3046 }
3047 position++
3048 }
3049 l379:
3050 goto l373
3051 l374:
3052 position, tokenIndex = position374, tokenIndex374
Robert Sloan8ff03552017-06-14 12:40:58 -07003053 }
3054 }
Robert Sloan978112c2018-01-22 12:53:01 -08003055 l371:
Robert Sloan8ff03552017-06-14 12:40:58 -07003056 if buffer[position] != rune('@') {
Robert Sloan978112c2018-01-22 12:53:01 -08003057 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07003058 }
3059 position++
3060 {
Robert Sloan978112c2018-01-22 12:53:01 -08003061 position383, tokenIndex383 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003062 if buffer[position] != rune('h') {
Robert Sloan978112c2018-01-22 12:53:01 -08003063 goto l384
Robert Sloan8ff03552017-06-14 12:40:58 -07003064 }
3065 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003066 goto l383
3067 l384:
3068 position, tokenIndex = position383, tokenIndex383
Robert Sloan8ff03552017-06-14 12:40:58 -07003069 if buffer[position] != rune('H') {
Robert Sloan978112c2018-01-22 12:53:01 -08003070 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07003071 }
3072 position++
3073 }
Robert Sloan978112c2018-01-22 12:53:01 -08003074 l383:
Robert Sloan8ff03552017-06-14 12:40:58 -07003075 {
3076 position385, tokenIndex385 := position, tokenIndex
Robert Sloan978112c2018-01-22 12:53:01 -08003077 if buffer[position] != rune('a') {
Robert Sloan8ff03552017-06-14 12:40:58 -07003078 goto l386
3079 }
3080 position++
3081 goto l385
3082 l386:
3083 position, tokenIndex = position385, tokenIndex385
Robert Sloan978112c2018-01-22 12:53:01 -08003084 if buffer[position] != rune('A') {
3085 goto l369
Robert Sloan8ff03552017-06-14 12:40:58 -07003086 }
3087 position++
Robert Sloan8ff03552017-06-14 12:40:58 -07003088 }
3089 l385:
Robert Sloan978112c2018-01-22 12:53:01 -08003090 add(ruleTOCRefHigh, position370)
3091 }
3092 return true
3093 l369:
3094 position, tokenIndex = position369, tokenIndex369
3095 return false
3096 },
3097 /* 29 TOCRefLow <- <('.' 'T' 'O' 'C' '.' '-' (('0' 'b') / ('.' 'L' ([a-z] / [A-Z] / '_' / [0-9])+)) ('@' ('l' / 'L')))> */
3098 func() bool {
3099 position387, tokenIndex387 := position, tokenIndex
3100 {
3101 position388 := position
3102 if buffer[position] != rune('.') {
3103 goto l387
3104 }
3105 position++
3106 if buffer[position] != rune('T') {
3107 goto l387
3108 }
3109 position++
3110 if buffer[position] != rune('O') {
3111 goto l387
3112 }
3113 position++
3114 if buffer[position] != rune('C') {
3115 goto l387
3116 }
3117 position++
3118 if buffer[position] != rune('.') {
3119 goto l387
3120 }
3121 position++
3122 if buffer[position] != rune('-') {
3123 goto l387
Robert Sloan8ff03552017-06-14 12:40:58 -07003124 }
3125 position++
3126 {
Robert Sloan978112c2018-01-22 12:53:01 -08003127 position389, tokenIndex389 := position, tokenIndex
3128 if buffer[position] != rune('0') {
3129 goto l390
Robert Sloan8ff03552017-06-14 12:40:58 -07003130 }
3131 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003132 if buffer[position] != rune('b') {
3133 goto l390
3134 }
3135 position++
3136 goto l389
3137 l390:
3138 position, tokenIndex = position389, tokenIndex389
3139 if buffer[position] != rune('.') {
3140 goto l387
3141 }
3142 position++
Robert Sloan8ff03552017-06-14 12:40:58 -07003143 if buffer[position] != rune('L') {
Robert Sloan978112c2018-01-22 12:53:01 -08003144 goto l387
3145 }
3146 position++
3147 {
3148 position393, tokenIndex393 := position, tokenIndex
3149 if c := buffer[position]; c < rune('a') || c > rune('z') {
3150 goto l394
3151 }
3152 position++
3153 goto l393
3154 l394:
3155 position, tokenIndex = position393, tokenIndex393
3156 if c := buffer[position]; c < rune('A') || c > rune('Z') {
3157 goto l395
3158 }
3159 position++
3160 goto l393
3161 l395:
3162 position, tokenIndex = position393, tokenIndex393
3163 if buffer[position] != rune('_') {
3164 goto l396
3165 }
3166 position++
3167 goto l393
3168 l396:
3169 position, tokenIndex = position393, tokenIndex393
3170 if c := buffer[position]; c < rune('0') || c > rune('9') {
3171 goto l387
3172 }
3173 position++
3174 }
3175 l393:
3176 l391:
3177 {
3178 position392, tokenIndex392 := position, tokenIndex
3179 {
3180 position397, tokenIndex397 := position, tokenIndex
3181 if c := buffer[position]; c < rune('a') || c > rune('z') {
3182 goto l398
3183 }
3184 position++
3185 goto l397
3186 l398:
3187 position, tokenIndex = position397, tokenIndex397
3188 if c := buffer[position]; c < rune('A') || c > rune('Z') {
3189 goto l399
3190 }
3191 position++
3192 goto l397
3193 l399:
3194 position, tokenIndex = position397, tokenIndex397
3195 if buffer[position] != rune('_') {
3196 goto l400
3197 }
3198 position++
3199 goto l397
3200 l400:
3201 position, tokenIndex = position397, tokenIndex397
3202 if c := buffer[position]; c < rune('0') || c > rune('9') {
3203 goto l392
3204 }
3205 position++
3206 }
3207 l397:
3208 goto l391
3209 l392:
3210 position, tokenIndex = position392, tokenIndex392
3211 }
3212 }
3213 l389:
3214 if buffer[position] != rune('@') {
3215 goto l387
3216 }
3217 position++
3218 {
3219 position401, tokenIndex401 := position, tokenIndex
3220 if buffer[position] != rune('l') {
3221 goto l402
3222 }
3223 position++
3224 goto l401
3225 l402:
3226 position, tokenIndex = position401, tokenIndex401
3227 if buffer[position] != rune('L') {
3228 goto l387
Robert Sloan8ff03552017-06-14 12:40:58 -07003229 }
3230 position++
3231 }
Robert Sloan978112c2018-01-22 12:53:01 -08003232 l401:
3233 add(ruleTOCRefLow, position388)
Robert Sloan8ff03552017-06-14 12:40:58 -07003234 }
3235 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003236 l387:
3237 position, tokenIndex = position387, tokenIndex387
Robert Sloan8ff03552017-06-14 12:40:58 -07003238 return false
3239 },
3240 /* 30 IndirectionIndicator <- <'*'> */
3241 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003242 position403, tokenIndex403 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003243 {
Robert Sloan978112c2018-01-22 12:53:01 -08003244 position404 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003245 if buffer[position] != rune('*') {
Robert Sloan978112c2018-01-22 12:53:01 -08003246 goto l403
Robert Sloan8ff03552017-06-14 12:40:58 -07003247 }
3248 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003249 add(ruleIndirectionIndicator, position404)
Robert Sloan8ff03552017-06-14 12:40:58 -07003250 }
3251 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003252 l403:
3253 position, tokenIndex = position403, tokenIndex403
Robert Sloan8ff03552017-06-14 12:40:58 -07003254 return false
3255 },
3256 /* 31 RegisterOrConstant <- <((('%' ([a-z] / [A-Z]) ([a-z] / [A-Z] / ([0-9] / [0-9]))*) / ('$'? ((Offset Offset) / Offset))) !('f' / 'b' / ':' / '(' / '+' / '-'))> */
3257 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003258 position405, tokenIndex405 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003259 {
Robert Sloan978112c2018-01-22 12:53:01 -08003260 position406 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003261 {
Robert Sloan978112c2018-01-22 12:53:01 -08003262 position407, tokenIndex407 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003263 if buffer[position] != rune('%') {
Robert Sloan978112c2018-01-22 12:53:01 -08003264 goto l408
Robert Sloan8ff03552017-06-14 12:40:58 -07003265 }
3266 position++
3267 {
Robert Sloan978112c2018-01-22 12:53:01 -08003268 position409, tokenIndex409 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003269 if c := buffer[position]; c < rune('a') || c > rune('z') {
Robert Sloan978112c2018-01-22 12:53:01 -08003270 goto l410
Robert Sloan8ff03552017-06-14 12:40:58 -07003271 }
3272 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003273 goto l409
3274 l410:
3275 position, tokenIndex = position409, tokenIndex409
Robert Sloan8ff03552017-06-14 12:40:58 -07003276 if c := buffer[position]; c < rune('A') || c > rune('Z') {
Robert Sloan978112c2018-01-22 12:53:01 -08003277 goto l408
Robert Sloan8ff03552017-06-14 12:40:58 -07003278 }
3279 position++
3280 }
Robert Sloan978112c2018-01-22 12:53:01 -08003281 l409:
3282 l411:
Robert Sloan8ff03552017-06-14 12:40:58 -07003283 {
Robert Sloan978112c2018-01-22 12:53:01 -08003284 position412, tokenIndex412 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003285 {
Robert Sloan978112c2018-01-22 12:53:01 -08003286 position413, tokenIndex413 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003287 if c := buffer[position]; c < rune('a') || c > rune('z') {
Robert Sloan978112c2018-01-22 12:53:01 -08003288 goto l414
Robert Sloan8ff03552017-06-14 12:40:58 -07003289 }
3290 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003291 goto l413
3292 l414:
3293 position, tokenIndex = position413, tokenIndex413
Robert Sloan8ff03552017-06-14 12:40:58 -07003294 if c := buffer[position]; c < rune('A') || c > rune('Z') {
Robert Sloan978112c2018-01-22 12:53:01 -08003295 goto l415
Robert Sloan8ff03552017-06-14 12:40:58 -07003296 }
3297 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003298 goto l413
3299 l415:
3300 position, tokenIndex = position413, tokenIndex413
Robert Sloan8ff03552017-06-14 12:40:58 -07003301 {
Robert Sloan978112c2018-01-22 12:53:01 -08003302 position416, tokenIndex416 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003303 if c := buffer[position]; c < rune('0') || c > rune('9') {
Robert Sloan978112c2018-01-22 12:53:01 -08003304 goto l417
Robert Sloan8ff03552017-06-14 12:40:58 -07003305 }
3306 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003307 goto l416
3308 l417:
3309 position, tokenIndex = position416, tokenIndex416
Robert Sloan8ff03552017-06-14 12:40:58 -07003310 if c := buffer[position]; c < rune('0') || c > rune('9') {
Robert Sloan978112c2018-01-22 12:53:01 -08003311 goto l412
Robert Sloan8ff03552017-06-14 12:40:58 -07003312 }
3313 position++
3314 }
Robert Sloan978112c2018-01-22 12:53:01 -08003315 l416:
Robert Sloan8ff03552017-06-14 12:40:58 -07003316 }
Robert Sloan978112c2018-01-22 12:53:01 -08003317 l413:
3318 goto l411
3319 l412:
3320 position, tokenIndex = position412, tokenIndex412
Robert Sloan8ff03552017-06-14 12:40:58 -07003321 }
Robert Sloan978112c2018-01-22 12:53:01 -08003322 goto l407
3323 l408:
3324 position, tokenIndex = position407, tokenIndex407
Robert Sloan8ff03552017-06-14 12:40:58 -07003325 {
Robert Sloan978112c2018-01-22 12:53:01 -08003326 position418, tokenIndex418 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003327 if buffer[position] != rune('$') {
Robert Sloan8ff03552017-06-14 12:40:58 -07003328 goto l418
3329 }
3330 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003331 goto l419
3332 l418:
3333 position, tokenIndex = position418, tokenIndex418
Robert Sloan8ff03552017-06-14 12:40:58 -07003334 }
3335 l419:
Robert Sloan978112c2018-01-22 12:53:01 -08003336 {
3337 position420, tokenIndex420 := position, tokenIndex
3338 if !_rules[ruleOffset]() {
3339 goto l421
3340 }
3341 if !_rules[ruleOffset]() {
3342 goto l421
3343 }
3344 goto l420
3345 l421:
3346 position, tokenIndex = position420, tokenIndex420
3347 if !_rules[ruleOffset]() {
3348 goto l405
3349 }
3350 }
3351 l420:
Robert Sloan8ff03552017-06-14 12:40:58 -07003352 }
Robert Sloan978112c2018-01-22 12:53:01 -08003353 l407:
3354 {
3355 position422, tokenIndex422 := position, tokenIndex
3356 {
3357 position423, tokenIndex423 := position, tokenIndex
3358 if buffer[position] != rune('f') {
3359 goto l424
3360 }
3361 position++
3362 goto l423
3363 l424:
3364 position, tokenIndex = position423, tokenIndex423
3365 if buffer[position] != rune('b') {
3366 goto l425
3367 }
3368 position++
3369 goto l423
3370 l425:
3371 position, tokenIndex = position423, tokenIndex423
3372 if buffer[position] != rune(':') {
3373 goto l426
3374 }
3375 position++
3376 goto l423
3377 l426:
3378 position, tokenIndex = position423, tokenIndex423
3379 if buffer[position] != rune('(') {
3380 goto l427
3381 }
3382 position++
3383 goto l423
3384 l427:
3385 position, tokenIndex = position423, tokenIndex423
3386 if buffer[position] != rune('+') {
3387 goto l428
3388 }
3389 position++
3390 goto l423
3391 l428:
3392 position, tokenIndex = position423, tokenIndex423
3393 if buffer[position] != rune('-') {
3394 goto l422
3395 }
3396 position++
3397 }
3398 l423:
3399 goto l405
3400 l422:
3401 position, tokenIndex = position422, tokenIndex422
3402 }
3403 add(ruleRegisterOrConstant, position406)
Robert Sloan8ff03552017-06-14 12:40:58 -07003404 }
3405 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003406 l405:
3407 position, tokenIndex = position405, tokenIndex405
Robert Sloan8ff03552017-06-14 12:40:58 -07003408 return false
3409 },
3410 /* 32 MemoryRef <- <((SymbolRef BaseIndexScale) / SymbolRef / (Offset* BaseIndexScale) / (SegmentRegister Offset BaseIndexScale) / (SegmentRegister BaseIndexScale) / (SegmentRegister Offset) / BaseIndexScale)> */
3411 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003412 position429, tokenIndex429 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003413 {
Robert Sloan978112c2018-01-22 12:53:01 -08003414 position430 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003415 {
Robert Sloan978112c2018-01-22 12:53:01 -08003416 position431, tokenIndex431 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003417 if !_rules[ruleSymbolRef]() {
Robert Sloan978112c2018-01-22 12:53:01 -08003418 goto l432
Robert Sloan8ff03552017-06-14 12:40:58 -07003419 }
3420 if !_rules[ruleBaseIndexScale]() {
Robert Sloan978112c2018-01-22 12:53:01 -08003421 goto l432
Robert Sloan8ff03552017-06-14 12:40:58 -07003422 }
Robert Sloan978112c2018-01-22 12:53:01 -08003423 goto l431
3424 l432:
3425 position, tokenIndex = position431, tokenIndex431
Robert Sloan8ff03552017-06-14 12:40:58 -07003426 if !_rules[ruleSymbolRef]() {
Robert Sloan978112c2018-01-22 12:53:01 -08003427 goto l433
3428 }
3429 goto l431
3430 l433:
3431 position, tokenIndex = position431, tokenIndex431
3432 l435:
3433 {
3434 position436, tokenIndex436 := position, tokenIndex
3435 if !_rules[ruleOffset]() {
3436 goto l436
3437 }
3438 goto l435
3439 l436:
3440 position, tokenIndex = position436, tokenIndex436
3441 }
3442 if !_rules[ruleBaseIndexScale]() {
3443 goto l434
3444 }
3445 goto l431
3446 l434:
3447 position, tokenIndex = position431, tokenIndex431
3448 if !_rules[ruleSegmentRegister]() {
3449 goto l437
3450 }
3451 if !_rules[ruleOffset]() {
3452 goto l437
3453 }
3454 if !_rules[ruleBaseIndexScale]() {
3455 goto l437
3456 }
3457 goto l431
3458 l437:
3459 position, tokenIndex = position431, tokenIndex431
3460 if !_rules[ruleSegmentRegister]() {
3461 goto l438
3462 }
3463 if !_rules[ruleBaseIndexScale]() {
3464 goto l438
3465 }
3466 goto l431
3467 l438:
3468 position, tokenIndex = position431, tokenIndex431
3469 if !_rules[ruleSegmentRegister]() {
3470 goto l439
3471 }
3472 if !_rules[ruleOffset]() {
3473 goto l439
3474 }
3475 goto l431
3476 l439:
3477 position, tokenIndex = position431, tokenIndex431
3478 if !_rules[ruleBaseIndexScale]() {
Robert Sloan8ff03552017-06-14 12:40:58 -07003479 goto l429
3480 }
Robert Sloan8ff03552017-06-14 12:40:58 -07003481 }
Robert Sloan978112c2018-01-22 12:53:01 -08003482 l431:
3483 add(ruleMemoryRef, position430)
Robert Sloan8ff03552017-06-14 12:40:58 -07003484 }
3485 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003486 l429:
3487 position, tokenIndex = position429, tokenIndex429
Robert Sloan8ff03552017-06-14 12:40:58 -07003488 return false
3489 },
3490 /* 33 SymbolRef <- <((Offset* '+')? (LocalSymbol / SymbolName) Offset* ('@' Section Offset*)?)> */
3491 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003492 position440, tokenIndex440 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003493 {
Robert Sloan978112c2018-01-22 12:53:01 -08003494 position441 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003495 {
3496 position442, tokenIndex442 := position, tokenIndex
Robert Sloan978112c2018-01-22 12:53:01 -08003497 l444:
3498 {
3499 position445, tokenIndex445 := position, tokenIndex
3500 if !_rules[ruleOffset]() {
3501 goto l445
3502 }
3503 goto l444
3504 l445:
3505 position, tokenIndex = position445, tokenIndex445
Robert Sloan8ff03552017-06-14 12:40:58 -07003506 }
Robert Sloan978112c2018-01-22 12:53:01 -08003507 if buffer[position] != rune('+') {
3508 goto l442
3509 }
3510 position++
3511 goto l443
3512 l442:
Robert Sloan8ff03552017-06-14 12:40:58 -07003513 position, tokenIndex = position442, tokenIndex442
Robert Sloan8ff03552017-06-14 12:40:58 -07003514 }
Robert Sloan978112c2018-01-22 12:53:01 -08003515 l443:
Robert Sloan8ff03552017-06-14 12:40:58 -07003516 {
3517 position446, tokenIndex446 := position, tokenIndex
Robert Sloan978112c2018-01-22 12:53:01 -08003518 if !_rules[ruleLocalSymbol]() {
3519 goto l447
3520 }
3521 goto l446
3522 l447:
3523 position, tokenIndex = position446, tokenIndex446
3524 if !_rules[ruleSymbolName]() {
3525 goto l440
3526 }
3527 }
3528 l446:
3529 l448:
3530 {
3531 position449, tokenIndex449 := position, tokenIndex
3532 if !_rules[ruleOffset]() {
3533 goto l449
3534 }
3535 goto l448
3536 l449:
3537 position, tokenIndex = position449, tokenIndex449
3538 }
3539 {
3540 position450, tokenIndex450 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003541 if buffer[position] != rune('@') {
Robert Sloan978112c2018-01-22 12:53:01 -08003542 goto l450
Robert Sloan8ff03552017-06-14 12:40:58 -07003543 }
3544 position++
3545 if !_rules[ruleSection]() {
Robert Sloan978112c2018-01-22 12:53:01 -08003546 goto l450
Robert Sloan8ff03552017-06-14 12:40:58 -07003547 }
Robert Sloan978112c2018-01-22 12:53:01 -08003548 l452:
Robert Sloan8ff03552017-06-14 12:40:58 -07003549 {
Robert Sloan978112c2018-01-22 12:53:01 -08003550 position453, tokenIndex453 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003551 if !_rules[ruleOffset]() {
Robert Sloan978112c2018-01-22 12:53:01 -08003552 goto l453
Robert Sloan8ff03552017-06-14 12:40:58 -07003553 }
Robert Sloan978112c2018-01-22 12:53:01 -08003554 goto l452
3555 l453:
3556 position, tokenIndex = position453, tokenIndex453
Robert Sloan8ff03552017-06-14 12:40:58 -07003557 }
Robert Sloan978112c2018-01-22 12:53:01 -08003558 goto l451
3559 l450:
3560 position, tokenIndex = position450, tokenIndex450
Robert Sloan8ff03552017-06-14 12:40:58 -07003561 }
Robert Sloan978112c2018-01-22 12:53:01 -08003562 l451:
3563 add(ruleSymbolRef, position441)
Robert Sloan8ff03552017-06-14 12:40:58 -07003564 }
3565 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003566 l440:
3567 position, tokenIndex = position440, tokenIndex440
Robert Sloan8ff03552017-06-14 12:40:58 -07003568 return false
3569 },
3570 /* 34 BaseIndexScale <- <('(' RegisterOrConstant? WS? (',' WS? RegisterOrConstant WS? (',' [0-9]+)?)? ')')> */
3571 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003572 position454, tokenIndex454 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003573 {
Robert Sloan978112c2018-01-22 12:53:01 -08003574 position455 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003575 if buffer[position] != rune('(') {
Robert Sloan978112c2018-01-22 12:53:01 -08003576 goto l454
Robert Sloan8ff03552017-06-14 12:40:58 -07003577 }
3578 position++
3579 {
Robert Sloan8ff03552017-06-14 12:40:58 -07003580 position456, tokenIndex456 := position, tokenIndex
Robert Sloan978112c2018-01-22 12:53:01 -08003581 if !_rules[ruleRegisterOrConstant]() {
Robert Sloan8ff03552017-06-14 12:40:58 -07003582 goto l456
3583 }
Robert Sloan978112c2018-01-22 12:53:01 -08003584 goto l457
3585 l456:
3586 position, tokenIndex = position456, tokenIndex456
3587 }
3588 l457:
3589 {
3590 position458, tokenIndex458 := position, tokenIndex
3591 if !_rules[ruleWS]() {
3592 goto l458
3593 }
3594 goto l459
3595 l458:
3596 position, tokenIndex = position458, tokenIndex458
3597 }
3598 l459:
3599 {
3600 position460, tokenIndex460 := position, tokenIndex
3601 if buffer[position] != rune(',') {
3602 goto l460
3603 }
Robert Sloan8ff03552017-06-14 12:40:58 -07003604 position++
3605 {
Robert Sloan8ff03552017-06-14 12:40:58 -07003606 position462, tokenIndex462 := position, tokenIndex
Robert Sloan978112c2018-01-22 12:53:01 -08003607 if !_rules[ruleWS]() {
Robert Sloan8ff03552017-06-14 12:40:58 -07003608 goto l462
3609 }
Robert Sloan8ff03552017-06-14 12:40:58 -07003610 goto l463
3611 l462:
3612 position, tokenIndex = position462, tokenIndex462
3613 }
3614 l463:
Robert Sloan978112c2018-01-22 12:53:01 -08003615 if !_rules[ruleRegisterOrConstant]() {
3616 goto l460
3617 }
3618 {
3619 position464, tokenIndex464 := position, tokenIndex
3620 if !_rules[ruleWS]() {
3621 goto l464
3622 }
3623 goto l465
3624 l464:
3625 position, tokenIndex = position464, tokenIndex464
3626 }
3627 l465:
3628 {
3629 position466, tokenIndex466 := position, tokenIndex
3630 if buffer[position] != rune(',') {
3631 goto l466
3632 }
3633 position++
3634 if c := buffer[position]; c < rune('0') || c > rune('9') {
3635 goto l466
3636 }
3637 position++
3638 l468:
3639 {
3640 position469, tokenIndex469 := position, tokenIndex
3641 if c := buffer[position]; c < rune('0') || c > rune('9') {
3642 goto l469
3643 }
3644 position++
3645 goto l468
3646 l469:
3647 position, tokenIndex = position469, tokenIndex469
3648 }
3649 goto l467
3650 l466:
3651 position, tokenIndex = position466, tokenIndex466
3652 }
3653 l467:
3654 goto l461
3655 l460:
3656 position, tokenIndex = position460, tokenIndex460
Robert Sloan8ff03552017-06-14 12:40:58 -07003657 }
Robert Sloan978112c2018-01-22 12:53:01 -08003658 l461:
Robert Sloan8ff03552017-06-14 12:40:58 -07003659 if buffer[position] != rune(')') {
Robert Sloan978112c2018-01-22 12:53:01 -08003660 goto l454
Robert Sloan8ff03552017-06-14 12:40:58 -07003661 }
3662 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003663 add(ruleBaseIndexScale, position455)
Robert Sloan8ff03552017-06-14 12:40:58 -07003664 }
3665 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003666 l454:
3667 position, tokenIndex = position454, tokenIndex454
Robert Sloan8ff03552017-06-14 12:40:58 -07003668 return false
3669 },
3670 /* 35 Operator <- <('+' / '-')> */
3671 func() bool {
Robert Sloan8ff03552017-06-14 12:40:58 -07003672 position470, tokenIndex470 := position, tokenIndex
3673 {
3674 position471 := position
3675 {
3676 position472, tokenIndex472 := position, tokenIndex
3677 if buffer[position] != rune('+') {
Robert Sloan978112c2018-01-22 12:53:01 -08003678 goto l473
Robert Sloan8ff03552017-06-14 12:40:58 -07003679 }
3680 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003681 goto l472
3682 l473:
Robert Sloan8ff03552017-06-14 12:40:58 -07003683 position, tokenIndex = position472, tokenIndex472
Robert Sloan8ff03552017-06-14 12:40:58 -07003684 if buffer[position] != rune('-') {
Robert Sloan8ff03552017-06-14 12:40:58 -07003685 goto l470
3686 }
3687 position++
Robert Sloan8ff03552017-06-14 12:40:58 -07003688 }
Robert Sloan978112c2018-01-22 12:53:01 -08003689 l472:
3690 add(ruleOperator, position471)
Robert Sloan8ff03552017-06-14 12:40:58 -07003691 }
3692 return true
3693 l470:
3694 position, tokenIndex = position470, tokenIndex470
3695 return false
3696 },
Robert Sloan978112c2018-01-22 12:53:01 -08003697 /* 36 Offset <- <('+'? '-'? (('0' ('b' / 'B') ('0' / '1')+) / ('0' ('x' / 'X') ([0-9] / [0-9] / ([a-f] / [A-F]))+) / [0-9]+))> */
Robert Sloan8ff03552017-06-14 12:40:58 -07003698 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003699 position474, tokenIndex474 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003700 {
Robert Sloan978112c2018-01-22 12:53:01 -08003701 position475 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003702 {
Robert Sloan978112c2018-01-22 12:53:01 -08003703 position476, tokenIndex476 := position, tokenIndex
3704 if buffer[position] != rune('+') {
3705 goto l476
Robert Sloan8ff03552017-06-14 12:40:58 -07003706 }
3707 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003708 goto l477
3709 l476:
3710 position, tokenIndex = position476, tokenIndex476
Robert Sloan8ff03552017-06-14 12:40:58 -07003711 }
Robert Sloan978112c2018-01-22 12:53:01 -08003712 l477:
Robert Sloan8ff03552017-06-14 12:40:58 -07003713 {
Robert Sloan978112c2018-01-22 12:53:01 -08003714 position478, tokenIndex478 := position, tokenIndex
3715 if buffer[position] != rune('-') {
3716 goto l478
3717 }
3718 position++
3719 goto l479
3720 l478:
3721 position, tokenIndex = position478, tokenIndex478
3722 }
3723 l479:
3724 {
3725 position480, tokenIndex480 := position, tokenIndex
3726 if buffer[position] != rune('0') {
3727 goto l481
3728 }
3729 position++
Robert Sloan8ff03552017-06-14 12:40:58 -07003730 {
Robert Sloan978112c2018-01-22 12:53:01 -08003731 position482, tokenIndex482 := position, tokenIndex
3732 if buffer[position] != rune('b') {
3733 goto l483
Robert Sloan8ff03552017-06-14 12:40:58 -07003734 }
3735 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003736 goto l482
3737 l483:
3738 position, tokenIndex = position482, tokenIndex482
3739 if buffer[position] != rune('B') {
3740 goto l481
Robert Sloan8ff03552017-06-14 12:40:58 -07003741 }
3742 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003743 }
3744 l482:
3745 {
3746 position486, tokenIndex486 := position, tokenIndex
3747 if buffer[position] != rune('0') {
3748 goto l487
3749 }
3750 position++
3751 goto l486
3752 l487:
3753 position, tokenIndex = position486, tokenIndex486
3754 if buffer[position] != rune('1') {
3755 goto l481
3756 }
3757 position++
3758 }
3759 l486:
3760 l484:
3761 {
3762 position485, tokenIndex485 := position, tokenIndex
3763 {
3764 position488, tokenIndex488 := position, tokenIndex
3765 if buffer[position] != rune('0') {
3766 goto l489
3767 }
3768 position++
3769 goto l488
3770 l489:
3771 position, tokenIndex = position488, tokenIndex488
3772 if buffer[position] != rune('1') {
3773 goto l485
3774 }
3775 position++
3776 }
3777 l488:
3778 goto l484
3779 l485:
3780 position, tokenIndex = position485, tokenIndex485
3781 }
3782 goto l480
3783 l481:
3784 position, tokenIndex = position480, tokenIndex480
3785 if buffer[position] != rune('0') {
3786 goto l490
3787 }
3788 position++
3789 {
3790 position491, tokenIndex491 := position, tokenIndex
3791 if buffer[position] != rune('x') {
3792 goto l492
3793 }
3794 position++
3795 goto l491
3796 l492:
3797 position, tokenIndex = position491, tokenIndex491
3798 if buffer[position] != rune('X') {
3799 goto l490
3800 }
3801 position++
3802 }
3803 l491:
3804 {
3805 position495, tokenIndex495 := position, tokenIndex
3806 if c := buffer[position]; c < rune('0') || c > rune('9') {
3807 goto l496
3808 }
3809 position++
3810 goto l495
3811 l496:
3812 position, tokenIndex = position495, tokenIndex495
3813 if c := buffer[position]; c < rune('0') || c > rune('9') {
3814 goto l497
3815 }
3816 position++
3817 goto l495
3818 l497:
3819 position, tokenIndex = position495, tokenIndex495
3820 {
3821 position498, tokenIndex498 := position, tokenIndex
3822 if c := buffer[position]; c < rune('a') || c > rune('f') {
3823 goto l499
3824 }
3825 position++
3826 goto l498
3827 l499:
3828 position, tokenIndex = position498, tokenIndex498
3829 if c := buffer[position]; c < rune('A') || c > rune('F') {
3830 goto l490
3831 }
3832 position++
3833 }
3834 l498:
3835 }
3836 l495:
3837 l493:
3838 {
3839 position494, tokenIndex494 := position, tokenIndex
3840 {
3841 position500, tokenIndex500 := position, tokenIndex
3842 if c := buffer[position]; c < rune('0') || c > rune('9') {
3843 goto l501
3844 }
3845 position++
3846 goto l500
3847 l501:
3848 position, tokenIndex = position500, tokenIndex500
3849 if c := buffer[position]; c < rune('0') || c > rune('9') {
3850 goto l502
3851 }
3852 position++
3853 goto l500
3854 l502:
3855 position, tokenIndex = position500, tokenIndex500
3856 {
3857 position503, tokenIndex503 := position, tokenIndex
3858 if c := buffer[position]; c < rune('a') || c > rune('f') {
3859 goto l504
3860 }
3861 position++
3862 goto l503
3863 l504:
3864 position, tokenIndex = position503, tokenIndex503
3865 if c := buffer[position]; c < rune('A') || c > rune('F') {
3866 goto l494
3867 }
3868 position++
3869 }
3870 l503:
3871 }
3872 l500:
3873 goto l493
3874 l494:
3875 position, tokenIndex = position494, tokenIndex494
3876 }
3877 goto l480
3878 l490:
3879 position, tokenIndex = position480, tokenIndex480
3880 if c := buffer[position]; c < rune('0') || c > rune('9') {
3881 goto l474
3882 }
3883 position++
3884 l505:
3885 {
3886 position506, tokenIndex506 := position, tokenIndex
3887 if c := buffer[position]; c < rune('0') || c > rune('9') {
Robert Sloan8ff03552017-06-14 12:40:58 -07003888 goto l506
3889 }
3890 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003891 goto l505
3892 l506:
3893 position, tokenIndex = position506, tokenIndex506
Robert Sloan8ff03552017-06-14 12:40:58 -07003894 }
Robert Sloan8ff03552017-06-14 12:40:58 -07003895 }
Robert Sloan978112c2018-01-22 12:53:01 -08003896 l480:
3897 add(ruleOffset, position475)
Robert Sloan8ff03552017-06-14 12:40:58 -07003898 }
3899 return true
Robert Sloan978112c2018-01-22 12:53:01 -08003900 l474:
3901 position, tokenIndex = position474, tokenIndex474
3902 return false
3903 },
3904 /* 37 Section <- <([a-z] / [A-Z] / '@')+> */
3905 func() bool {
3906 position507, tokenIndex507 := position, tokenIndex
3907 {
3908 position508 := position
3909 {
3910 position511, tokenIndex511 := position, tokenIndex
3911 if c := buffer[position]; c < rune('a') || c > rune('z') {
3912 goto l512
3913 }
3914 position++
3915 goto l511
3916 l512:
3917 position, tokenIndex = position511, tokenIndex511
3918 if c := buffer[position]; c < rune('A') || c > rune('Z') {
3919 goto l513
3920 }
3921 position++
3922 goto l511
3923 l513:
3924 position, tokenIndex = position511, tokenIndex511
3925 if buffer[position] != rune('@') {
3926 goto l507
3927 }
3928 position++
3929 }
3930 l511:
3931 l509:
3932 {
3933 position510, tokenIndex510 := position, tokenIndex
3934 {
3935 position514, tokenIndex514 := position, tokenIndex
3936 if c := buffer[position]; c < rune('a') || c > rune('z') {
3937 goto l515
3938 }
3939 position++
3940 goto l514
3941 l515:
3942 position, tokenIndex = position514, tokenIndex514
3943 if c := buffer[position]; c < rune('A') || c > rune('Z') {
3944 goto l516
3945 }
3946 position++
3947 goto l514
3948 l516:
3949 position, tokenIndex = position514, tokenIndex514
3950 if buffer[position] != rune('@') {
3951 goto l510
3952 }
3953 position++
3954 }
3955 l514:
3956 goto l509
3957 l510:
3958 position, tokenIndex = position510, tokenIndex510
3959 }
3960 add(ruleSection, position508)
3961 }
3962 return true
3963 l507:
3964 position, tokenIndex = position507, tokenIndex507
Robert Sloan8ff03552017-06-14 12:40:58 -07003965 return false
3966 },
3967 /* 38 SegmentRegister <- <('%' ([c-g] / 's') ('s' ':'))> */
3968 func() bool {
Robert Sloan978112c2018-01-22 12:53:01 -08003969 position517, tokenIndex517 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003970 {
Robert Sloan978112c2018-01-22 12:53:01 -08003971 position518 := position
Robert Sloan8ff03552017-06-14 12:40:58 -07003972 if buffer[position] != rune('%') {
Robert Sloan978112c2018-01-22 12:53:01 -08003973 goto l517
Robert Sloan8ff03552017-06-14 12:40:58 -07003974 }
3975 position++
3976 {
Robert Sloan978112c2018-01-22 12:53:01 -08003977 position519, tokenIndex519 := position, tokenIndex
Robert Sloan8ff03552017-06-14 12:40:58 -07003978 if c := buffer[position]; c < rune('c') || c > rune('g') {
Robert Sloan978112c2018-01-22 12:53:01 -08003979 goto l520
Robert Sloan8ff03552017-06-14 12:40:58 -07003980 }
3981 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003982 goto l519
3983 l520:
3984 position, tokenIndex = position519, tokenIndex519
Robert Sloan8ff03552017-06-14 12:40:58 -07003985 if buffer[position] != rune('s') {
Robert Sloan978112c2018-01-22 12:53:01 -08003986 goto l517
Robert Sloan8ff03552017-06-14 12:40:58 -07003987 }
3988 position++
3989 }
Robert Sloan978112c2018-01-22 12:53:01 -08003990 l519:
Robert Sloan8ff03552017-06-14 12:40:58 -07003991 if buffer[position] != rune('s') {
Robert Sloan978112c2018-01-22 12:53:01 -08003992 goto l517
Robert Sloan8ff03552017-06-14 12:40:58 -07003993 }
3994 position++
3995 if buffer[position] != rune(':') {
Robert Sloan978112c2018-01-22 12:53:01 -08003996 goto l517
Robert Sloan8ff03552017-06-14 12:40:58 -07003997 }
3998 position++
Robert Sloan978112c2018-01-22 12:53:01 -08003999 add(ruleSegmentRegister, position518)
Robert Sloan8ff03552017-06-14 12:40:58 -07004000 }
4001 return true
Robert Sloan978112c2018-01-22 12:53:01 -08004002 l517:
4003 position, tokenIndex = position517, tokenIndex517
Robert Sloan8ff03552017-06-14 12:40:58 -07004004 return false
4005 },
4006 }
4007 p.rules = _rules
4008}