@@ -254,10 +254,10 @@ class_def[stmt_ty]:
254254class_def_raw[stmt_ty]:
255255 | invalid_class_def_raw
256256 | 'class' a=NAME t=[type_params] b=['(' z=[arguments] ')' { z }] ':' c=block {
257- _PyAST_ClassDef(a->v.Name.id, t,
257+ _PyAST_ClassDef(a->v.Name.id,
258258 (b) ? ((expr_ty) b)->v.Call.args : NULL,
259259 (b) ? ((expr_ty) b)->v.Call.keywords : NULL,
260- c, NULL, EXTRA) }
260+ c, NULL, t, EXTRA) }
261261
262262# Function definitions
263263# --------------------
@@ -269,17 +269,17 @@ function_def[stmt_ty]:
269269function_def_raw[stmt_ty]:
270270 | invalid_def_raw
271271 | 'def' n=NAME t=[type_params] &&'(' params=[params] ')' a=['->' z=expression { z }] &&':' tc=[func_type_comment] b=block {
272- _PyAST_FunctionDef(n->v.Name.id, t,
272+ _PyAST_FunctionDef(n->v.Name.id,
273273 (params) ? params : CHECK(arguments_ty, _PyPegen_empty_arguments(p)),
274- b, NULL, a, NEW_TYPE_COMMENT(p, tc), EXTRA) }
274+ b, NULL, a, NEW_TYPE_COMMENT(p, tc), t, EXTRA) }
275275 | ASYNC 'def' n=NAME t=[type_params] &&'(' params=[params] ')' a=['->' z=expression { z }] &&':' tc=[func_type_comment] b=block {
276276 CHECK_VERSION(
277277 stmt_ty,
278278 5,
279279 "Async functions are",
280- _PyAST_AsyncFunctionDef(n->v.Name.id, t,
280+ _PyAST_AsyncFunctionDef(n->v.Name.id,
281281 (params) ? params : CHECK(arguments_ty, _PyPegen_empty_arguments(p)),
282- b, NULL, a, NEW_TYPE_COMMENT(p, tc), EXTRA)
282+ b, NULL, a, NEW_TYPE_COMMENT(p, tc), t, EXTRA)
283283 ) }
284284
285285# Function parameters
0 commit comments