Fix the signature of expr_ext
The extension body is just a string, not an expression.
This commit is contained in:
parent
c78b73b71d
commit
540344acb9
5 changed files with 8 additions and 8 deletions
|
|
@ -173,7 +173,7 @@ type ast_fold[ENV] =
|
|||
|
||||
(fn(&ENV e, &span sp,
|
||||
&path p, vec[@expr] args,
|
||||
option.t[@expr] body,
|
||||
option.t[str] body,
|
||||
@expr expanded,
|
||||
ann a) -> @expr) fold_expr_ext,
|
||||
|
||||
|
|
@ -1343,7 +1343,7 @@ fn identity_fold_expr_path[ENV](&ENV env, &span sp,
|
|||
|
||||
fn identity_fold_expr_ext[ENV](&ENV env, &span sp,
|
||||
&path p, vec[@expr] args,
|
||||
option.t[@expr] body,
|
||||
option.t[str] body,
|
||||
@expr expanded,
|
||||
ann a) -> @expr {
|
||||
ret @respan(sp, ast.expr_ext(p, args, body, expanded, a));
|
||||
|
|
|
|||
|
|
@ -1922,9 +1922,9 @@ fn annotate_expr(&fn_info_map fm, &@expr e) -> @expr {
|
|||
case (expr_path(_,_,_)) {
|
||||
/* no change */
|
||||
}
|
||||
case (expr_ext(?p, ?es, ?e_opt, ?e, ?a)) {
|
||||
case (expr_ext(?p, ?es, ?s_opt, ?e, ?a)) {
|
||||
e1 = expr_ext(p, annotate_exprs(fm, es),
|
||||
annotate_option_exp(fm, e_opt),
|
||||
s_opt,
|
||||
annotate_expr(fm, e), a);
|
||||
}
|
||||
/* no change, next 3 cases */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue