10000 -XLambdaCase. · github/semantic@54f3aa7 · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Apr 1, 2025. It is now read-only.

Commit 54f3aa7

Browse files
committed
-XLambdaCase.
1 parent e4cf5c1 commit 54f3aa7

File tree

1 file changed

+1
-1
lines changed
  • semantic-analysis/src/Analysis/Syntax

1 file changed

+1
-1
lines changed

semantic-analysis/src/Analysis/Syntax/Python.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ eval eval = \case
8585
-- FIXME: RaiseV2
8686
-- FIXME: whatever the second field is
8787
Statement (Py.StmtExpr e sp) -> setSpan sp (eval (Expr e))
88-
Statement (Py.Fun n ps _r ss sp) -> let ps' = mapMaybe (\ p -> case p of { Py.Param n _ _ _ -> Just (ident n) ; _ -> Nothing}) ps in setSpan sp $ letrec (ident n) (dabs ps' (foldr (\ (p, a) m -> let' p a m) (suite ss) . zip ps'))
88+
Statement (Py.Fun n ps _r ss sp) -> let ps' = mapMaybe (\case { Py.Param n _ _ _ -> Just (ident n) ; _ -> Nothing}) ps in setSpan sp $ letrec (ident n) (dabs ps' (foldr (\ (p, a) m -> let' p a m) (suite ss) . zip ps'))
8989
Expr (Py.Var n sp) -> setSpan sp $ let n' = ident n in lookupEnv n' >>= maybe (dvar n') fetch
9090
Expr (Py.Bool b sp) -> setSpan sp $ dbool b
9191
Expr (Py.Strings ss sp) -> setSpan sp $ dstring (pack (mconcat ss))

0 commit comments

Comments
 (0)
0