You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
type Bool:
T
F
def filter(f, ls):
match ls:
case List/Nil:
return List/Nil
case List/Cons:
match f(ls.head):
case Bool/T:
return List/Cons(ls.head, filter(f, ls.tail))
case Bool/F:
return filter(f, ls.tail)
def main:
return filter(lambda x: x, [Bool/T])
Reproducing the behavior
Result:
System Settings
bend-lang 0.2.37-alpha.1
Additional context
No response
The text was updated successfully, but these errors were encountered: