Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve error message when program is missing arm of branching statement #464

Closed
developedby opened this issue May 23, 2024 · 0 comments · Fixed by #645
Closed

Improve error message when program is missing arm of branching statement #464

developedby opened this issue May 23, 2024 · 0 comments · Fixed by #645
Labels
enhancement New feature or request syntax About Bend's syntax

Comments

@developedby
Copy link
Member

for example

def is_even(n):
  if n % 2 == 0:
    return 1
  else:
    return 0

def get_even_sum_under_if(this_number):
  bend current = 0:
    when current < this_number:
      new_num = fork(current + is_even(current))
    
      return new_num

def main():
  return get_even_sum_under_if(1000)

will complain about wrong indentation and not the missing else

@developedby developedby added enhancement New feature or request syntax About Bend's syntax labels May 23, 2024
github-merge-queue bot pushed a commit that referenced this issue Jul 25, 2024
…when-program-is-missing-arm-of-branching-statement

#464 Improve error message when program is missing arm of branching statement
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request syntax About Bend's syntax
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant