# Generated from SystemRDL.g4 by ANTLR 4.13.1
# encoding: utf-8
from antlr4 import *
from io import StringIO
import sys
if sys.version_info[1] > 5:
	from typing import TextIO
else:
	from typing.io import TextIO

def serializedATN():
    return [
        4,1,125,810,2,0,7,0,2,1,7,1,2,2,7,2,2,3,7,3,2,4,7,4,2,5,7,5,2,6,
        7,6,2,7,7,7,2,8,7,8,2,9,7,9,2,10,7,10,2,11,7,11,2,12,7,12,2,13,7,
        13,2,14,7,14,2,15,7,15,2,16,7,16,2,17,7,17,2,18,7,18,2,19,7,19,2,
        20,7,20,2,21,7,21,2,22,7,22,2,23,7,23,2,24,7,24,2,25,7,25,2,26,7,
        26,2,27,7,27,2,28,7,28,2,29,7,29,2,30,7,30,2,31,7,31,2,32,7,32,2,
        33,7,33,2,34,7,34,2,35,7,35,2,36,7,36,2,37,7,37,2,38,7,38,2,39,7,
        39,2,40,7,40,2,41,7,41,2,42,7,42,2,43,7,43,2,44,7,44,2,45,7,45,2,
        46,7,46,2,47,7,47,2,48,7,48,2,49,7,49,2,50,7,50,2,51,7,51,2,52,7,
        52,2,53,7,53,2,54,7,54,2,55,7,55,2,56,7,56,2,57,7,57,2,58,7,58,2,
        59,7,59,2,60,7,60,2,61,7,61,2,62,7,62,2,63,7,63,2,64,7,64,2,65,7,
        65,2,66,7,66,2,67,7,67,2,68,7,68,2,69,7,69,2,70,7,70,2,71,7,71,2,
        72,7,72,2,73,7,73,2,74,7,74,2,75,7,75,2,76,7,76,2,77,7,77,2,78,7,
        78,2,79,7,79,2,80,7,80,2,81,7,81,2,82,7,82,2,83,7,83,2,84,7,84,1,
        0,1,0,1,0,5,0,174,8,0,10,0,12,0,177,9,0,1,0,1,0,1,1,1,1,1,1,1,2,
        1,2,1,2,1,2,1,2,1,2,1,2,1,2,3,2,192,8,2,1,3,1,3,1,3,1,3,1,3,3,3,
        199,8,3,3,3,201,8,3,1,3,1,3,1,3,1,3,1,3,3,3,208,8,3,1,3,1,3,1,3,
        1,3,1,3,1,3,1,3,1,3,3,3,218,8,3,1,4,3,4,221,8,4,1,4,3,4,224,8,4,
        1,4,1,4,1,4,1,5,1,5,1,5,1,6,1,6,1,6,3,6,235,8,6,1,6,1,6,1,7,1,7,
        1,7,1,8,1,8,1,8,1,8,5,8,246,8,8,10,8,12,8,249,9,8,1,8,1,8,1,9,1,
        9,1,9,1,9,1,9,1,9,1,9,3,9,260,8,9,1,10,3,10,263,8,10,1,10,1,10,1,
        10,5,10,268,8,10,10,10,12,10,271,9,10,1,11,1,11,4,11,275,8,11,11,
        11,12,11,276,1,11,3,11,280,8,11,1,11,3,11,283,8,11,1,11,3,11,286,
        8,11,1,11,3,11,289,8,11,1,11,3,11,292,8,11,1,12,1,12,1,12,1,13,1,
        13,1,13,1,14,1,14,1,14,1,15,1,15,1,15,1,16,1,16,1,17,1,17,3,17,310,
        8,17,1,18,1,18,1,19,1,19,1,19,1,19,1,19,5,19,319,8,19,10,19,12,19,
        322,9,19,1,19,1,19,1,20,1,20,1,20,3,20,329,8,20,1,20,1,20,3,20,333,
        8,20,1,21,1,21,1,21,1,21,1,21,5,21,340,8,21,10,21,12,21,343,9,21,
        1,21,1,21,1,22,1,22,1,22,1,22,1,22,1,22,1,23,1,23,1,23,1,23,3,23,
        357,8,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,
        1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,
        1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,1,23,
        1,23,1,23,5,23,398,8,23,10,23,12,23,401,9,23,1,24,1,24,1,24,1,24,
        1,24,1,24,1,24,1,24,1,24,3,24,412,8,24,1,25,1,25,1,25,1,25,5,25,
        418,8,25,10,25,12,25,421,9,25,1,25,1,25,1,26,1,26,1,26,1,26,1,26,
        1,27,1,27,1,27,1,27,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,28,
        1,28,1,28,1,28,3,28,446,8,28,1,29,1,29,3,29,450,8,29,1,30,1,30,1,
        30,1,30,1,30,1,30,1,31,1,31,1,31,1,31,1,32,1,32,1,32,1,33,1,33,3,
        33,467,8,33,1,34,1,34,3,34,471,8,34,1,34,3,34,474,8,34,1,35,1,35,
        1,35,1,35,1,35,1,35,1,35,1,35,1,35,3,35,485,8,35,1,36,1,36,1,36,
        3,36,490,8,36,1,37,1,37,1,38,1,38,1,39,1,39,1,39,1,39,1,39,1,39,
        1,39,1,39,5,39,504,8,39,10,39,12,39,507,9,39,1,39,1,39,3,39,511,
        8,39,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1,40,5,40,523,
        8,40,10,40,12,40,526,9,40,1,40,1,40,3,40,530,8,40,1,41,1,41,1,41,
        1,41,1,42,1,42,1,42,1,42,1,43,1,43,1,44,1,44,1,45,1,45,1,46,1,46,
        1,47,1,47,1,48,1,48,1,48,5,48,553,8,48,10,48,12,48,556,9,48,1,49,
        1,49,5,49,560,8,49,10,49,12,49,563,9,49,1,50,1,50,1,50,1,50,3,50,
        569,8,50,1,51,3,51,572,8,51,1,51,1,51,3,51,576,8,51,1,51,1,51,3,
        51,580,8,51,1,51,3,51,583,8,51,1,52,1,52,1,52,1,52,1,52,1,52,1,52,
        1,52,3,52,593,8,52,1,53,1,53,3,53,597,8,53,1,53,1,53,3,53,601,8,
        53,1,54,1,54,1,54,1,54,1,55,1,55,1,55,1,56,1,56,3,56,612,8,56,1,
        57,1,57,1,58,1,58,1,59,1,59,1,59,1,59,1,59,1,59,4,59,624,8,59,11,
        59,12,59,625,1,59,1,59,1,60,1,60,1,60,1,60,3,60,634,8,60,1,61,1,
        61,1,61,1,61,3,61,640,8,61,1,62,1,62,1,62,3,62,645,8,62,1,63,1,63,
        1,63,1,63,1,63,5,63,652,8,63,10,63,12,63,655,9,63,1,64,1,64,3,64,
        659,8,64,1,65,1,65,1,65,1,65,1,66,1,66,1,66,1,66,1,67,1,67,1,67,
        1,67,1,67,1,67,4,67,675,8,67,11,67,12,67,676,1,67,1,67,1,68,1,68,
        1,68,3,68,684,8,68,1,68,1,68,1,68,1,68,5,68,690,8,68,10,68,12,68,
        693,9,68,1,68,3,68,696,8,68,1,69,1,69,1,69,1,69,1,70,3,70,703,8,
        70,1,70,1,70,1,70,1,70,3,70,709,8,70,1,70,1,70,1,70,1,70,5,70,715,
        8,70,10,70,12,70,718,9,70,1,70,1,70,1,71,1,71,1,71,3,71,725,8,71,
        1,72,1,72,3,72,729,8,72,1,73,1,73,3,73,733,8,73,1,73,1,73,1,73,3,
        73,738,8,73,1,74,1,74,1,74,1,74,1,75,1,75,1,75,1,76,1,76,1,76,1,
        76,5,76,751,8,76,10,76,12,76,754,9,76,1,76,1,76,1,77,1,77,1,77,1,
        77,3,77,762,8,77,1,78,1,78,1,78,5,78,767,8,78,10,78,12,78,770,9,
        78,1,79,1,79,1,79,1,79,1,80,1,80,1,80,1,80,1,81,1,81,1,81,1,81,1,
        81,1,81,5,81,786,8,81,10,81,12,81,789,9,81,1,81,1,81,1,82,1,82,1,
        82,1,82,1,83,1,83,3,83,799,8,83,1,84,1,84,1,84,1,84,1,84,1,84,1,
        84,3,84,808,8,84,1,84,0,1,46,85,0,2,4,6,8,10,12,14,16,18,20,22,24,
        26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,
        70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,
        110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,
        142,144,146,148,150,152,154,156,158,160,162,164,166,168,0,24,1,0,
        28,29,1,0,30,34,3,0,96,99,101,103,105,107,2,0,110,110,112,113,1,
        0,96,97,1,0,108,109,1,0,117,120,2,0,114,114,116,116,1,0,106,107,
        1,0,18,20,1,0,23,26,1,0,19,20,3,0,18,18,22,22,125,125,1,0,36,37,
        1,0,38,44,1,0,45,47,1,0,48,56,1,0,57,59,1,0,60,61,3,0,45,46,48,49,
        60,61,1,0,62,66,2,0,76,76,78,78,2,0,68,68,71,71,2,0,114,114,116,
        120,843,0,175,1,0,0,0,2,180,1,0,0,0,4,191,1,0,0,0,6,217,1,0,0,0,
        8,220,1,0,0,0,10,228,1,0,0,0,12,231,1,0,0,0,14,238,1,0,0,0,16,241,
        1,0,0,0,18,259,1,0,0,0,20,262,1,0,0,0,22,272,1,0,0,0,24,293,1,0,
        0,0,26,296,1,0,0,0,28,299,1,0,0,0,30,302,1,0,0,0,32,305,1,0,0,0,
        34,309,1,0,0,0,36,311,1,0,0,0,38,313,1,0,0,0,40,325,1,0,0,0,42,334,
        1,0,0,0,44,346,1,0,0,0,46,356,1,0,0,0,48,411,1,0,0,0,50,413,1,0,
        0,0,52,424,1,0,0,0,54,429,1,0,0,0,56,445,1,0,0,0,58,449,1,0,0,0,
        60,451,1,0,0,0,62,457,1,0,0,0,64,461,1,0,0,0,66,466,1,0,0,0,68,473,
        1,0,0,0,70,484,1,0,0,0,72,489,1,0,0,0,74,491,1,0,0,0,76,493,1,0,
        0,0,78,510,1,0,0,0,80,529,1,0,0,0,82,531,1,0,0,0,84,535,1,0,0,0,
        86,539,1,0,0,0,88,541,1,0,0,0,90,543,1,0,0,0,92,545,1,0,0,0,94,547,
        1,0,0,0,96,549,1,0,0,0,98,557,1,0,0,0,100,564,1,0,0,0,102,582,1,
        0,0,0,104,592,1,0,0,0,106,596,1,0,0,0,108,602,1,0,0,0,110,606,1,
        0,0,0,112,611,1,0,0,0,114,613,1,0,0,0,116,615,1,0,0,0,118,617,1,
        0,0,0,120,633,1,0,0,0,122,635,1,0,0,0,124,644,1,0,0,0,126,646,1,
        0,0,0,128,658,1,0,0,0,130,660,1,0,0,0,132,664,1,0,0,0,134,668,1,
        0,0,0,136,680,1,0,0,0,138,697,1,0,0,0,140,702,1,0,0,0,142,721,1,
        0,0,0,144,728,1,0,0,0,146,737,1,0,0,0,148,739,1,0,0,0,150,743,1,
        0,0,0,152,746,1,0,0,0,154,761,1,0,0,0,156,763,1,0,0,0,158,771,1,
        0,0,0,160,775,1,0,0,0,162,779,1,0,0,0,164,792,1,0,0,0,166,798,1,
        0,0,0,168,807,1,0,0,0,170,171,3,4,2,0,171,172,5,1,0,0,172,174,1,
        0,0,0,173,170,1,0,0,0,174,177,1,0,0,0,175,173,1,0,0,0,175,176,1,
        0,0,0,176,178,1,0,0,0,177,175,1,0,0,0,178,179,5,0,0,1,179,1,1,0,
        0,0,180,181,3,46,23,0,181,182,5,0,0,1,182,3,1,0,0,0,183,192,3,6,
        3,0,184,192,3,134,67,0,185,192,3,118,59,0,186,192,3,140,70,0,187,
        192,3,146,73,0,188,192,3,8,4,0,189,192,3,102,51,0,190,192,3,104,
        52,0,191,183,1,0,0,0,191,184,1,0,0,0,191,185,1,0,0,0,191,186,1,0,
        0,0,191,187,1,0,0,0,191,188,1,0,0,0,191,189,1,0,0,0,191,190,1,0,
        0,0,192,5,1,0,0,0,193,200,3,12,6,0,194,195,3,32,16,0,195,196,3,20,
        10,0,196,201,1,0,0,0,197,199,3,20,10,0,198,197,1,0,0,0,198,199,1,
        0,0,0,199,201,1,0,0,0,200,194,1,0,0,0,200,198,1,0,0,0,201,218,1,
        0,0,0,202,207,3,14,7,0,203,204,3,32,16,0,204,205,3,20,10,0,205,208,
        1,0,0,0,206,208,3,20,10,0,207,203,1,0,0,0,207,206,1,0,0,0,208,218,
        1,0,0,0,209,210,3,32,16,0,210,211,3,12,6,0,211,212,3,20,10,0,212,
        218,1,0,0,0,213,214,3,32,16,0,214,215,3,14,7,0,215,216,3,20,10,0,
        216,218,1,0,0,0,217,193,1,0,0,0,217,202,1,0,0,0,217,209,1,0,0,0,
        217,213,1,0,0,0,218,7,1,0,0,0,219,221,3,32,16,0,220,219,1,0,0,0,
        220,221,1,0,0,0,221,223,1,0,0,0,222,224,3,10,5,0,223,222,1,0,0,0,
        223,224,1,0,0,0,224,225,1,0,0,0,225,226,5,125,0,0,226,227,3,20,10,
        0,227,9,1,0,0,0,228,229,5,27,0,0,229,230,5,125,0,0,230,11,1,0,0,
        0,231,232,3,34,17,0,232,234,5,125,0,0,233,235,3,38,19,0,234,233,
        1,0,0,0,234,235,1,0,0,0,235,236,1,0,0,0,236,237,3,16,8,0,237,13,
        1,0,0,0,238,239,3,34,17,0,239,240,3,16,8,0,240,15,1,0,0,0,241,247,
        5,2,0,0,242,243,3,18,9,0,243,244,5,1,0,0,244,246,1,0,0,0,245,242,
        1,0,0,0,246,249,1,0,0,0,247,245,1,0,0,0,247,248,1,0,0,0,248,250,
        1,0,0,0,249,247,1,0,0,0,250,251,5,3,0,0,251,17,1,0,0,0,252,260,3,
        6,3,0,253,260,3,134,67,0,254,260,3,140,70,0,255,260,3,146,73,0,256,
        260,3,8,4,0,257,260,3,102,51,0,258,260,3,104,52,0,259,252,1,0,0,
        0,259,253,1,0,0,0,259,254,1,0,0,0,259,255,1,0,0,0,259,256,1,0,0,
        0,259,257,1,0,0,0,259,258,1,0,0,0,260,19,1,0,0,0,261,263,3,42,21,
        0,262,261,1,0,0,0,262,263,1,0,0,0,263,264,1,0,0,0,264,269,3,22,11,
        0,265,266,5,4,0,0,266,268,3,22,11,0,267,265,1,0,0,0,268,271,1,0,
        0,0,269,267,1,0,0,0,269,270,1,0,0,0,270,21,1,0,0,0,271,269,1,0,0,
        0,272,279,5,125,0,0,273,275,3,62,31,0,274,273,1,0,0,0,275,276,1,
        0,0,0,276,274,1,0,0,0,276,277,1,0,0,0,277,280,1,0,0,0,278,280,3,
        60,30,0,279,274,1,0,0,0,279,278,1,0,0,0,279,280,1,0,0,0,280,282,
        1,0,0,0,281,283,3,24,12,0,282,281,1,0,0,0,282,283,1,0,0,0,283,285,
        1,0,0,0,284,286,3,26,13,0,285,284,1,0,0,0,285,286,1,0,0,0,286,288,
        1,0,0,0,287,289,3,28,14,0,288,287,1,0,0,0,288,289,1,0,0,0,289,291,
        1,0,0,0,290,292,3,30,15,0,291,290,1,0,0,0,291,292,1,0,0,0,292,23,
        1,0,0,0,293,294,5,115,0,0,294,295,3,46,23,0,295,25,1,0,0,0,296,297,
        5,121,0,0,297,298,3,46,23,0,298,27,1,0,0,0,299,300,5,122,0,0,300,
        301,3,46,23,0,301,29,1,0,0,0,302,303,5,123,0,0,303,304,3,46,23,0,
        304,31,1,0,0,0,305,306,7,0,0,0,306,33,1,0,0,0,307,310,3,36,18,0,
        308,310,5,35,0,0,309,307,1,0,0,0,309,308,1,0,0,0,310,35,1,0,0,0,
        311,312,7,1,0,0,312,37,1,0,0,0,313,314,5,5,0,0,314,315,5,6,0,0,315,
        320,3,40,20,0,316,317,5,4,0,0,317,319,3,40,20,0,318,316,1,0,0,0,
        319,322,1,0,0,0,320,318,1,0,0,0,320,321,1,0,0,0,321,323,1,0,0,0,
        322,320,1,0,0,0,323,324,5,7,0,0,324,39,1,0,0,0,325,326,3,66,33,0,
        326,328,5,125,0,0,327,329,3,64,32,0,328,327,1,0,0,0,328,329,1,0,
        0,0,329,332,1,0,0,0,330,331,5,115,0,0,331,333,3,46,23,0,332,330,
        1,0,0,0,332,333,1,0,0,0,333,41,1,0,0,0,334,335,5,5,0,0,335,336,5,
        6,0,0,336,341,3,44,22,0,337,338,5,4,0,0,338,340,3,44,22,0,339,337,
        1,0,0,0,340,343,1,0,0,0,341,339,1,0,0,0,341,342,1,0,0,0,342,344,
        1,0,0,0,343,341,1,0,0,0,344,345,5,7,0,0,345,43,1,0,0,0,346,347,5,
        8,0,0,347,348,5,125,0,0,348,349,5,6,0,0,349,350,3,46,23,0,350,351,
        5,7,0,0,351,45,1,0,0,0,352,353,6,23,-1,0,353,354,7,2,0,0,354,357,
        3,48,24,0,355,357,3,48,24,0,356,352,1,0,0,0,356,355,1,0,0,0,357,
        399,1,0,0,0,358,359,10,13,0,0,359,360,5,111,0,0,360,398,3,46,23,
        14,361,362,10,12,0,0,362,363,7,3,0,0,363,398,3,46,23,13,364,365,
        10,11,0,0,365,366,7,4,0,0,366,398,3,46,23,12,367,368,10,10,0,0,368,
        369,7,5,0,0,369,398,3,46,23,11,370,371,10,9,0,0,371,372,7,6,0,0,
        372,398,3,46,23,10,373,374,10,8,0,0,374,375,7,7,0,0,375,398,3,46,
        23,9,376,377,10,7,0,0,377,378,5,102,0,0,378,398,3,46,23,8,379,380,
        10,6,0,0,380,381,7,8,0,0,381,398,3,46,23,7,382,383,10,5,0,0,383,
        384,5,103,0,0,384,398,3,46,23,6,385,386,10,4,0,0,386,387,5,100,0,
        0,387,398,3,46,23,5,388,389,10,3,0,0,389,390,5,104,0,0,390,398,3,
        46,23,4,391,392,10,2,0,0,392,393,5,9,0,0,393,394,3,46,23,0,394,395,
        5,10,0,0,395,396,3,46,23,2,396,398,1,0,0,0,397,358,1,0,0,0,397,361,
        1,0,0,0,397,364,1,0,0,0,397,367,1,0,0,0,397,370,1,0,0,0,397,373,
        1,0,0,0,397,376,1,0,0,0,397,379,1,0,0,0,397,382,1,0,0,0,397,385,
        1,0,0,0,397,388,1,0,0,0,397,391,1,0,0,0,398,401,1,0,0,0,399,397,
        1,0,0,0,399,400,1,0,0,0,400,47,1,0,0,0,401,399,1,0,0,0,402,412,3,
        70,35,0,403,412,3,50,25,0,404,412,3,52,26,0,405,412,3,54,27,0,406,
        412,3,56,28,0,407,412,3,100,50,0,408,412,3,96,48,0,409,412,3,80,
        40,0,410,412,3,78,39,0,411,402,1,0,0,0,411,403,1,0,0,0,411,404,1,
        0,0,0,411,405,1,0,0,0,411,406,1,0,0,0,411,407,1,0,0,0,411,408,1,
        0,0,0,411,409,1,0,0,0,411,410,1,0,0,0,412,49,1,0,0,0,413,414,5,2,
        0,0,414,419,3,46,23,0,415,416,5,4,0,0,416,418,3,46,23,0,417,415,
        1,0,0,0,418,421,1,0,0,0,419,417,1,0,0,0,419,420,1,0,0,0,420,422,
        1,0,0,0,421,419,1,0,0,0,422,423,5,3,0,0,423,51,1,0,0,0,424,425,5,
        2,0,0,425,426,3,46,23,0,426,427,3,50,25,0,427,428,5,3,0,0,428,53,
        1,0,0,0,429,430,5,6,0,0,430,431,3,46,23,0,431,432,5,7,0,0,432,55,
        1,0,0,0,433,434,7,9,0,0,434,435,5,11,0,0,435,436,5,6,0,0,436,437,
        3,46,23,0,437,438,5,7,0,0,438,446,1,0,0,0,439,440,3,58,29,0,440,
        441,5,11,0,0,441,442,5,6,0,0,442,443,3,46,23,0,443,444,5,7,0,0,444,
        446,1,0,0,0,445,433,1,0,0,0,445,439,1,0,0,0,446,57,1,0,0,0,447,450,
        3,70,35,0,448,450,3,54,27,0,449,447,1,0,0,0,449,448,1,0,0,0,450,
        59,1,0,0,0,451,452,5,12,0,0,452,453,3,46,23,0,453,454,5,10,0,0,454,
        455,3,46,23,0,455,456,5,13,0,0,456,61,1,0,0,0,457,458,5,12,0,0,458,
        459,3,46,23,0,459,460,5,13,0,0,460,63,1,0,0,0,461,462,5,12,0,0,462,
        463,5,13,0,0,463,65,1,0,0,0,464,467,3,68,34,0,465,467,7,10,0,0,466,
        464,1,0,0,0,466,465,1,0,0,0,467,67,1,0,0,0,468,470,7,11,0,0,469,
        471,5,21,0,0,470,469,1,0,0,0,470,471,1,0,0,0,471,474,1,0,0,0,472,
        474,7,12,0,0,473,468,1,0,0,0,473,472,1,0,0,0,474,69,1,0,0,0,475,
        485,3,72,36,0,476,485,3,74,37,0,477,485,3,76,38,0,478,485,3,86,43,
        0,479,485,3,88,44,0,480,485,3,90,45,0,481,485,3,92,46,0,482,485,
        3,94,47,0,483,485,3,84,42,0,484,475,1,0,0,0,484,476,1,0,0,0,484,
        477,1,0,0,0,484,478,1,0,0,0,484,479,1,0,0,0,484,480,1,0,0,0,484,
        481,1,0,0,0,484,482,1,0,0,0,484,483,1,0,0,0,485,71,1,0,0,0,486,490,
        5,92,0,0,487,490,5,93,0,0,488,490,5,94,0,0,489,486,1,0,0,0,489,487,
        1,0,0,0,489,488,1,0,0,0,490,73,1,0,0,0,491,492,5,95,0,0,492,75,1,
        0,0,0,493,494,7,13,0,0,494,77,1,0,0,0,495,496,5,11,0,0,496,497,5,
        2,0,0,497,511,5,3,0,0,498,499,5,11,0,0,499,500,5,2,0,0,500,505,3,
        46,23,0,501,502,5,4,0,0,502,504,3,46,23,0,503,501,1,0,0,0,504,507,
        1,0,0,0,505,503,1,0,0,0,505,506,1,0,0,0,506,508,1,0,0,0,507,505,
        1,0,0,0,508,509,5,3,0,0,509,511,1,0,0,0,510,495,1,0,0,0,510,498,
        1,0,0,0,511,79,1,0,0,0,512,513,5,125,0,0,513,514,5,11,0,0,514,515,
        5,2,0,0,515,530,5,3,0,0,516,517,5,125,0,0,517,518,5,11,0,0,518,519,
        5,2,0,0,519,524,3,82,41,0,520,521,5,4,0,0,521,523,3,82,41,0,522,
        520,1,0,0,0,523,526,1,0,0,0,524,522,1,0,0,0,524,525,1,0,0,0,525,
        527,1,0,0,0,526,524,1,0,0,0,527,528,5,3,0,0,528,530,1,0,0,0,529,
        512,1,0,0,0,529,516,1,0,0,0,530,81,1,0,0,0,531,532,5,125,0,0,532,
        533,5,10,0,0,533,534,3,46,23,0,534,83,1,0,0,0,535,536,5,125,0,0,
        536,537,5,14,0,0,537,538,5,125,0,0,538,85,1,0,0,0,539,540,7,14,0,
        0,540,87,1,0,0,0,541,542,7,15,0,0,542,89,1,0,0,0,543,544,7,16,0,
        0,544,91,1,0,0,0,545,546,7,17,0,0,546,93,1,0,0,0,547,548,7,18,0,
        0,548,95,1,0,0,0,549,554,3,98,49,0,550,551,5,8,0,0,551,553,3,98,
        49,0,552,550,1,0,0,0,553,556,1,0,0,0,554,552,1,0,0,0,554,555,1,0,
        0,0,555,97,1,0,0,0,556,554,1,0,0,0,557,561,5,125,0,0,558,560,3,62,
        31,0,559,558,1,0,0,0,560,563,1,0,0,0,561,559,1,0,0,0,561,562,1,0,
        0,0,562,99,1,0,0,0,563,561,1,0,0,0,564,565,3,96,48,0,565,568,5,15,
        0,0,566,569,3,114,57,0,567,569,5,125,0,0,568,566,1,0,0,0,568,567,
        1,0,0,0,569,101,1,0,0,0,570,572,5,72,0,0,571,570,1,0,0,0,571,572,
        1,0,0,0,572,573,1,0,0,0,573,583,3,106,53,0,574,576,5,72,0,0,575,
        574,1,0,0,0,575,576,1,0,0,0,576,577,1,0,0,0,577,583,3,108,54,0,578,
        580,5,72,0,0,579,578,1,0,0,0,579,580,1,0,0,0,580,581,1,0,0,0,581,
        583,3,110,55,0,582,571,1,0,0,0,582,575,1,0,0,0,582,579,1,0,0,0,583,
        103,1,0,0,0,584,585,3,96,48,0,585,586,5,15,0,0,586,587,3,106,53,
        0,587,593,1,0,0,0,588,589,3,96,48,0,589,590,5,15,0,0,590,591,3,108,
        54,0,591,593,1,0,0,0,592,584,1,0,0,0,592,588,1,0,0,0,593,105,1,0,
        0,0,594,597,3,114,57,0,595,597,5,125,0,0,596,594,1,0,0,0,596,595,
        1,0,0,0,597,600,1,0,0,0,598,599,5,115,0,0,599,601,3,112,56,0,600,
        598,1,0,0,0,600,601,1,0,0,0,601,107,1,0,0,0,602,603,5,74,0,0,603,
        604,5,115,0,0,604,605,5,125,0,0,605,109,1,0,0,0,606,607,3,116,58,
        0,607,608,5,125,0,0,608,111,1,0,0,0,609,612,3,94,47,0,610,612,3,
        46,23,0,611,609,1,0,0,0,611,610,1,0,0,0,612,113,1,0,0,0,613,614,
        7,19,0,0,614,115,1,0,0,0,615,616,7,20,0,0,616,117,1,0,0,0,617,618,
        5,77,0,0,618,619,5,125,0,0,619,623,5,2,0,0,620,621,3,120,60,0,621,
        622,5,1,0,0,622,624,1,0,0,0,623,620,1,0,0,0,624,625,1,0,0,0,625,
        623,1,0,0,0,625,626,1,0,0,0,626,627,1,0,0,0,627,628,5,3,0,0,628,
        119,1,0,0,0,629,634,3,122,61,0,630,634,3,126,63,0,631,634,3,130,
        65,0,632,634,3,132,66,0,633,629,1,0,0,0,633,630,1,0,0,0,633,631,
        1,0,0,0,633,632,1,0,0,0,634,121,1,0,0,0,635,636,5,81,0,0,636,637,
        5,115,0,0,637,639,3,124,62,0,638,640,3,64,32,0,639,638,1,0,0,0,639,
        640,1,0,0,0,640,123,1,0,0,0,641,645,3,36,18,0,642,645,7,21,0,0,643,
        645,3,68,34,0,644,641,1,0,0,0,644,642,1,0,0,0,644,643,1,0,0,0,645,
        125,1,0,0,0,646,647,5,69,0,0,647,648,5,115,0,0,648,653,3,128,64,
        0,649,650,5,103,0,0,650,652,3,128,64,0,651,649,1,0,0,0,652,655,1,
        0,0,0,653,651,1,0,0,0,653,654,1,0,0,0,654,127,1,0,0,0,655,653,1,
        0,0,0,656,659,3,34,17,0,657,659,7,22,0,0,658,656,1,0,0,0,658,657,
        1,0,0,0,659,129,1,0,0,0,660,661,5,72,0,0,661,662,5,115,0,0,662,663,
        3,46,23,0,663,131,1,0,0,0,664,665,5,71,0,0,665,666,5,115,0,0,666,
        667,5,70,0,0,667,133,1,0,0,0,668,669,5,73,0,0,669,670,5,125,0,0,
        670,674,5,2,0,0,671,672,3,136,68,0,672,673,5,1,0,0,673,675,1,0,0,
        0,674,671,1,0,0,0,675,676,1,0,0,0,676,674,1,0,0,0,676,677,1,0,0,
        0,677,678,1,0,0,0,678,679,5,3,0,0,679,135,1,0,0,0,680,683,5,125,
        0,0,681,682,5,115,0,0,682,684,3,46,23,0,683,681,1,0,0,0,683,684,
        1,0,0,0,684,695,1,0,0,0,685,691,5,2,0,0,686,687,3,138,69,0,687,688,
        5,1,0,0,688,690,1,0,0,0,689,686,1,0,0,0,690,693,1,0,0,0,691,689,
        1,0,0,0,691,692,1,0,0,0,692,694,1,0,0,0,693,691,1,0,0,0,694,696,
        5,3,0,0,695,685,1,0,0,0,695,696,1,0,0,0,696,137,1,0,0,0,697,698,
        5,125,0,0,698,699,5,115,0,0,699,700,3,46,23,0,700,139,1,0,0,0,701,
        703,5,67,0,0,702,701,1,0,0,0,702,703,1,0,0,0,703,704,1,0,0,0,704,
        705,5,79,0,0,705,708,5,125,0,0,706,707,5,10,0,0,707,709,5,125,0,
        0,708,706,1,0,0,0,708,709,1,0,0,0,709,710,1,0,0,0,710,716,5,2,0,
        0,711,712,3,142,71,0,712,713,5,1,0,0,713,715,1,0,0,0,714,711,1,0,
        0,0,715,718,1,0,0,0,716,714,1,0,0,0,716,717,1,0,0,0,717,719,1,0,
        0,0,718,716,1,0,0,0,719,720,5,3,0,0,720,141,1,0,0,0,721,722,3,144,
        72,0,722,724,5,125,0,0,723,725,3,64,32,0,724,723,1,0,0,0,724,725,
        1,0,0,0,725,143,1,0,0,0,726,729,3,66,33,0,727,729,3,34,17,0,728,
        726,1,0,0,0,728,727,1,0,0,0,729,145,1,0,0,0,730,732,3,148,74,0,731,
        733,3,156,78,0,732,731,1,0,0,0,732,733,1,0,0,0,733,738,1,0,0,0,734,
        735,3,150,75,0,735,736,3,156,78,0,736,738,1,0,0,0,737,730,1,0,0,
        0,737,734,1,0,0,0,738,147,1,0,0,0,739,740,5,71,0,0,740,741,5,125,
        0,0,741,742,3,152,76,0,742,149,1,0,0,0,743,744,5,71,0,0,744,745,
        3,152,76,0,745,151,1,0,0,0,746,752,5,2,0,0,747,748,3,154,77,0,748,
        749,5,1,0,0,749,751,1,0,0,0,750,747,1,0,0,0,751,754,1,0,0,0,752,
        750,1,0,0,0,752,753,1,0,0,0,753,755,1,0,0,0,754,752,1,0,0,0,755,
        756,5,3,0,0,756,153,1,0,0,0,757,762,3,158,79,0,758,762,3,160,80,
        0,759,762,3,162,81,0,760,762,3,164,82,0,761,757,1,0,0,0,761,758,
        1,0,0,0,761,759,1,0,0,0,761,760,1,0,0,0,762,155,1,0,0,0,763,768,
        5,125,0,0,764,765,5,4,0,0,765,767,5,125,0,0,766,764,1,0,0,0,767,
        770,1,0,0,0,768,766,1,0,0,0,768,769,1,0,0,0,769,157,1,0,0,0,770,
        768,1,0,0,0,771,772,3,46,23,0,772,773,7,23,0,0,773,774,3,46,23,0,
        774,159,1,0,0,0,775,776,5,125,0,0,776,777,5,115,0,0,777,778,3,46,
        23,0,778,161,1,0,0,0,779,780,3,166,83,0,780,781,5,75,0,0,781,782,
        5,2,0,0,782,787,3,168,84,0,783,784,5,4,0,0,784,786,3,168,84,0,785,
        783,1,0,0,0,786,789,1,0,0,0,787,785,1,0,0,0,787,788,1,0,0,0,788,
        790,1,0,0,0,789,787,1,0,0,0,790,791,5,3,0,0,791,163,1,0,0,0,792,
        793,3,166,83,0,793,794,5,75,0,0,794,795,5,125,0,0,795,165,1,0,0,
        0,796,799,5,80,0,0,797,799,3,96,48,0,798,796,1,0,0,0,798,797,1,0,
        0,0,799,167,1,0,0,0,800,808,3,46,23,0,801,802,5,12,0,0,802,803,3,
        46,23,0,803,804,5,10,0,0,804,805,3,46,23,0,805,806,5,13,0,0,806,
        808,1,0,0,0,807,800,1,0,0,0,807,801,1,0,0,0,808,169,1,0,0,0,74,175,
        191,198,200,207,217,220,223,234,247,259,262,269,276,279,282,285,
        288,291,309,320,328,332,341,356,397,399,411,419,445,449,466,470,
        473,484,489,505,510,524,529,554,561,568,571,575,579,582,592,596,
        600,611,625,633,639,644,653,658,676,683,691,695,702,708,716,724,
        728,732,737,752,761,768,787,798,807
    ]

