0
Я вижу $startpos
и $endpos
в .mly
от типа проверки:долларов + идентификатор в mly
recursive_def:
| f = term_variable
ty_args = multiple(formal_type_arguments)
te_args = multiple(term_arguments)
codomain = preceded(COLON,typ)
EQ t = loc(term)
{ let loc = ($startpos(ty_args), $endpos(t)) in
make_recursive_definition f loc ty_args te_args codomain t }
(* one should check that the right-hand side of a recursive definition
is a value, e.g. a function or a data constructor application; this
is not done for the moment. *)
...
pattern:
| d = data_constructor tvars = multiple(formal_type_arguments) LBRACE fields = semi(term_variable) RBRACE
{ SynPatData (($startpos, $endpos), d, tvars, fields) }
...
(* Recording locations. *)
loc(TERM):
| t = TERM
{ SynTeLoc (($startpos, $endpos), t) }
Может кто-нибудь сказать мне, что смысл $
+ identifier
? Являются ли они функциями или переменными? Как их ценности питаются?