Grammar connected by Vadim Zaytsev, see the Grammar Zoo entry for details: api/rascal/boolean/connected
Source used for this grammar: Jurgen J. Vinju, Paul Klint, Boolean
, 2009–2013 [Explore]
bool
, int
, real
, str
), 0 root (—), 2 top (int
, real
), 0 bottom (—).[arbBool]
, [fromString]
, [toInt]
, [toReal]
, [toString]
.⟨s⟩
, ⟨b⟩
3.bool ::=
[arbBool]::ε
[fromString]::⟨s⟩:str
boolean
int ::=
[toInt]::⟨b⟩:bool
integer
real ::= [toReal]::⟨b⟩:bool integer "." integer
str ::=
[toString]::⟨b⟩:bool
string