class SystemRDLParser ( Parser ):

    grammarFileName = "SystemRDL.g4"

    atn = ATNDeserializer().deserialize(serializedATN())

    decisionsToDFA = [ DFA(ds, i) for i, ds in enumerate(atn.decisionToState) ]

    sharedContextCache = PredictionContextCache()

    literalNames = [ "<INVALID>", "';'", "'{'", "'}'", "','", "'#'", "'('", 
                     "')'", "'.'", "'?'", "':'", "'''", "'['", "']'", "'::'", 
                     "'->'", "<INVALID>", "<INVALID>", "'boolean'", "'bit'", 
                     "'longint'", "'unsigned'", "'string'", "'accesstype'", 
                     "'addressingtype'", "'onreadtype'", "'onwritetype'", 
                     "'alias'", "'external'", "'internal'", "'addrmap'", 
                     "'regfile'", "'reg'", "'field'", "'mem'", "'signal'", 
                     "'true'", "'false'", "'na'", "'rw'", "'wr'", "'r'", 
                     "'w'", "'rw1'", "'w1'", "'rclr'", "'rset'", "'ruser'", 
                     "'woset'", "'woclr'", "'wot'", "'wzs'", "'wzc'", "'wzt'", 
                     "'wclr'", "'wset'", "'wuser'", "'compact'", "'regalign'", 
                     "'fullalign'", "'hw'", "'sw'", "'posedge'", "'negedge'", 
                     "'bothedge'", "'level'", "'nonsticky'", "'abstract'", 
                     "'all'", "'component'", "'componentwidth'", "'constraint'", 
                     "'default'", "'enum'", "'encode'", "'inside'", "'number'", 
                     "'property'", "'ref'", "'struct'", "'this'", "'type'", 
                     "'alternate'", "'byte'", "'int'", "'precedencetype'", 
                     "'real'", "'shortint'", "'shortreal'", "'signed'", 
                     "'with'", "'within'", "<INVALID>", "<INVALID>", "<INVALID>", 
                     "<INVALID>", "'+'", "'-'", "'!'", "'~'", "'&&'", "'~&'", 
                     "'&'", "'|'", "'||'", "'~|'", "'^'", "<INVALID>", "'<<'", 
                     "'>>'", "'*'", "'**'", "'/'", "'%'", "'=='", "'='", 
                     "'!='", "'<='", "'<'", "'>='", "'>'", "'@'", "'+='", 
                     "'%='" ]

    symbolicNames = [ "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "<INVALID>", "<INVALID>", "<INVALID>", "<INVALID>", 
                      "SL_COMMENT", "ML_COMMENT", "BOOLEAN_kw", "BIT_kw", 
                      "LONGINT_kw", "UNSIGNED_kw", "STRING_kw", "ACCESSTYPE_kw", 
                      "ADDRESSINGTYPE_kw", "ONREADTYPE_kw", "ONWRITETYPE_kw", 
                      "ALIAS_kw", "EXTERNAL_kw", "INTERNAL_kw", "ADDRMAP_kw", 
                      "REGFILE_kw", "REG_kw", "FIELD_kw", "MEM_kw", "SIGNAL_kw", 
                      "TRUE_kw", "FALSE_kw", "NA_kw", "RW_kw", "WR_kw", 
                      "R_kw", "W_kw", "RW1_kw", "W1_kw", "RCLR_kw", "RSET_kw", 
                      "RUSER_kw", "WOSET_kw", "WOCLR_kw", "WOT_kw", "WZS_kw", 
                      "WZC_kw", "WZT_kw", "WCLR_kw", "WSET_kw", "WUSER_kw", 
                      "COMPACT_kw", "REGALIGN_kw", "FULLALIGN_kw", "HW_kw", 
                      "SW_kw", "POSEDGE_kw", "NEGEDGE_kw", "BOTHEDGE_kw", 
                      "LEVEL_kw", "NONSTICKY_kw", "ABSTRACT_kw", "ALL_kw", 
                      "COMPONENT_kw", "COMPONENTWIDTH_kw", "CONSTRAINT_kw", 
                      "DEFAULT_kw", "ENUM_kw", "ENCODE_kw", "INSIDE_kw", 
                      "NUMBER_kw", "PROPERTY_kw", "REF_kw", "STRUCT_kw", 
                      "THIS_kw", "TYPE_kw", "ALTERNATE_kw", "BYTE_kw", "INT_kw", 
                      "PRECEDENCETYPE_kw", "REAL_kw", "SHORTINT_kw", "SHORTREAL_kw", 
                      "SIGNED_kw", "WITH_kw", "WITHIN_kw", "INT", "HEX_INT", 
                      "VLOG_INT", "STRING", "PLUS", "MINUS", "BNOT", "NOT", 
                      "BAND", "NAND", "AND", "OR", "BOR", "NOR", "XOR", 
                      "XNOR", "LSHIFT", "RSHIFT", "MULT", "EXP", "DIV", 
                      "MOD", "EQ", "ASSIGN", "NEQ", "LEQ", "LT", "GEQ", 
                      "GT", "AT", "INC", "ALIGN", "WS", "ID" ]

    RULE_root = 0
    RULE_eval_expr_root = 1
    RULE_root_elem = 2
    RULE_component_def = 3
    RULE_explicit_component_inst = 4
    RULE_component_inst_alias = 5
    RULE_component_named_def = 6
    RULE_component_anon_def = 7
    RULE_component_body = 8
    RULE_component_body_elem = 9
    RULE_component_insts = 10
    RULE_component_inst = 11
    RULE_field_inst_reset = 12
    RULE_inst_addr_fixed = 13
    RULE_inst_addr_stride = 14
    RULE_inst_addr_align = 15
    RULE_component_inst_type = 16
    RULE_component_type = 17
    RULE_component_type_primary = 18
    RULE_param_def = 19
    RULE_param_def_elem = 20
    RULE_param_inst = 21
    RULE_param_assignment = 22
    RULE_expr = 23
    RULE_expr_primary = 24
    RULE_concatenate = 25
    RULE_replicate = 26
    RULE_paren_expr = 27
    RULE_cast = 28
    RULE_cast_width_expr = 29
    RULE_range_suffix = 30
    RULE_array_suffix = 31
    RULE_array_type_suffix = 32
    RULE_data_type = 33
    RULE_basic_data_type = 34
    RULE_literal = 35
    RULE_number = 36
    RULE_string_literal = 37
    RULE_boolean_literal = 38
    RULE_array_literal = 39
    RULE_struct_literal = 40
    RULE_struct_kv = 41
    RULE_enum_literal = 42
    RULE_accesstype_literal = 43
    RULE_onreadtype_literal = 44
    RULE_onwritetype_literal = 45
    RULE_addressingtype_literal = 46
    RULE_precedencetype_literal = 47
    RULE_instance_ref = 48
    RULE_instance_ref_element = 49
    RULE_prop_ref = 50
    RULE_local_property_assignment = 51
    RULE_dynamic_property_assignment = 52
    RULE_normal_prop_assign = 53
    RULE_encode_prop_assign = 54
    RULE_prop_mod_assign = 55
    RULE_prop_assignment_rhs = 56
    RULE_prop_keyword = 57
    RULE_prop_mod = 58
    RULE_udp_def = 59
    RULE_udp_attr = 60
    RULE_udp_type = 61
    RULE_udp_data_type = 62
    RULE_udp_usage = 63
    RULE_udp_comp_type = 64
    RULE_udp_default = 65
    RULE_udp_constraint = 66
    RULE_enum_def = 67
    RULE_enum_entry = 68
    RULE_enum_prop_assign = 69
    RULE_struct_def = 70
    RULE_struct_elem = 71
    RULE_struct_type = 72
    RULE_constraint_def = 73
    RULE_constraint_named_def = 74
    RULE_constraint_anon_def = 75
    RULE_constraint_body = 76
    RULE_constraint_body_elem = 77
    RULE_constraint_insts = 78
    RULE_constr_relational = 79
    RULE_constr_prop_assign = 80
    RULE_constr_inside_values = 81
    RULE_constr_inside_enum = 82
    RULE_constr_lhs = 83
    RULE_constr_inside_value = 84

    ruleNames =  [ "root", "eval_expr_root", "root_elem", "component_def", 
                   "explicit_component_inst", "component_inst_alias", "component_named_def", 
                   "component_anon_def", "component_body", "component_body_elem", 
                   "component_insts", "component_inst", "field_inst_reset", 
                   "inst_addr_fixed", "inst_addr_stride", "inst_addr_align", 
                   "component_inst_type", "component_type", "component_type_primary", 
                   "param_def", "param_def_elem", "param_inst", "param_assignment", 
                   "expr", "expr_primary", "concatenate", "replicate", "paren_expr", 
                   "cast", "cast_width_expr", "range_suffix", "array_suffix", 
                   "array_type_suffix", "data_type", "basic_data_type", 
                   "literal", "number", "string_literal", "boolean_literal", 
                   "array_literal", "struct_literal", "struct_kv", "enum_literal", 
                   "accesstype_literal", "onreadtype_literal", "onwritetype_literal", 
                   "addressingtype_literal", "precedencetype_literal", "instance_ref", 
                   "instance_ref_element", "prop_ref", "local_property_assignment", 
                   "dynamic_property_assignment", "normal_prop_assign", 
                   "encode_prop_assign", "prop_mod_assign", "prop_assignment_rhs", 
                   "prop_keyword", "prop_mod", "udp_def", "udp_attr", "udp_type", 
                   "udp_data_type", "udp_usage", "udp_comp_type", "udp_default", 
                   "udp_constraint", "enum_def", "enum_entry", "enum_prop_assign", 
                   "struct_def", "struct_elem", "struct_type", "constraint_def", 
                   "constraint_named_def", "constraint_anon_def", "constraint_body", 
                   "constraint_body_elem", "constraint_insts", "constr_relational", 
                   "constr_prop_assign", "constr_inside_values", "constr_inside_enum", 
                   "constr_lhs", "constr_inside_value" ]

    EOF = Token.EOF
    T__0=1
    T__1=2
    T__2=3
    T__3=4
    T__4=5
    T__5=6
    T__6=7
    T__7=8
    T__8=9
    T__9=10
    T__10=11
    T__11=12
    T__12=13
    T__13=14
    T__14=15
    SL_COMMENT=16
    ML_COMMENT=17
    BOOLEAN_kw=18
    BIT_kw=19
    LONGINT_kw=20
    UNSIGNED_kw=21
    STRING_kw=22
    ACCESSTYPE_kw=23
    ADDRESSINGTYPE_kw=24
    ONREADTYPE_kw=25
    ONWRITETYPE_kw=26
    ALIAS_kw=27
    EXTERNAL_kw=28
    INTERNAL_kw=29
    ADDRMAP_kw=30
    REGFILE_kw=31
    REG_kw=32
    FIELD_kw=33
    MEM_kw=34
    SIGNAL_kw=35
    TRUE_kw=36
    FALSE_kw=37
    NA_kw=38
    RW_kw=39
    WR_kw=40
    R_kw=41
    W_kw=42
    RW1_kw=43
    W1_kw=44
    RCLR_kw=45
    RSET_kw=46
    RUSER_kw=47
    WOSET_kw=48
    WOCLR_kw=49
    WOT_kw=50
    WZS_kw=51
    WZC_kw=52
    WZT_kw=53
    WCLR_kw=54
    WSET_kw=55
    WUSER_kw=56
    COMPACT_kw=57
    REGALIGN_kw=58
    FULLALIGN_kw=59
    HW_kw=60
    SW_kw=61
    POSEDGE_kw=62
    NEGEDGE_kw=63
    BOTHEDGE_kw=64
    LEVEL_kw=65
    NONSTICKY_kw=66
    ABSTRACT_kw=67
    ALL_kw=68
    COMPONENT_kw=69
    COMPONENTWIDTH_kw=70
    CONSTRAINT_kw=71
    DEFAULT_kw=72
    ENUM_kw=73
    ENCODE_kw=74
    INSIDE_kw=75
    NUMBER_kw=76
    PROPERTY_kw=77
    REF_kw=78
    STRUCT_kw=79
    THIS_kw=80
    TYPE_kw=81
    ALTERNATE_kw=82
    BYTE_kw=83
    INT_kw=84
    PRECEDENCETYPE_kw=85
    REAL_kw=86
    SHORTINT_kw=87
    SHORTREAL_kw=88
    SIGNED_kw=89
    WITH_kw=90
    WITHIN_kw=91
    INT=92
    HEX_INT=93
    VLOG_INT=94
    STRING=95
    PLUS=96
    MINUS=97
    BNOT=98
    NOT=99
    BAND=100
    NAND=101
    AND=102
    OR=103
    BOR=104
    NOR=105
    XOR=106
    XNOR=107
    LSHIFT=108
    RSHIFT=109
    MULT=110
    EXP=111
    DIV=112
    MOD=113
    EQ=114
    ASSIGN=115
    NEQ=116
    LEQ=117
    LT=118
    GEQ=119
    GT=120
    AT=121
    INC=122
    ALIGN=123
    WS=124
    ID=125

    def __init__(self, input:TokenStream, output:TextIO = sys.stdout):
        super().__init__(input, output)
        self.checkVersion("4.13.1")
        self._interp = ParserATNSimulator(self, self.atn, self.decisionsToDFA, self.sharedContextCache)
        self._predicates = None




    class RootContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def EOF(self):
            return self.getToken(SystemRDLParser.EOF, 0)

        def root_elem(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Root_elemContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Root_elemContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_root

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitRoot" ):
                return visitor.visitRoot(self)
            else:
                return visitor.visitChildren(self)




    def root(self):

        localctx = SystemRDLParser.RootContext(self, self._ctx, self.state)
        self.enterRule(localctx, 0, self.RULE_root)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 175
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while (((_la) & ~0x3f) == 0 and ((1 << _la) & -1151971457975189504) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & 2305843009213736847) != 0):
                self.state = 170
                self.root_elem()
                self.state = 171
                self.match(SystemRDLParser.T__0)
                self.state = 177
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 178
            self.match(SystemRDLParser.EOF)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Eval_expr_rootContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def EOF(self):
            return self.getToken(SystemRDLParser.EOF, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_eval_expr_root

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEval_expr_root" ):
                return visitor.visitEval_expr_root(self)
            else:
                return visitor.visitChildren(self)




    def eval_expr_root(self):

        localctx = SystemRDLParser.Eval_expr_rootContext(self, self._ctx, self.state)
        self.enterRule(localctx, 2, self.RULE_eval_expr_root)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 180
            self.expr(0)
            self.state = 181
            self.match(SystemRDLParser.EOF)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Root_elemContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_defContext,0)


        def enum_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Enum_defContext,0)


        def udp_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_defContext,0)


        def struct_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Struct_defContext,0)


        def constraint_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_defContext,0)


        def explicit_component_inst(self):
            return self.getTypedRuleContext(SystemRDLParser.Explicit_component_instContext,0)


        def local_property_assignment(self):
            return self.getTypedRuleContext(SystemRDLParser.Local_property_assignmentContext,0)


        def dynamic_property_assignment(self):
            return self.getTypedRuleContext(SystemRDLParser.Dynamic_property_assignmentContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_root_elem

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitRoot_elem" ):
                return visitor.visitRoot_elem(self)
            else:
                return visitor.visitChildren(self)




    def root_elem(self):

        localctx = SystemRDLParser.Root_elemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 4, self.RULE_root_elem)
        try:
            self.state = 191
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,1,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 183
                self.component_def()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 184
                self.enum_def()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 185
                self.udp_def()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 186
                self.struct_def()
                pass

            elif la_ == 5:
                self.enterOuterAlt(localctx, 5)
                self.state = 187
                self.constraint_def()
                pass

            elif la_ == 6:
                self.enterOuterAlt(localctx, 6)
                self.state = 188
                self.explicit_component_inst()
                pass

            elif la_ == 7:
                self.enterOuterAlt(localctx, 7)
                self.state = 189
                self.local_property_assignment()
                pass

            elif la_ == 8:
                self.enterOuterAlt(localctx, 8)
                self.state = 190
                self.dynamic_property_assignment()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_named_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_named_defContext,0)


        def component_inst_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_inst_typeContext,0)


        def component_insts(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_instsContext,0)


        def component_anon_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_anon_defContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_def" ):
                return visitor.visitComponent_def(self)
            else:
                return visitor.visitChildren(self)




    def component_def(self):

        localctx = SystemRDLParser.Component_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 6, self.RULE_component_def)
        self._la = 0 # Token type
        try:
            self.state = 217
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,5,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 193
                self.component_named_def()
                self.state = 200
                self._errHandler.sync(self)
                token = self._input.LA(1)
                if token in [28, 29]:
                    self.state = 194
                    self.component_inst_type()
                    self.state = 195
                    self.component_insts()
                    pass
                elif token in [1, 5, 125]:
                    self.state = 198
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==5 or _la==125:
                        self.state = 197
                        self.component_insts()


                    pass
                else:
                    raise NoViableAltException(self)

                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 202
                self.component_anon_def()
                self.state = 207
                self._errHandler.sync(self)
                token = self._input.LA(1)
                if token in [28, 29]:
                    self.state = 203
                    self.component_inst_type()
                    self.state = 204
                    self.component_insts()
                    pass
                elif token in [5, 125]:
                    self.state = 206
                    self.component_insts()
                    pass
                else:
                    raise NoViableAltException(self)

                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 209
                self.component_inst_type()
                self.state = 210
                self.component_named_def()
                self.state = 211
                self.component_insts()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 213
                self.component_inst_type()
                self.state = 214
                self.component_anon_def()
                self.state = 215
                self.component_insts()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Explicit_component_instContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def component_insts(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_instsContext,0)


        def component_inst_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_inst_typeContext,0)


        def component_inst_alias(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_inst_aliasContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_explicit_component_inst

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitExplicit_component_inst" ):
                return visitor.visitExplicit_component_inst(self)
            else:
                return visitor.visitChildren(self)




    def explicit_component_inst(self):

        localctx = SystemRDLParser.Explicit_component_instContext(self, self._ctx, self.state)
        self.enterRule(localctx, 8, self.RULE_explicit_component_inst)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 220
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==28 or _la==29:
                self.state = 219
                self.component_inst_type()


            self.state = 223
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==27:
                self.state = 222
                self.component_inst_alias()


            self.state = 225
            self.match(SystemRDLParser.ID)
            self.state = 226
            self.component_insts()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_inst_aliasContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ALIAS_kw(self):
            return self.getToken(SystemRDLParser.ALIAS_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_inst_alias

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_inst_alias" ):
                return visitor.visitComponent_inst_alias(self)
            else:
                return visitor.visitChildren(self)




    def component_inst_alias(self):

        localctx = SystemRDLParser.Component_inst_aliasContext(self, self._ctx, self.state)
        self.enterRule(localctx, 10, self.RULE_component_inst_alias)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 228
            self.match(SystemRDLParser.ALIAS_kw)
            self.state = 229
            self.match(SystemRDLParser.ID)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_named_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_typeContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def component_body(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_bodyContext,0)


        def param_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Param_defContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_named_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_named_def" ):
                return visitor.visitComponent_named_def(self)
            else:
                return visitor.visitChildren(self)




    def component_named_def(self):

        localctx = SystemRDLParser.Component_named_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 12, self.RULE_component_named_def)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 231
            self.component_type()
            self.state = 232
            self.match(SystemRDLParser.ID)
            self.state = 234
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==5:
                self.state = 233
                self.param_def()


            self.state = 236
            self.component_body()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_anon_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_typeContext,0)


        def component_body(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_bodyContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_anon_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_anon_def" ):
                return visitor.visitComponent_anon_def(self)
            else:
                return visitor.visitChildren(self)




    def component_anon_def(self):

        localctx = SystemRDLParser.Component_anon_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 14, self.RULE_component_anon_def)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 238
            self.component_type()
            self.state = 239
            self.component_body()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_bodyContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_body_elem(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Component_body_elemContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Component_body_elemContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_body

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_body" ):
                return visitor.visitComponent_body(self)
            else:
                return visitor.visitChildren(self)




    def component_body(self):

        localctx = SystemRDLParser.Component_bodyContext(self, self._ctx, self.state)
        self.enterRule(localctx, 16, self.RULE_component_body)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 241
            self.match(SystemRDLParser.T__1)
            self.state = 247
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while (((_la) & ~0x3f) == 0 and ((1 << _la) & -1151971457975189504) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & 2305843009213728655) != 0):
                self.state = 242
                self.component_body_elem()
                self.state = 243
                self.match(SystemRDLParser.T__0)
                self.state = 249
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 250
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_body_elemContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_defContext,0)


        def enum_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Enum_defContext,0)


        def struct_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Struct_defContext,0)


        def constraint_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_defContext,0)


        def explicit_component_inst(self):
            return self.getTypedRuleContext(SystemRDLParser.Explicit_component_instContext,0)


        def local_property_assignment(self):
            return self.getTypedRuleContext(SystemRDLParser.Local_property_assignmentContext,0)


        def dynamic_property_assignment(self):
            return self.getTypedRuleContext(SystemRDLParser.Dynamic_property_assignmentContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_body_elem

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_body_elem" ):
                return visitor.visitComponent_body_elem(self)
            else:
                return visitor.visitChildren(self)




    def component_body_elem(self):

        localctx = SystemRDLParser.Component_body_elemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 18, self.RULE_component_body_elem)
        try:
            self.state = 259
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,10,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 252
                self.component_def()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 253
                self.enum_def()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 254
                self.struct_def()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 255
                self.constraint_def()
                pass

            elif la_ == 5:
                self.enterOuterAlt(localctx, 5)
                self.state = 256
                self.explicit_component_inst()
                pass

            elif la_ == 6:
                self.enterOuterAlt(localctx, 6)
                self.state = 257
                self.local_property_assignment()
                pass

            elif la_ == 7:
                self.enterOuterAlt(localctx, 7)
                self.state = 258
                self.dynamic_property_assignment()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_instsContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def component_inst(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Component_instContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Component_instContext,i)


        def param_inst(self):
            return self.getTypedRuleContext(SystemRDLParser.Param_instContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_insts

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_insts" ):
                return visitor.visitComponent_insts(self)
            else:
                return visitor.visitChildren(self)




    def component_insts(self):

        localctx = SystemRDLParser.Component_instsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 20, self.RULE_component_insts)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 262
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==5:
                self.state = 261
                self.param_inst()


            self.state = 264
            self.component_inst()
            self.state = 269
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 265
                self.match(SystemRDLParser.T__3)
                self.state = 266
                self.component_inst()
                self.state = 271
                self._errHandler.sync(self)
                _la = self._input.LA(1)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_instContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def range_suffix(self):
            return self.getTypedRuleContext(SystemRDLParser.Range_suffixContext,0)


        def field_inst_reset(self):
            return self.getTypedRuleContext(SystemRDLParser.Field_inst_resetContext,0)


        def inst_addr_fixed(self):
            return self.getTypedRuleContext(SystemRDLParser.Inst_addr_fixedContext,0)


        def inst_addr_stride(self):
            return self.getTypedRuleContext(SystemRDLParser.Inst_addr_strideContext,0)


        def inst_addr_align(self):
            return self.getTypedRuleContext(SystemRDLParser.Inst_addr_alignContext,0)


        def array_suffix(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Array_suffixContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Array_suffixContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_inst

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_inst" ):
                return visitor.visitComponent_inst(self)
            else:
                return visitor.visitChildren(self)




    def component_inst(self):

        localctx = SystemRDLParser.Component_instContext(self, self._ctx, self.state)
        self.enterRule(localctx, 22, self.RULE_component_inst)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 272
            self.match(SystemRDLParser.ID)
            self.state = 279
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,14,self._ctx)
            if la_ == 1:
                self.state = 274 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while True:
                    self.state = 273
                    self.array_suffix()
                    self.state = 276 
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if not (_la==12):
                        break


            elif la_ == 2:
                self.state = 278
                self.range_suffix()


            self.state = 282
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==115:
                self.state = 281
                self.field_inst_reset()


            self.state = 285
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==121:
                self.state = 284
                self.inst_addr_fixed()


            self.state = 288
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==122:
                self.state = 287
                self.inst_addr_stride()


            self.state = 291
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==123:
                self.state = 290
                self.inst_addr_align()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Field_inst_resetContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.op = None # Token

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_field_inst_reset

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitField_inst_reset" ):
                return visitor.visitField_inst_reset(self)
            else:
                return visitor.visitChildren(self)




    def field_inst_reset(self):

        localctx = SystemRDLParser.Field_inst_resetContext(self, self._ctx, self.state)
        self.enterRule(localctx, 24, self.RULE_field_inst_reset)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 293
            localctx.op = self.match(SystemRDLParser.ASSIGN)
            self.state = 294
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Inst_addr_fixedContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.op = None # Token

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def AT(self):
            return self.getToken(SystemRDLParser.AT, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_inst_addr_fixed

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitInst_addr_fixed" ):
                return visitor.visitInst_addr_fixed(self)
            else:
                return visitor.visitChildren(self)




    def inst_addr_fixed(self):

        localctx = SystemRDLParser.Inst_addr_fixedContext(self, self._ctx, self.state)
        self.enterRule(localctx, 26, self.RULE_inst_addr_fixed)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 296
            localctx.op = self.match(SystemRDLParser.AT)
            self.state = 297
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Inst_addr_strideContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.op = None # Token

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def INC(self):
            return self.getToken(SystemRDLParser.INC, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_inst_addr_stride

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitInst_addr_stride" ):
                return visitor.visitInst_addr_stride(self)
            else:
                return visitor.visitChildren(self)




    def inst_addr_stride(self):

        localctx = SystemRDLParser.Inst_addr_strideContext(self, self._ctx, self.state)
        self.enterRule(localctx, 28, self.RULE_inst_addr_stride)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 299
            localctx.op = self.match(SystemRDLParser.INC)
            self.state = 300
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Inst_addr_alignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.op = None # Token

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def ALIGN(self):
            return self.getToken(SystemRDLParser.ALIGN, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_inst_addr_align

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitInst_addr_align" ):
                return visitor.visitInst_addr_align(self)
            else:
                return visitor.visitChildren(self)




    def inst_addr_align(self):

        localctx = SystemRDLParser.Inst_addr_alignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 30, self.RULE_inst_addr_align)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 302
            localctx.op = self.match(SystemRDLParser.ALIGN)
            self.state = 303
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_inst_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def EXTERNAL_kw(self):
            return self.getToken(SystemRDLParser.EXTERNAL_kw, 0)

        def INTERNAL_kw(self):
            return self.getToken(SystemRDLParser.INTERNAL_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_inst_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_inst_type" ):
                return visitor.visitComponent_inst_type(self)
            else:
                return visitor.visitChildren(self)




    def component_inst_type(self):

        localctx = SystemRDLParser.Component_inst_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 32, self.RULE_component_inst_type)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 305
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not(_la==28 or _la==29):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def component_type_primary(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_type_primaryContext,0)


        def SIGNAL_kw(self):
            return self.getToken(SystemRDLParser.SIGNAL_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_type" ):
                return visitor.visitComponent_type(self)
            else:
                return visitor.visitChildren(self)




    def component_type(self):

        localctx = SystemRDLParser.Component_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 34, self.RULE_component_type)
        try:
            self.state = 309
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [30, 31, 32, 33, 34]:
                self.enterOuterAlt(localctx, 1)
                self.state = 307
                self.component_type_primary()
                pass
            elif token in [35]:
                self.enterOuterAlt(localctx, 2)
                self.state = 308
                localctx.kw = self.match(SystemRDLParser.SIGNAL_kw)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Component_type_primaryContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def ADDRMAP_kw(self):
            return self.getToken(SystemRDLParser.ADDRMAP_kw, 0)

        def REGFILE_kw(self):
            return self.getToken(SystemRDLParser.REGFILE_kw, 0)

        def REG_kw(self):
            return self.getToken(SystemRDLParser.REG_kw, 0)

        def FIELD_kw(self):
            return self.getToken(SystemRDLParser.FIELD_kw, 0)

        def MEM_kw(self):
            return self.getToken(SystemRDLParser.MEM_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_component_type_primary

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitComponent_type_primary" ):
                return visitor.visitComponent_type_primary(self)
            else:
                return visitor.visitChildren(self)




    def component_type_primary(self):

        localctx = SystemRDLParser.Component_type_primaryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 36, self.RULE_component_type_primary)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 311
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 33285996544) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Param_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def param_def_elem(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Param_def_elemContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Param_def_elemContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_param_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitParam_def" ):
                return visitor.visitParam_def(self)
            else:
                return visitor.visitChildren(self)




    def param_def(self):

        localctx = SystemRDLParser.Param_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 38, self.RULE_param_def)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 313
            self.match(SystemRDLParser.T__4)
            self.state = 314
            self.match(SystemRDLParser.T__5)
            self.state = 315
            self.param_def_elem()
            self.state = 320
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 316
                self.match(SystemRDLParser.T__3)
                self.state = 317
                self.param_def_elem()
                self.state = 322
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 323
            self.match(SystemRDLParser.T__6)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Param_def_elemContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def data_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Data_typeContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def array_type_suffix(self):
            return self.getTypedRuleContext(SystemRDLParser.Array_type_suffixContext,0)


        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_param_def_elem

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitParam_def_elem" ):
                return visitor.visitParam_def_elem(self)
            else:
                return visitor.visitChildren(self)




    def param_def_elem(self):

        localctx = SystemRDLParser.Param_def_elemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 40, self.RULE_param_def_elem)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 325
            self.data_type()
            self.state = 326
            self.match(SystemRDLParser.ID)
            self.state = 328
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==12:
                self.state = 327
                self.array_type_suffix()


            self.state = 332
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==115:
                self.state = 330
                self.match(SystemRDLParser.ASSIGN)
                self.state = 331
                self.expr(0)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Param_instContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def param_assignment(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Param_assignmentContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Param_assignmentContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_param_inst

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitParam_inst" ):
                return visitor.visitParam_inst(self)
            else:
                return visitor.visitChildren(self)




    def param_inst(self):

        localctx = SystemRDLParser.Param_instContext(self, self._ctx, self.state)
        self.enterRule(localctx, 42, self.RULE_param_inst)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 334
            self.match(SystemRDLParser.T__4)
            self.state = 335
            self.match(SystemRDLParser.T__5)
            self.state = 336
            self.param_assignment()
            self.state = 341
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 337
                self.match(SystemRDLParser.T__3)
                self.state = 338
                self.param_assignment()
                self.state = 343
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 344
            self.match(SystemRDLParser.T__6)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Param_assignmentContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_param_assignment

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitParam_assignment" ):
                return visitor.visitParam_assignment(self)
            else:
                return visitor.visitChildren(self)




    def param_assignment(self):

        localctx = SystemRDLParser.Param_assignmentContext(self, self._ctx, self.state)
        self.enterRule(localctx, 44, self.RULE_param_assignment)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 346
            self.match(SystemRDLParser.T__7)
            self.state = 347
            self.match(SystemRDLParser.ID)
            self.state = 348
            self.match(SystemRDLParser.T__5)
            self.state = 349
            self.expr(0)
            self.state = 350
            self.match(SystemRDLParser.T__6)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class ExprContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SystemRDLParser.RULE_expr

     
        def copyFrom(self, ctx:ParserRuleContext):
            super().copyFrom(ctx)


    class BinaryExprContext(ExprContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.ExprContext
            super().__init__(parser)
            self.op = None # Token
            self.copyFrom(ctx)

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)

        def EXP(self):
            return self.getToken(SystemRDLParser.EXP, 0)
        def MULT(self):
            return self.getToken(SystemRDLParser.MULT, 0)
        def DIV(self):
            return self.getToken(SystemRDLParser.DIV, 0)
        def MOD(self):
            return self.getToken(SystemRDLParser.MOD, 0)
        def PLUS(self):
            return self.getToken(SystemRDLParser.PLUS, 0)
        def MINUS(self):
            return self.getToken(SystemRDLParser.MINUS, 0)
        def LSHIFT(self):
            return self.getToken(SystemRDLParser.LSHIFT, 0)
        def RSHIFT(self):
            return self.getToken(SystemRDLParser.RSHIFT, 0)
        def LT(self):
            return self.getToken(SystemRDLParser.LT, 0)
        def LEQ(self):
            return self.getToken(SystemRDLParser.LEQ, 0)
        def GT(self):
            return self.getToken(SystemRDLParser.GT, 0)
        def GEQ(self):
            return self.getToken(SystemRDLParser.GEQ, 0)
        def EQ(self):
            return self.getToken(SystemRDLParser.EQ, 0)
        def NEQ(self):
            return self.getToken(SystemRDLParser.NEQ, 0)
        def AND(self):
            return self.getToken(SystemRDLParser.AND, 0)
        def XOR(self):
            return self.getToken(SystemRDLParser.XOR, 0)
        def XNOR(self):
            return self.getToken(SystemRDLParser.XNOR, 0)
        def OR(self):
            return self.getToken(SystemRDLParser.OR, 0)
        def BAND(self):
            return self.getToken(SystemRDLParser.BAND, 0)
        def BOR(self):
            return self.getToken(SystemRDLParser.BOR, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitBinaryExpr" ):
                return visitor.visitBinaryExpr(self)
            else:
                return visitor.visitChildren(self)


    class UnaryExprContext(ExprContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.ExprContext
            super().__init__(parser)
            self.op = None # Token
            self.copyFrom(ctx)

        def expr_primary(self):
            return self.getTypedRuleContext(SystemRDLParser.Expr_primaryContext,0)

        def PLUS(self):
            return self.getToken(SystemRDLParser.PLUS, 0)
        def MINUS(self):
            return self.getToken(SystemRDLParser.MINUS, 0)
        def BNOT(self):
            return self.getToken(SystemRDLParser.BNOT, 0)
        def NOT(self):
            return self.getToken(SystemRDLParser.NOT, 0)
        def AND(self):
            return self.getToken(SystemRDLParser.AND, 0)
        def NAND(self):
            return self.getToken(SystemRDLParser.NAND, 0)
        def OR(self):
            return self.getToken(SystemRDLParser.OR, 0)
        def NOR(self):
            return self.getToken(SystemRDLParser.NOR, 0)
        def XOR(self):
            return self.getToken(SystemRDLParser.XOR, 0)
        def XNOR(self):
            return self.getToken(SystemRDLParser.XNOR, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUnaryExpr" ):
                return visitor.visitUnaryExpr(self)
            else:
                return visitor.visitChildren(self)


    class NOPContext(ExprContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.ExprContext
            super().__init__(parser)
            self.copyFrom(ctx)

        def expr_primary(self):
            return self.getTypedRuleContext(SystemRDLParser.Expr_primaryContext,0)


        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitNOP" ):
                return visitor.visitNOP(self)
            else:
                return visitor.visitChildren(self)


    class TernaryExprContext(ExprContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.ExprContext
            super().__init__(parser)
            self.op = None # Token
            self.copyFrom(ctx)

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitTernaryExpr" ):
                return visitor.visitTernaryExpr(self)
            else:
                return visitor.visitChildren(self)



    def expr(self, _p:int=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SystemRDLParser.ExprContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 46
        self.enterRecursionRule(localctx, 46, self.RULE_expr, _p)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 356
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [96, 97, 98, 99, 101, 102, 103, 105, 106, 107]:
                localctx = SystemRDLParser.UnaryExprContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx

                self.state = 353
                localctx.op = self._input.LT(1)
                _la = self._input.LA(1)
                if not(((((_la - 96)) & ~0x3f) == 0 and ((1 << (_la - 96)) & 3823) != 0)):
                    localctx.op = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 354
                self.expr_primary()
                pass
            elif token in [2, 6, 11, 18, 19, 20, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 92, 93, 94, 95, 125]:
                localctx = SystemRDLParser.NOPContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 355
                self.expr_primary()
                pass
            else:
                raise NoViableAltException(self)

            self._ctx.stop = self._input.LT(-1)
            self.state = 399
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,26,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    self.state = 397
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,25,self._ctx)
                    if la_ == 1:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 358
                        if not self.precpred(self._ctx, 13):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 13)")
                        self.state = 359
                        localctx.op = self.match(SystemRDLParser.EXP)
                        self.state = 360
                        self.expr(14)
                        pass

                    elif la_ == 2:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 361
                        if not self.precpred(self._ctx, 12):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 12)")
                        self.state = 362
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(((((_la - 110)) & ~0x3f) == 0 and ((1 << (_la - 110)) & 13) != 0)):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 363
                        self.expr(13)
                        pass

                    elif la_ == 3:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 364
                        if not self.precpred(self._ctx, 11):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 11)")
                        self.state = 365
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==96 or _la==97):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 366
                        self.expr(12)
                        pass

                    elif la_ == 4:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 367
                        if not self.precpred(self._ctx, 10):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 10)")
                        self.state = 368
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==108 or _la==109):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 369
                        self.expr(11)
                        pass

                    elif la_ == 5:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 370
                        if not self.precpred(self._ctx, 9):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 9)")
                        self.state = 371
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(((((_la - 117)) & ~0x3f) == 0 and ((1 << (_la - 117)) & 15) != 0)):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 372
                        self.expr(10)
                        pass

                    elif la_ == 6:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 373
                        if not self.precpred(self._ctx, 8):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 8)")
                        self.state = 374
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==114 or _la==116):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 375
                        self.expr(9)
                        pass

                    elif la_ == 7:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 376
                        if not self.precpred(self._ctx, 7):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 7)")
                        self.state = 377
                        localctx.op = self.match(SystemRDLParser.AND)
                        self.state = 378
                        self.expr(8)
                        pass

                    elif la_ == 8:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 379
                        if not self.precpred(self._ctx, 6):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 6)")
                        self.state = 380
                        localctx.op = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==106 or _la==107):
                            localctx.op = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 381
                        self.expr(7)
                        pass

                    elif la_ == 9:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 382
                        if not self.precpred(self._ctx, 5):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 5)")
                        self.state = 383
                        localctx.op = self.match(SystemRDLParser.OR)
                        self.state = 384
                        self.expr(6)
                        pass

                    elif la_ == 10:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 385
                        if not self.precpred(self._ctx, 4):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 4)")
                        self.state = 386
                        localctx.op = self.match(SystemRDLParser.BAND)
                        self.state = 387
                        self.expr(5)
                        pass

                    elif la_ == 11:
                        localctx = SystemRDLParser.BinaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 388
                        if not self.precpred(self._ctx, 3):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 3)")
                        self.state = 389
                        localctx.op = self.match(SystemRDLParser.BOR)
                        self.state = 390
                        self.expr(4)
                        pass

                    elif la_ == 12:
                        localctx = SystemRDLParser.TernaryExprContext(self, SystemRDLParser.ExprContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_expr)
                        self.state = 391
                        if not self.precpred(self._ctx, 2):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 2)")
                        self.state = 392
                        localctx.op = self.match(SystemRDLParser.T__8)
                        self.state = 393
                        self.expr(0)
                        self.state = 394
                        self.match(SystemRDLParser.T__9)
                        self.state = 395
                        self.expr(2)
                        pass

             
                self.state = 401
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,26,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx


    class Expr_primaryContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def literal(self):
            return self.getTypedRuleContext(SystemRDLParser.LiteralContext,0)


        def concatenate(self):
            return self.getTypedRuleContext(SystemRDLParser.ConcatenateContext,0)


        def replicate(self):
            return self.getTypedRuleContext(SystemRDLParser.ReplicateContext,0)


        def paren_expr(self):
            return self.getTypedRuleContext(SystemRDLParser.Paren_exprContext,0)


        def cast(self):
            return self.getTypedRuleContext(SystemRDLParser.CastContext,0)


        def prop_ref(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_refContext,0)


        def instance_ref(self):
            return self.getTypedRuleContext(SystemRDLParser.Instance_refContext,0)


        def struct_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Struct_literalContext,0)


        def array_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Array_literalContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_expr_primary

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitExpr_primary" ):
                return visitor.visitExpr_primary(self)
            else:
                return visitor.visitChildren(self)




    def expr_primary(self):

        localctx = SystemRDLParser.Expr_primaryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 48, self.RULE_expr_primary)
        try:
            self.state = 411
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,27,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 402
                self.literal()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 403
                self.concatenate()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 404
                self.replicate()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 405
                self.paren_expr()
                pass

            elif la_ == 5:
                self.enterOuterAlt(localctx, 5)
                self.state = 406
                self.cast()
                pass

            elif la_ == 6:
                self.enterOuterAlt(localctx, 6)
                self.state = 407
                self.prop_ref()
                pass

            elif la_ == 7:
                self.enterOuterAlt(localctx, 7)
                self.state = 408
                self.instance_ref()
                pass

            elif la_ == 8:
                self.enterOuterAlt(localctx, 8)
                self.state = 409
                self.struct_literal()
                pass

            elif la_ == 9:
                self.enterOuterAlt(localctx, 9)
                self.state = 410
                self.array_literal()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class ConcatenateContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_concatenate

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConcatenate" ):
                return visitor.visitConcatenate(self)
            else:
                return visitor.visitChildren(self)




    def concatenate(self):

        localctx = SystemRDLParser.ConcatenateContext(self, self._ctx, self.state)
        self.enterRule(localctx, 50, self.RULE_concatenate)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 413
            self.match(SystemRDLParser.T__1)
            self.state = 414
            self.expr(0)
            self.state = 419
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 415
                self.match(SystemRDLParser.T__3)
                self.state = 416
                self.expr(0)
                self.state = 421
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 422
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class ReplicateContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def concatenate(self):
            return self.getTypedRuleContext(SystemRDLParser.ConcatenateContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_replicate

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitReplicate" ):
                return visitor.visitReplicate(self)
            else:
                return visitor.visitChildren(self)




    def replicate(self):

        localctx = SystemRDLParser.ReplicateContext(self, self._ctx, self.state)
        self.enterRule(localctx, 52, self.RULE_replicate)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 424
            self.match(SystemRDLParser.T__1)
            self.state = 425
            self.expr(0)
            self.state = 426
            self.concatenate()
            self.state = 427
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Paren_exprContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_paren_expr

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitParen_expr" ):
                return visitor.visitParen_expr(self)
            else:
                return visitor.visitChildren(self)




    def paren_expr(self):

        localctx = SystemRDLParser.Paren_exprContext(self, self._ctx, self.state)
        self.enterRule(localctx, 54, self.RULE_paren_expr)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 429
            self.match(SystemRDLParser.T__5)
            self.state = 430
            self.expr(0)
            self.state = 431
            self.match(SystemRDLParser.T__6)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class CastContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SystemRDLParser.RULE_cast

     
        def copyFrom(self, ctx:ParserRuleContext):
            super().copyFrom(ctx)



    class CastWidthContext(CastContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.CastContext
            super().__init__(parser)
            self.op = None # Token
            self.copyFrom(ctx)

        def cast_width_expr(self):
            return self.getTypedRuleContext(SystemRDLParser.Cast_width_exprContext,0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitCastWidth" ):
                return visitor.visitCastWidth(self)
            else:
                return visitor.visitChildren(self)


    class CastTypeContext(CastContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.CastContext
            super().__init__(parser)
            self.typ = None # Token
            self.op = None # Token
            self.copyFrom(ctx)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)

        def BOOLEAN_kw(self):
            return self.getToken(SystemRDLParser.BOOLEAN_kw, 0)
        def BIT_kw(self):
            return self.getToken(SystemRDLParser.BIT_kw, 0)
        def LONGINT_kw(self):
            return self.getToken(SystemRDLParser.LONGINT_kw, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitCastType" ):
                return visitor.visitCastType(self)
            else:
                return visitor.visitChildren(self)



    def cast(self):

        localctx = SystemRDLParser.CastContext(self, self._ctx, self.state)
        self.enterRule(localctx, 56, self.RULE_cast)
        self._la = 0 # Token type
        try:
            self.state = 445
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [18, 19, 20]:
                localctx = SystemRDLParser.CastTypeContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 433
                localctx.typ = self._input.LT(1)
                _la = self._input.LA(1)
                if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 1835008) != 0)):
                    localctx.typ = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 434
                localctx.op = self.match(SystemRDLParser.T__10)
                self.state = 435
                self.match(SystemRDLParser.T__5)
                self.state = 436
                self.expr(0)
                self.state = 437
                self.match(SystemRDLParser.T__6)
                pass
            elif token in [6, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 92, 93, 94, 95, 125]:
                localctx = SystemRDLParser.CastWidthContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 439
                self.cast_width_expr()
                self.state = 440
                localctx.op = self.match(SystemRDLParser.T__10)
                self.state = 441
                self.match(SystemRDLParser.T__5)
                self.state = 442
                self.expr(0)
                self.state = 443
                self.match(SystemRDLParser.T__6)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Cast_width_exprContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def literal(self):
            return self.getTypedRuleContext(SystemRDLParser.LiteralContext,0)


        def paren_expr(self):
            return self.getTypedRuleContext(SystemRDLParser.Paren_exprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_cast_width_expr

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitCast_width_expr" ):
                return visitor.visitCast_width_expr(self)
            else:
                return visitor.visitChildren(self)




    def cast_width_expr(self):

        localctx = SystemRDLParser.Cast_width_exprContext(self, self._ctx, self.state)
        self.enterRule(localctx, 58, self.RULE_cast_width_expr)
        try:
            self.state = 449
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 92, 93, 94, 95, 125]:
                self.enterOuterAlt(localctx, 1)
                self.state = 447
                self.literal()
                pass
            elif token in [6]:
                self.enterOuterAlt(localctx, 2)
                self.state = 448
                self.paren_expr()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Range_suffixContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_range_suffix

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitRange_suffix" ):
                return visitor.visitRange_suffix(self)
            else:
                return visitor.visitChildren(self)




    def range_suffix(self):

        localctx = SystemRDLParser.Range_suffixContext(self, self._ctx, self.state)
        self.enterRule(localctx, 60, self.RULE_range_suffix)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 451
            self.match(SystemRDLParser.T__11)
            self.state = 452
            self.expr(0)
            self.state = 453
            self.match(SystemRDLParser.T__9)
            self.state = 454
            self.expr(0)
            self.state = 455
            self.match(SystemRDLParser.T__12)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Array_suffixContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_array_suffix

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitArray_suffix" ):
                return visitor.visitArray_suffix(self)
            else:
                return visitor.visitChildren(self)




    def array_suffix(self):

        localctx = SystemRDLParser.Array_suffixContext(self, self._ctx, self.state)
        self.enterRule(localctx, 62, self.RULE_array_suffix)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 457
            self.match(SystemRDLParser.T__11)
            self.state = 458
            self.expr(0)
            self.state = 459
            self.match(SystemRDLParser.T__12)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Array_type_suffixContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SystemRDLParser.RULE_array_type_suffix

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitArray_type_suffix" ):
                return visitor.visitArray_type_suffix(self)
            else:
                return visitor.visitChildren(self)




    def array_type_suffix(self):

        localctx = SystemRDLParser.Array_type_suffixContext(self, self._ctx, self.state)
        self.enterRule(localctx, 64, self.RULE_array_type_suffix)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 461
            self.match(SystemRDLParser.T__11)
            self.state = 462
            self.match(SystemRDLParser.T__12)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Data_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def basic_data_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Basic_data_typeContext,0)


        def ACCESSTYPE_kw(self):
            return self.getToken(SystemRDLParser.ACCESSTYPE_kw, 0)

        def ADDRESSINGTYPE_kw(self):
            return self.getToken(SystemRDLParser.ADDRESSINGTYPE_kw, 0)

        def ONREADTYPE_kw(self):
            return self.getToken(SystemRDLParser.ONREADTYPE_kw, 0)

        def ONWRITETYPE_kw(self):
            return self.getToken(SystemRDLParser.ONWRITETYPE_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_data_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitData_type" ):
                return visitor.visitData_type(self)
            else:
                return visitor.visitChildren(self)




    def data_type(self):

        localctx = SystemRDLParser.Data_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 66, self.RULE_data_type)
        self._la = 0 # Token type
        try:
            self.state = 466
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [18, 19, 20, 22, 125]:
                self.enterOuterAlt(localctx, 1)
                self.state = 464
                self.basic_data_type()
                pass
            elif token in [23, 24, 25, 26]:
                self.enterOuterAlt(localctx, 2)
                self.state = 465
                localctx.kw = self._input.LT(1)
                _la = self._input.LA(1)
                if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 125829120) != 0)):
                    localctx.kw = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Basic_data_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def BIT_kw(self):
            return self.getToken(SystemRDLParser.BIT_kw, 0)

        def LONGINT_kw(self):
            return self.getToken(SystemRDLParser.LONGINT_kw, 0)

        def UNSIGNED_kw(self):
            return self.getToken(SystemRDLParser.UNSIGNED_kw, 0)

        def STRING_kw(self):
            return self.getToken(SystemRDLParser.STRING_kw, 0)

        def BOOLEAN_kw(self):
            return self.getToken(SystemRDLParser.BOOLEAN_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_basic_data_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitBasic_data_type" ):
                return visitor.visitBasic_data_type(self)
            else:
                return visitor.visitChildren(self)




    def basic_data_type(self):

        localctx = SystemRDLParser.Basic_data_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 68, self.RULE_basic_data_type)
        self._la = 0 # Token type
        try:
            self.state = 473
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [19, 20]:
                self.enterOuterAlt(localctx, 1)
                self.state = 468
                localctx.kw = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==19 or _la==20):
                    localctx.kw = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 470
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==21:
                    self.state = 469
                    self.match(SystemRDLParser.UNSIGNED_kw)


                pass
            elif token in [18, 22, 125]:
                self.enterOuterAlt(localctx, 2)
                self.state = 472
                localctx.kw = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==18 or _la==22 or _la==125):
                    localctx.kw = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class LiteralContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def number(self):
            return self.getTypedRuleContext(SystemRDLParser.NumberContext,0)


        def string_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.String_literalContext,0)


        def boolean_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Boolean_literalContext,0)


        def accesstype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Accesstype_literalContext,0)


        def onreadtype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Onreadtype_literalContext,0)


        def onwritetype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Onwritetype_literalContext,0)


        def addressingtype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Addressingtype_literalContext,0)


        def precedencetype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Precedencetype_literalContext,0)


        def enum_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Enum_literalContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitLiteral" ):
                return visitor.visitLiteral(self)
            else:
                return visitor.visitChildren(self)




    def literal(self):

        localctx = SystemRDLParser.LiteralContext(self, self._ctx, self.state)
        self.enterRule(localctx, 70, self.RULE_literal)
        try:
            self.state = 484
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [92, 93, 94]:
                self.enterOuterAlt(localctx, 1)
                self.state = 475
                self.number()
                pass
            elif token in [95]:
                self.enterOuterAlt(localctx, 2)
                self.state = 476
                self.string_literal()
                pass
            elif token in [36, 37]:
                self.enterOuterAlt(localctx, 3)
                self.state = 477
                self.boolean_literal()
                pass
            elif token in [38, 39, 40, 41, 42, 43, 44]:
                self.enterOuterAlt(localctx, 4)
                self.state = 478
                self.accesstype_literal()
                pass
            elif token in [45, 46, 47]:
                self.enterOuterAlt(localctx, 5)
                self.state = 479
                self.onreadtype_literal()
                pass
            elif token in [48, 49, 50, 51, 52, 53, 54, 55, 56]:
                self.enterOuterAlt(localctx, 6)
                self.state = 480
                self.onwritetype_literal()
                pass
            elif token in [57, 58, 59]:
                self.enterOuterAlt(localctx, 7)
                self.state = 481
                self.addressingtype_literal()
                pass
            elif token in [60, 61]:
                self.enterOuterAlt(localctx, 8)
                self.state = 482
                self.precedencetype_literal()
                pass
            elif token in [125]:
                self.enterOuterAlt(localctx, 9)
                self.state = 483
                self.enum_literal()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class NumberContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SystemRDLParser.RULE_number

     
        def copyFrom(self, ctx:ParserRuleContext):
            super().copyFrom(ctx)



    class NumberHexContext(NumberContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.NumberContext
            super().__init__(parser)
            self.copyFrom(ctx)

        def HEX_INT(self):
            return self.getToken(SystemRDLParser.HEX_INT, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitNumberHex" ):
                return visitor.visitNumberHex(self)
            else:
                return visitor.visitChildren(self)


    class NumberVerilogContext(NumberContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.NumberContext
            super().__init__(parser)
            self.copyFrom(ctx)

        def VLOG_INT(self):
            return self.getToken(SystemRDLParser.VLOG_INT, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitNumberVerilog" ):
                return visitor.visitNumberVerilog(self)
            else:
                return visitor.visitChildren(self)


    class NumberIntContext(NumberContext):

        def __init__(self, parser, ctx:ParserRuleContext): # actually a SystemRDLParser.NumberContext
            super().__init__(parser)
            self.copyFrom(ctx)

        def INT(self):
            return self.getToken(SystemRDLParser.INT, 0)

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitNumberInt" ):
                return visitor.visitNumberInt(self)
            else:
                return visitor.visitChildren(self)



    def number(self):

        localctx = SystemRDLParser.NumberContext(self, self._ctx, self.state)
        self.enterRule(localctx, 72, self.RULE_number)
        try:
            self.state = 489
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [92]:
                localctx = SystemRDLParser.NumberIntContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 486
                self.match(SystemRDLParser.INT)
                pass
            elif token in [93]:
                localctx = SystemRDLParser.NumberHexContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 487
                self.match(SystemRDLParser.HEX_INT)
                pass
            elif token in [94]:
                localctx = SystemRDLParser.NumberVerilogContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 488
                self.match(SystemRDLParser.VLOG_INT)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class String_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def STRING(self):
            return self.getToken(SystemRDLParser.STRING, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_string_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitString_literal" ):
                return visitor.visitString_literal(self)
            else:
                return visitor.visitChildren(self)




    def string_literal(self):

        localctx = SystemRDLParser.String_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 74, self.RULE_string_literal)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 491
            self.match(SystemRDLParser.STRING)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Boolean_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.val = None # Token

        def TRUE_kw(self):
            return self.getToken(SystemRDLParser.TRUE_kw, 0)

        def FALSE_kw(self):
            return self.getToken(SystemRDLParser.FALSE_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_boolean_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitBoolean_literal" ):
                return visitor.visitBoolean_literal(self)
            else:
                return visitor.visitChildren(self)




    def boolean_literal(self):

        localctx = SystemRDLParser.Boolean_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 76, self.RULE_boolean_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 493
            localctx.val = self._input.LT(1)
            _la = self._input.LA(1)
            if not(_la==36 or _la==37):
                localctx.val = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Array_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_array_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitArray_literal" ):
                return visitor.visitArray_literal(self)
            else:
                return visitor.visitChildren(self)




    def array_literal(self):

        localctx = SystemRDLParser.Array_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 78, self.RULE_array_literal)
        self._la = 0 # Token type
        try:
            self.state = 510
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,37,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 495
                self.match(SystemRDLParser.T__10)
                self.state = 496
                self.match(SystemRDLParser.T__1)
                self.state = 497
                self.match(SystemRDLParser.T__2)
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 498
                self.match(SystemRDLParser.T__10)
                self.state = 499
                self.match(SystemRDLParser.T__1)
                self.state = 500
                self.expr(0)
                self.state = 505
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==4:
                    self.state = 501
                    self.match(SystemRDLParser.T__3)
                    self.state = 502
                    self.expr(0)
                    self.state = 507
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 508
                self.match(SystemRDLParser.T__2)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Struct_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def struct_kv(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Struct_kvContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Struct_kvContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_struct_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitStruct_literal" ):
                return visitor.visitStruct_literal(self)
            else:
                return visitor.visitChildren(self)




    def struct_literal(self):

        localctx = SystemRDLParser.Struct_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 80, self.RULE_struct_literal)
        self._la = 0 # Token type
        try:
            self.state = 529
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,39,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 512
                self.match(SystemRDLParser.ID)
                self.state = 513
                self.match(SystemRDLParser.T__10)
                self.state = 514
                self.match(SystemRDLParser.T__1)
                self.state = 515
                self.match(SystemRDLParser.T__2)
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 516
                self.match(SystemRDLParser.ID)
                self.state = 517
                self.match(SystemRDLParser.T__10)
                self.state = 518
                self.match(SystemRDLParser.T__1)
                self.state = 519
                self.struct_kv()
                self.state = 524
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==4:
                    self.state = 520
                    self.match(SystemRDLParser.T__3)
                    self.state = 521
                    self.struct_kv()
                    self.state = 526
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 527
                self.match(SystemRDLParser.T__2)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Struct_kvContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_struct_kv

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitStruct_kv" ):
                return visitor.visitStruct_kv(self)
            else:
                return visitor.visitChildren(self)




    def struct_kv(self):

        localctx = SystemRDLParser.Struct_kvContext(self, self._ctx, self.state)
        self.enterRule(localctx, 82, self.RULE_struct_kv)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 531
            self.match(SystemRDLParser.ID)
            self.state = 532
            self.match(SystemRDLParser.T__9)
            self.state = 533
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Enum_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self, i:int=None):
            if i is None:
                return self.getTokens(SystemRDLParser.ID)
            else:
                return self.getToken(SystemRDLParser.ID, i)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_enum_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEnum_literal" ):
                return visitor.visitEnum_literal(self)
            else:
                return visitor.visitChildren(self)




    def enum_literal(self):

        localctx = SystemRDLParser.Enum_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 84, self.RULE_enum_literal)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 535
            self.match(SystemRDLParser.ID)
            self.state = 536
            self.match(SystemRDLParser.T__13)
            self.state = 537
            self.match(SystemRDLParser.ID)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Accesstype_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def NA_kw(self):
            return self.getToken(SystemRDLParser.NA_kw, 0)

        def RW_kw(self):
            return self.getToken(SystemRDLParser.RW_kw, 0)

        def WR_kw(self):
            return self.getToken(SystemRDLParser.WR_kw, 0)

        def R_kw(self):
            return self.getToken(SystemRDLParser.R_kw, 0)

        def W_kw(self):
            return self.getToken(SystemRDLParser.W_kw, 0)

        def RW1_kw(self):
            return self.getToken(SystemRDLParser.RW1_kw, 0)

        def W1_kw(self):
            return self.getToken(SystemRDLParser.W1_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_accesstype_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitAccesstype_literal" ):
                return visitor.visitAccesstype_literal(self)
            else:
                return visitor.visitChildren(self)




    def accesstype_literal(self):

        localctx = SystemRDLParser.Accesstype_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 86, self.RULE_accesstype_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 539
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 34909494181888) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Onreadtype_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def RCLR_kw(self):
            return self.getToken(SystemRDLParser.RCLR_kw, 0)

        def RSET_kw(self):
            return self.getToken(SystemRDLParser.RSET_kw, 0)

        def RUSER_kw(self):
            return self.getToken(SystemRDLParser.RUSER_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_onreadtype_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitOnreadtype_literal" ):
                return visitor.visitOnreadtype_literal(self)
            else:
                return visitor.visitChildren(self)




    def onreadtype_literal(self):

        localctx = SystemRDLParser.Onreadtype_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 88, self.RULE_onreadtype_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 541
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 246290604621824) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Onwritetype_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def WOSET_kw(self):
            return self.getToken(SystemRDLParser.WOSET_kw, 0)

        def WOCLR_kw(self):
            return self.getToken(SystemRDLParser.WOCLR_kw, 0)

        def WOT_kw(self):
            return self.getToken(SystemRDLParser.WOT_kw, 0)

        def WZS_kw(self):
            return self.getToken(SystemRDLParser.WZS_kw, 0)

        def WZC_kw(self):
            return self.getToken(SystemRDLParser.WZC_kw, 0)

        def WZT_kw(self):
            return self.getToken(SystemRDLParser.WZT_kw, 0)

        def WCLR_kw(self):
            return self.getToken(SystemRDLParser.WCLR_kw, 0)

        def WSET_kw(self):
            return self.getToken(SystemRDLParser.WSET_kw, 0)

        def WUSER_kw(self):
            return self.getToken(SystemRDLParser.WUSER_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_onwritetype_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitOnwritetype_literal" ):
                return visitor.visitOnwritetype_literal(self)
            else:
                return visitor.visitChildren(self)




    def onwritetype_literal(self):

        localctx = SystemRDLParser.Onwritetype_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 90, self.RULE_onwritetype_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 543
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 143833713099145216) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Addressingtype_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def COMPACT_kw(self):
            return self.getToken(SystemRDLParser.COMPACT_kw, 0)

        def REGALIGN_kw(self):
            return self.getToken(SystemRDLParser.REGALIGN_kw, 0)

        def FULLALIGN_kw(self):
            return self.getToken(SystemRDLParser.FULLALIGN_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_addressingtype_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitAddressingtype_literal" ):
                return visitor.visitAddressingtype_literal(self)
            else:
                return visitor.visitChildren(self)




    def addressingtype_literal(self):

        localctx = SystemRDLParser.Addressingtype_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 92, self.RULE_addressingtype_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 545
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 1008806316530991104) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Precedencetype_literalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def HW_kw(self):
            return self.getToken(SystemRDLParser.HW_kw, 0)

        def SW_kw(self):
            return self.getToken(SystemRDLParser.SW_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_precedencetype_literal

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitPrecedencetype_literal" ):
                return visitor.visitPrecedencetype_literal(self)
            else:
                return visitor.visitChildren(self)




    def precedencetype_literal(self):

        localctx = SystemRDLParser.Precedencetype_literalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 94, self.RULE_precedencetype_literal)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 547
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not(_la==60 or _la==61):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Instance_refContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def instance_ref_element(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Instance_ref_elementContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Instance_ref_elementContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_instance_ref

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitInstance_ref" ):
                return visitor.visitInstance_ref(self)
            else:
                return visitor.visitChildren(self)




    def instance_ref(self):

        localctx = SystemRDLParser.Instance_refContext(self, self._ctx, self.state)
        self.enterRule(localctx, 96, self.RULE_instance_ref)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 549
            self.instance_ref_element()
            self.state = 554
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,40,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 550
                    self.match(SystemRDLParser.T__7)
                    self.state = 551
                    self.instance_ref_element() 
                self.state = 556
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,40,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Instance_ref_elementContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def array_suffix(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Array_suffixContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Array_suffixContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_instance_ref_element

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitInstance_ref_element" ):
                return visitor.visitInstance_ref_element(self)
            else:
                return visitor.visitChildren(self)




    def instance_ref_element(self):

        localctx = SystemRDLParser.Instance_ref_elementContext(self, self._ctx, self.state)
        self.enterRule(localctx, 98, self.RULE_instance_ref_element)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 557
            self.match(SystemRDLParser.ID)
            self.state = 561
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,41,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 558
                    self.array_suffix() 
                self.state = 563
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,41,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Prop_refContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def instance_ref(self):
            return self.getTypedRuleContext(SystemRDLParser.Instance_refContext,0)


        def prop_keyword(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_keywordContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_prop_ref

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitProp_ref" ):
                return visitor.visitProp_ref(self)
            else:
                return visitor.visitChildren(self)




    def prop_ref(self):

        localctx = SystemRDLParser.Prop_refContext(self, self._ctx, self.state)
        self.enterRule(localctx, 100, self.RULE_prop_ref)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 564
            self.instance_ref()
            self.state = 565
            self.match(SystemRDLParser.T__14)
            self.state = 568
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [45, 46, 48, 49, 60, 61]:
                self.state = 566
                self.prop_keyword()
                pass
            elif token in [125]:
                self.state = 567
                self.match(SystemRDLParser.ID)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Local_property_assignmentContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def normal_prop_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Normal_prop_assignContext,0)


        def DEFAULT_kw(self):
            return self.getToken(SystemRDLParser.DEFAULT_kw, 0)

        def encode_prop_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Encode_prop_assignContext,0)


        def prop_mod_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_mod_assignContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_local_property_assignment

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitLocal_property_assignment" ):
                return visitor.visitLocal_property_assignment(self)
            else:
                return visitor.visitChildren(self)




    def local_property_assignment(self):

        localctx = SystemRDLParser.Local_property_assignmentContext(self, self._ctx, self.state)
        self.enterRule(localctx, 102, self.RULE_local_property_assignment)
        self._la = 0 # Token type
        try:
            self.state = 582
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,46,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 571
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==72:
                    self.state = 570
                    self.match(SystemRDLParser.DEFAULT_kw)


                self.state = 573
                self.normal_prop_assign()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 575
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==72:
                    self.state = 574
                    self.match(SystemRDLParser.DEFAULT_kw)


                self.state = 577
                self.encode_prop_assign()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 579
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==72:
                    self.state = 578
                    self.match(SystemRDLParser.DEFAULT_kw)


                self.state = 581
                self.prop_mod_assign()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Dynamic_property_assignmentContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def instance_ref(self):
            return self.getTypedRuleContext(SystemRDLParser.Instance_refContext,0)


        def normal_prop_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Normal_prop_assignContext,0)


        def encode_prop_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Encode_prop_assignContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_dynamic_property_assignment

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitDynamic_property_assignment" ):
                return visitor.visitDynamic_property_assignment(self)
            else:
                return visitor.visitChildren(self)




    def dynamic_property_assignment(self):

        localctx = SystemRDLParser.Dynamic_property_assignmentContext(self, self._ctx, self.state)
        self.enterRule(localctx, 104, self.RULE_dynamic_property_assignment)
        try:
            self.state = 592
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,47,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 584
                self.instance_ref()
                self.state = 585
                self.match(SystemRDLParser.T__14)
                self.state = 586
                self.normal_prop_assign()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 588
                self.instance_ref()
                self.state = 589
                self.match(SystemRDLParser.T__14)
                self.state = 590
                self.encode_prop_assign()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Normal_prop_assignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def prop_keyword(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_keywordContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def prop_assignment_rhs(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_assignment_rhsContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_normal_prop_assign

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitNormal_prop_assign" ):
                return visitor.visitNormal_prop_assign(self)
            else:
                return visitor.visitChildren(self)




    def normal_prop_assign(self):

        localctx = SystemRDLParser.Normal_prop_assignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 106, self.RULE_normal_prop_assign)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 596
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [45, 46, 48, 49, 60, 61]:
                self.state = 594
                self.prop_keyword()
                pass
            elif token in [125]:
                self.state = 595
                self.match(SystemRDLParser.ID)
                pass
            else:
                raise NoViableAltException(self)

            self.state = 600
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==115:
                self.state = 598
                self.match(SystemRDLParser.ASSIGN)
                self.state = 599
                self.prop_assignment_rhs()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Encode_prop_assignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ENCODE_kw(self):
            return self.getToken(SystemRDLParser.ENCODE_kw, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_encode_prop_assign

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEncode_prop_assign" ):
                return visitor.visitEncode_prop_assign(self)
            else:
                return visitor.visitChildren(self)




    def encode_prop_assign(self):

        localctx = SystemRDLParser.Encode_prop_assignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 108, self.RULE_encode_prop_assign)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 602
            self.match(SystemRDLParser.ENCODE_kw)
            self.state = 603
            self.match(SystemRDLParser.ASSIGN)
            self.state = 604
            self.match(SystemRDLParser.ID)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Prop_mod_assignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def prop_mod(self):
            return self.getTypedRuleContext(SystemRDLParser.Prop_modContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_prop_mod_assign

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitProp_mod_assign" ):
                return visitor.visitProp_mod_assign(self)
            else:
                return visitor.visitChildren(self)




    def prop_mod_assign(self):

        localctx = SystemRDLParser.Prop_mod_assignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 110, self.RULE_prop_mod_assign)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 606
            self.prop_mod()
            self.state = 607
            self.match(SystemRDLParser.ID)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Prop_assignment_rhsContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def precedencetype_literal(self):
            return self.getTypedRuleContext(SystemRDLParser.Precedencetype_literalContext,0)


        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_prop_assignment_rhs

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitProp_assignment_rhs" ):
                return visitor.visitProp_assignment_rhs(self)
            else:
                return visitor.visitChildren(self)




    def prop_assignment_rhs(self):

        localctx = SystemRDLParser.Prop_assignment_rhsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 112, self.RULE_prop_assignment_rhs)
        try:
            self.state = 611
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,50,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 609
                self.precedencetype_literal()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 610
                self.expr(0)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Prop_keywordContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def SW_kw(self):
            return self.getToken(SystemRDLParser.SW_kw, 0)

        def HW_kw(self):
            return self.getToken(SystemRDLParser.HW_kw, 0)

        def RCLR_kw(self):
            return self.getToken(SystemRDLParser.RCLR_kw, 0)

        def RSET_kw(self):
            return self.getToken(SystemRDLParser.RSET_kw, 0)

        def WOCLR_kw(self):
            return self.getToken(SystemRDLParser.WOCLR_kw, 0)

        def WOSET_kw(self):
            return self.getToken(SystemRDLParser.WOSET_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_prop_keyword

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitProp_keyword" ):
                return visitor.visitProp_keyword(self)
            else:
                return visitor.visitChildren(self)




    def prop_keyword(self):

        localctx = SystemRDLParser.Prop_keywordContext(self, self._ctx, self.state)
        self.enterRule(localctx, 114, self.RULE_prop_keyword)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 613
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & 3459714491866939392) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Prop_modContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def POSEDGE_kw(self):
            return self.getToken(SystemRDLParser.POSEDGE_kw, 0)

        def NEGEDGE_kw(self):
            return self.getToken(SystemRDLParser.NEGEDGE_kw, 0)

        def BOTHEDGE_kw(self):
            return self.getToken(SystemRDLParser.BOTHEDGE_kw, 0)

        def LEVEL_kw(self):
            return self.getToken(SystemRDLParser.LEVEL_kw, 0)

        def NONSTICKY_kw(self):
            return self.getToken(SystemRDLParser.NONSTICKY_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_prop_mod

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitProp_mod" ):
                return visitor.visitProp_mod(self)
            else:
                return visitor.visitChildren(self)




    def prop_mod(self):

        localctx = SystemRDLParser.Prop_modContext(self, self._ctx, self.state)
        self.enterRule(localctx, 116, self.RULE_prop_mod)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 615
            localctx.kw = self._input.LT(1)
            _la = self._input.LA(1)
            if not(((((_la - 62)) & ~0x3f) == 0 and ((1 << (_la - 62)) & 31) != 0)):
                localctx.kw = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def PROPERTY_kw(self):
            return self.getToken(SystemRDLParser.PROPERTY_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def udp_attr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Udp_attrContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Udp_attrContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_def" ):
                return visitor.visitUdp_def(self)
            else:
                return visitor.visitChildren(self)




    def udp_def(self):

        localctx = SystemRDLParser.Udp_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 118, self.RULE_udp_def)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 617
            self.match(SystemRDLParser.PROPERTY_kw)
            self.state = 618
            self.match(SystemRDLParser.ID)
            self.state = 619
            self.match(SystemRDLParser.T__1)
            self.state = 623 
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while True:
                self.state = 620
                self.udp_attr()
                self.state = 621
                self.match(SystemRDLParser.T__0)
                self.state = 625 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if not (((((_la - 69)) & ~0x3f) == 0 and ((1 << (_la - 69)) & 4109) != 0)):
                    break

            self.state = 627
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_attrContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def udp_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_typeContext,0)


        def udp_usage(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_usageContext,0)


        def udp_default(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_defaultContext,0)


        def udp_constraint(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_constraintContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_attr

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_attr" ):
                return visitor.visitUdp_attr(self)
            else:
                return visitor.visitChildren(self)




    def udp_attr(self):

        localctx = SystemRDLParser.Udp_attrContext(self, self._ctx, self.state)
        self.enterRule(localctx, 120, self.RULE_udp_attr)
        try:
            self.state = 633
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [81]:
                self.enterOuterAlt(localctx, 1)
                self.state = 629
                self.udp_type()
                pass
            elif token in [69]:
                self.enterOuterAlt(localctx, 2)
                self.state = 630
                self.udp_usage()
                pass
            elif token in [72]:
                self.enterOuterAlt(localctx, 3)
                self.state = 631
                self.udp_default()
                pass
            elif token in [71]:
                self.enterOuterAlt(localctx, 4)
                self.state = 632
                self.udp_constraint()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def TYPE_kw(self):
            return self.getToken(SystemRDLParser.TYPE_kw, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def udp_data_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Udp_data_typeContext,0)


        def array_type_suffix(self):
            return self.getTypedRuleContext(SystemRDLParser.Array_type_suffixContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_type" ):
                return visitor.visitUdp_type(self)
            else:
                return visitor.visitChildren(self)




    def udp_type(self):

        localctx = SystemRDLParser.Udp_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 122, self.RULE_udp_type)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 635
            self.match(SystemRDLParser.TYPE_kw)
            self.state = 636
            self.match(SystemRDLParser.ASSIGN)
            self.state = 637
            self.udp_data_type()
            self.state = 639
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==12:
                self.state = 638
                self.array_type_suffix()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_data_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def component_type_primary(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_type_primaryContext,0)


        def REF_kw(self):
            return self.getToken(SystemRDLParser.REF_kw, 0)

        def NUMBER_kw(self):
            return self.getToken(SystemRDLParser.NUMBER_kw, 0)

        def basic_data_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Basic_data_typeContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_data_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_data_type" ):
                return visitor.visitUdp_data_type(self)
            else:
                return visitor.visitChildren(self)




    def udp_data_type(self):

        localctx = SystemRDLParser.Udp_data_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 124, self.RULE_udp_data_type)
        self._la = 0 # Token type
        try:
            self.state = 644
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [30, 31, 32, 33, 34]:
                self.enterOuterAlt(localctx, 1)
                self.state = 641
                self.component_type_primary()
                pass
            elif token in [76, 78]:
                self.enterOuterAlt(localctx, 2)
                self.state = 642
                localctx.kw = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==76 or _la==78):
                    localctx.kw = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            elif token in [18, 19, 20, 22, 125]:
                self.enterOuterAlt(localctx, 3)
                self.state = 643
                self.basic_data_type()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_usageContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def COMPONENT_kw(self):
            return self.getToken(SystemRDLParser.COMPONENT_kw, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def udp_comp_type(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Udp_comp_typeContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Udp_comp_typeContext,i)


        def OR(self, i:int=None):
            if i is None:
                return self.getTokens(SystemRDLParser.OR)
            else:
                return self.getToken(SystemRDLParser.OR, i)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_usage

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_usage" ):
                return visitor.visitUdp_usage(self)
            else:
                return visitor.visitChildren(self)




    def udp_usage(self):

        localctx = SystemRDLParser.Udp_usageContext(self, self._ctx, self.state)
        self.enterRule(localctx, 126, self.RULE_udp_usage)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 646
            self.match(SystemRDLParser.COMPONENT_kw)
            self.state = 647
            self.match(SystemRDLParser.ASSIGN)
            self.state = 648
            self.udp_comp_type()
            self.state = 653
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==103:
                self.state = 649
                self.match(SystemRDLParser.OR)
                self.state = 650
                self.udp_comp_type()
                self.state = 655
                self._errHandler.sync(self)
                _la = self._input.LA(1)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_comp_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.kw = None # Token

        def component_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_typeContext,0)


        def CONSTRAINT_kw(self):
            return self.getToken(SystemRDLParser.CONSTRAINT_kw, 0)

        def ALL_kw(self):
            return self.getToken(SystemRDLParser.ALL_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_comp_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_comp_type" ):
                return visitor.visitUdp_comp_type(self)
            else:
                return visitor.visitChildren(self)




    def udp_comp_type(self):

        localctx = SystemRDLParser.Udp_comp_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 128, self.RULE_udp_comp_type)
        self._la = 0 # Token type
        try:
            self.state = 658
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [30, 31, 32, 33, 34, 35]:
                self.enterOuterAlt(localctx, 1)
                self.state = 656
                self.component_type()
                pass
            elif token in [68, 71]:
                self.enterOuterAlt(localctx, 2)
                self.state = 657
                localctx.kw = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==68 or _la==71):
                    localctx.kw = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_defaultContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def DEFAULT_kw(self):
            return self.getToken(SystemRDLParser.DEFAULT_kw, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_default

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_default" ):
                return visitor.visitUdp_default(self)
            else:
                return visitor.visitChildren(self)




    def udp_default(self):

        localctx = SystemRDLParser.Udp_defaultContext(self, self._ctx, self.state)
        self.enterRule(localctx, 130, self.RULE_udp_default)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 660
            self.match(SystemRDLParser.DEFAULT_kw)
            self.state = 661
            self.match(SystemRDLParser.ASSIGN)
            self.state = 662
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Udp_constraintContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def CONSTRAINT_kw(self):
            return self.getToken(SystemRDLParser.CONSTRAINT_kw, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def COMPONENTWIDTH_kw(self):
            return self.getToken(SystemRDLParser.COMPONENTWIDTH_kw, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_udp_constraint

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitUdp_constraint" ):
                return visitor.visitUdp_constraint(self)
            else:
                return visitor.visitChildren(self)




    def udp_constraint(self):

        localctx = SystemRDLParser.Udp_constraintContext(self, self._ctx, self.state)
        self.enterRule(localctx, 132, self.RULE_udp_constraint)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 664
            self.match(SystemRDLParser.CONSTRAINT_kw)
            self.state = 665
            self.match(SystemRDLParser.ASSIGN)
            self.state = 666
            self.match(SystemRDLParser.COMPONENTWIDTH_kw)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Enum_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ENUM_kw(self):
            return self.getToken(SystemRDLParser.ENUM_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def enum_entry(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Enum_entryContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Enum_entryContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_enum_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEnum_def" ):
                return visitor.visitEnum_def(self)
            else:
                return visitor.visitChildren(self)




    def enum_def(self):

        localctx = SystemRDLParser.Enum_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 134, self.RULE_enum_def)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 668
            self.match(SystemRDLParser.ENUM_kw)
            self.state = 669
            self.match(SystemRDLParser.ID)
            self.state = 670
            self.match(SystemRDLParser.T__1)
            self.state = 674 
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while True:
                self.state = 671
                self.enum_entry()
                self.state = 672
                self.match(SystemRDLParser.T__0)
                self.state = 676 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if not (_la==125):
                    break

            self.state = 678
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Enum_entryContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def enum_prop_assign(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Enum_prop_assignContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Enum_prop_assignContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_enum_entry

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEnum_entry" ):
                return visitor.visitEnum_entry(self)
            else:
                return visitor.visitChildren(self)




    def enum_entry(self):

        localctx = SystemRDLParser.Enum_entryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 136, self.RULE_enum_entry)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 680
            self.match(SystemRDLParser.ID)
            self.state = 683
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==115:
                self.state = 681
                self.match(SystemRDLParser.ASSIGN)
                self.state = 682
                self.expr(0)


            self.state = 695
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==2:
                self.state = 685
                self.match(SystemRDLParser.T__1)
                self.state = 691
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==125:
                    self.state = 686
                    self.enum_prop_assign()
                    self.state = 687
                    self.match(SystemRDLParser.T__0)
                    self.state = 693
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 694
                self.match(SystemRDLParser.T__2)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Enum_prop_assignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_enum_prop_assign

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitEnum_prop_assign" ):
                return visitor.visitEnum_prop_assign(self)
            else:
                return visitor.visitChildren(self)




    def enum_prop_assign(self):

        localctx = SystemRDLParser.Enum_prop_assignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 138, self.RULE_enum_prop_assign)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 697
            self.match(SystemRDLParser.ID)
            self.state = 698
            self.match(SystemRDLParser.ASSIGN)
            self.state = 699
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Struct_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.name = None # Token
            self.base = None # Token

        def STRUCT_kw(self):
            return self.getToken(SystemRDLParser.STRUCT_kw, 0)

        def ID(self, i:int=None):
            if i is None:
                return self.getTokens(SystemRDLParser.ID)
            else:
                return self.getToken(SystemRDLParser.ID, i)

        def ABSTRACT_kw(self):
            return self.getToken(SystemRDLParser.ABSTRACT_kw, 0)

        def struct_elem(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Struct_elemContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Struct_elemContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_struct_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitStruct_def" ):
                return visitor.visitStruct_def(self)
            else:
                return visitor.visitChildren(self)




    def struct_def(self):

        localctx = SystemRDLParser.Struct_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 140, self.RULE_struct_def)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 702
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==67:
                self.state = 701
                self.match(SystemRDLParser.ABSTRACT_kw)


            self.state = 704
            self.match(SystemRDLParser.STRUCT_kw)
            self.state = 705
            localctx.name = self.match(SystemRDLParser.ID)
            self.state = 708
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==10:
                self.state = 706
                self.match(SystemRDLParser.T__9)
                self.state = 707
                localctx.base = self.match(SystemRDLParser.ID)


            self.state = 710
            self.match(SystemRDLParser.T__1)
            self.state = 716
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while (((_la) & ~0x3f) == 0 and ((1 << _la) & 67777593344) != 0) or _la==125:
                self.state = 711
                self.struct_elem()
                self.state = 712
                self.match(SystemRDLParser.T__0)
                self.state = 718
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 719
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Struct_elemContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def struct_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Struct_typeContext,0)


        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def array_type_suffix(self):
            return self.getTypedRuleContext(SystemRDLParser.Array_type_suffixContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_struct_elem

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitStruct_elem" ):
                return visitor.visitStruct_elem(self)
            else:
                return visitor.visitChildren(self)




    def struct_elem(self):

        localctx = SystemRDLParser.Struct_elemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 142, self.RULE_struct_elem)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 721
            self.struct_type()
            self.state = 722
            self.match(SystemRDLParser.ID)
            self.state = 724
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==12:
                self.state = 723
                self.array_type_suffix()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Struct_typeContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def data_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Data_typeContext,0)


        def component_type(self):
            return self.getTypedRuleContext(SystemRDLParser.Component_typeContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_struct_type

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitStruct_type" ):
                return visitor.visitStruct_type(self)
            else:
                return visitor.visitChildren(self)




    def struct_type(self):

        localctx = SystemRDLParser.Struct_typeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 144, self.RULE_struct_type)
        try:
            self.state = 728
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [18, 19, 20, 22, 23, 24, 25, 26, 125]:
                self.enterOuterAlt(localctx, 1)
                self.state = 726
                self.data_type()
                pass
            elif token in [30, 31, 32, 33, 34, 35]:
                self.enterOuterAlt(localctx, 2)
                self.state = 727
                self.component_type()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def constraint_named_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_named_defContext,0)


        def constraint_insts(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_instsContext,0)


        def constraint_anon_def(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_anon_defContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_def" ):
                return visitor.visitConstraint_def(self)
            else:
                return visitor.visitChildren(self)




    def constraint_def(self):

        localctx = SystemRDLParser.Constraint_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 146, self.RULE_constraint_def)
        self._la = 0 # Token type
        try:
            self.state = 737
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,67,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 730
                self.constraint_named_def()
                self.state = 732
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==125:
                    self.state = 731
                    self.constraint_insts()


                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 734
                self.constraint_anon_def()
                self.state = 735
                self.constraint_insts()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_named_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def CONSTRAINT_kw(self):
            return self.getToken(SystemRDLParser.CONSTRAINT_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def constraint_body(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_bodyContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_named_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_named_def" ):
                return visitor.visitConstraint_named_def(self)
            else:
                return visitor.visitChildren(self)




    def constraint_named_def(self):

        localctx = SystemRDLParser.Constraint_named_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 148, self.RULE_constraint_named_def)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 739
            self.match(SystemRDLParser.CONSTRAINT_kw)
            self.state = 740
            self.match(SystemRDLParser.ID)
            self.state = 741
            self.constraint_body()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_anon_defContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def CONSTRAINT_kw(self):
            return self.getToken(SystemRDLParser.CONSTRAINT_kw, 0)

        def constraint_body(self):
            return self.getTypedRuleContext(SystemRDLParser.Constraint_bodyContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_anon_def

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_anon_def" ):
                return visitor.visitConstraint_anon_def(self)
            else:
                return visitor.visitChildren(self)




    def constraint_anon_def(self):

        localctx = SystemRDLParser.Constraint_anon_defContext(self, self._ctx, self.state)
        self.enterRule(localctx, 150, self.RULE_constraint_anon_def)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 743
            self.match(SystemRDLParser.CONSTRAINT_kw)
            self.state = 744
            self.constraint_body()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_bodyContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def constraint_body_elem(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Constraint_body_elemContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Constraint_body_elemContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_body

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_body" ):
                return visitor.visitConstraint_body(self)
            else:
                return visitor.visitChildren(self)




    def constraint_body(self):

        localctx = SystemRDLParser.Constraint_bodyContext(self, self._ctx, self.state)
        self.enterRule(localctx, 152, self.RULE_constraint_body)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 746
            self.match(SystemRDLParser.T__1)
            self.state = 752
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while (((_la) & ~0x3f) == 0 and ((1 << _la) & 4611685949709748292) != 0) or ((((_la - 80)) & ~0x3f) == 0 and ((1 << (_la - 80)) & 35184622694401) != 0):
                self.state = 747
                self.constraint_body_elem()
                self.state = 748
                self.match(SystemRDLParser.T__0)
                self.state = 754
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 755
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_body_elemContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def constr_relational(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_relationalContext,0)


        def constr_prop_assign(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_prop_assignContext,0)


        def constr_inside_values(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_inside_valuesContext,0)


        def constr_inside_enum(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_inside_enumContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_body_elem

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_body_elem" ):
                return visitor.visitConstraint_body_elem(self)
            else:
                return visitor.visitChildren(self)




    def constraint_body_elem(self):

        localctx = SystemRDLParser.Constraint_body_elemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 154, self.RULE_constraint_body_elem)
        try:
            self.state = 761
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,69,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 757
                self.constr_relational()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 758
                self.constr_prop_assign()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 759
                self.constr_inside_values()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 760
                self.constr_inside_enum()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constraint_instsContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self, i:int=None):
            if i is None:
                return self.getTokens(SystemRDLParser.ID)
            else:
                return self.getToken(SystemRDLParser.ID, i)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_constraint_insts

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstraint_insts" ):
                return visitor.visitConstraint_insts(self)
            else:
                return visitor.visitChildren(self)




    def constraint_insts(self):

        localctx = SystemRDLParser.Constraint_instsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 156, self.RULE_constraint_insts)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 763
            self.match(SystemRDLParser.ID)
            self.state = 768
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 764
                self.match(SystemRDLParser.T__3)
                self.state = 765
                self.match(SystemRDLParser.ID)
                self.state = 770
                self._errHandler.sync(self)
                _la = self._input.LA(1)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_relationalContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.op = None # Token

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def LT(self):
            return self.getToken(SystemRDLParser.LT, 0)

        def LEQ(self):
            return self.getToken(SystemRDLParser.LEQ, 0)

        def GT(self):
            return self.getToken(SystemRDLParser.GT, 0)

        def GEQ(self):
            return self.getToken(SystemRDLParser.GEQ, 0)

        def EQ(self):
            return self.getToken(SystemRDLParser.EQ, 0)

        def NEQ(self):
            return self.getToken(SystemRDLParser.NEQ, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_relational

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_relational" ):
                return visitor.visitConstr_relational(self)
            else:
                return visitor.visitChildren(self)




    def constr_relational(self):

        localctx = SystemRDLParser.Constr_relationalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 158, self.RULE_constr_relational)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 771
            self.expr(0)
            self.state = 772
            localctx.op = self._input.LT(1)
            _la = self._input.LA(1)
            if not(((((_la - 114)) & ~0x3f) == 0 and ((1 << (_la - 114)) & 125) != 0)):
                localctx.op = self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
            self.state = 773
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_prop_assignContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def ASSIGN(self):
            return self.getToken(SystemRDLParser.ASSIGN, 0)

        def expr(self):
            return self.getTypedRuleContext(SystemRDLParser.ExprContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_prop_assign

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_prop_assign" ):
                return visitor.visitConstr_prop_assign(self)
            else:
                return visitor.visitChildren(self)




    def constr_prop_assign(self):

        localctx = SystemRDLParser.Constr_prop_assignContext(self, self._ctx, self.state)
        self.enterRule(localctx, 160, self.RULE_constr_prop_assign)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 775
            self.match(SystemRDLParser.ID)
            self.state = 776
            self.match(SystemRDLParser.ASSIGN)
            self.state = 777
            self.expr(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_inside_valuesContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def constr_lhs(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_lhsContext,0)


        def INSIDE_kw(self):
            return self.getToken(SystemRDLParser.INSIDE_kw, 0)

        def constr_inside_value(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.Constr_inside_valueContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.Constr_inside_valueContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_inside_values

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_inside_values" ):
                return visitor.visitConstr_inside_values(self)
            else:
                return visitor.visitChildren(self)




    def constr_inside_values(self):

        localctx = SystemRDLParser.Constr_inside_valuesContext(self, self._ctx, self.state)
        self.enterRule(localctx, 162, self.RULE_constr_inside_values)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 779
            self.constr_lhs()
            self.state = 780
            self.match(SystemRDLParser.INSIDE_kw)
            self.state = 781
            self.match(SystemRDLParser.T__1)
            self.state = 782
            self.constr_inside_value()
            self.state = 787
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==4:
                self.state = 783
                self.match(SystemRDLParser.T__3)
                self.state = 784
                self.constr_inside_value()
                self.state = 789
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 790
            self.match(SystemRDLParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_inside_enumContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def constr_lhs(self):
            return self.getTypedRuleContext(SystemRDLParser.Constr_lhsContext,0)


        def INSIDE_kw(self):
            return self.getToken(SystemRDLParser.INSIDE_kw, 0)

        def ID(self):
            return self.getToken(SystemRDLParser.ID, 0)

        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_inside_enum

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_inside_enum" ):
                return visitor.visitConstr_inside_enum(self)
            else:
                return visitor.visitChildren(self)




    def constr_inside_enum(self):

        localctx = SystemRDLParser.Constr_inside_enumContext(self, self._ctx, self.state)
        self.enterRule(localctx, 164, self.RULE_constr_inside_enum)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 792
            self.constr_lhs()
            self.state = 793
            self.match(SystemRDLParser.INSIDE_kw)
            self.state = 794
            self.match(SystemRDLParser.ID)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_lhsContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser

        def THIS_kw(self):
            return self.getToken(SystemRDLParser.THIS_kw, 0)

        def instance_ref(self):
            return self.getTypedRuleContext(SystemRDLParser.Instance_refContext,0)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_lhs

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_lhs" ):
                return visitor.visitConstr_lhs(self)
            else:
                return visitor.visitChildren(self)




    def constr_lhs(self):

        localctx = SystemRDLParser.Constr_lhsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 166, self.RULE_constr_lhs)
        try:
            self.state = 798
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [80]:
                self.enterOuterAlt(localctx, 1)
                self.state = 796
                self.match(SystemRDLParser.THIS_kw)
                pass
            elif token in [125]:
                self.enterOuterAlt(localctx, 2)
                self.state = 797
                self.instance_ref()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx


    class Constr_inside_valueContext(ParserRuleContext):
        __slots__ = 'parser'

        def __init__(self, parser, parent:ParserRuleContext=None, invokingState:int=-1):
            super().__init__(parent, invokingState)
            self.parser = parser
            self.val = None # ExprContext
            self.l_val = None # ExprContext
            self.r_val = None # ExprContext

        def expr(self, i:int=None):
            if i is None:
                return self.getTypedRuleContexts(SystemRDLParser.ExprContext)
            else:
                return self.getTypedRuleContext(SystemRDLParser.ExprContext,i)


        def getRuleIndex(self):
            return SystemRDLParser.RULE_constr_inside_value

        def accept(self, visitor:ParseTreeVisitor):
            if hasattr( visitor, "visitConstr_inside_value" ):
                return visitor.visitConstr_inside_value(self)
            else:
                return visitor.visitChildren(self)




    def constr_inside_value(self):

        localctx = SystemRDLParser.Constr_inside_valueContext(self, self._ctx, self.state)
        self.enterRule(localctx, 168, self.RULE_constr_inside_value)
        try:
            self.state = 807
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [2, 6, 11, 18, 19, 20, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 92, 93, 94, 95, 96, 97, 98, 99, 101, 102, 103, 105, 106, 107, 125]:
                self.enterOuterAlt(localctx, 1)
                self.state = 800
                localctx.val = self.expr(0)
                pass
            elif token in [12]:
                self.enterOuterAlt(localctx, 2)
                self.state = 801
                self.match(SystemRDLParser.T__11)
                self.state = 802
                localctx.l_val = self.expr(0)
                self.state = 803
                self.match(SystemRDLParser.T__9)
                self.state = 804
                localctx.r_val = self.expr(0)
                self.state = 805
                self.match(SystemRDLParser.T__12)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx



    def sempred(self, localctx:RuleContext, ruleIndex:int, predIndex:int):
        if self._predicates == None:
            self._predicates = dict()
        self._predicates[23] = self.expr_sempred
        pred = self._predicates.get(ruleIndex, None)
        if pred is None:
            raise Exception("No predicate with index:" + str(ruleIndex))
        else:
            return pred(localctx, predIndex)

    def expr_sempred(self, localctx:ExprContext, predIndex:int):
            if predIndex == 0:
                return self.precpred(self._ctx, 13)
         

            if predIndex == 1:
                return self.precpred(self._ctx, 12)
         

            if predIndex == 2:
                return self.precpred(self._ctx, 11)
         

            if predIndex == 3:
                return self.precpred(self._ctx, 10)
         

            if predIndex == 4:
                return self.precpred(self._ctx, 9)
         

            if predIndex == 5:
                return self.precpred(self._ctx, 8)
         

            if predIndex == 6:
                return self.precpred(self._ctx, 7)
         

            if predIndex == 7:
                return self.precpred(self._ctx, 6)
         

            if predIndex == 8:
                return self.precpred(self._ctx, 5)
         

            if predIndex == 9:
                return self.precpred(self._ctx, 4)
         

            if predIndex == 10:
                return self.precpred(self._ctx, 3)
         

            if predIndex == 11:
                return self.precpred(self._ctx, 2)
         




