Bug #521

IF without ELSE in end of function

Added by iri almost 2 years ago.

Status:NewStart date:05/09/2015
Priority:NormalDue date:
Assignee:iri% Done:

0%

Category:VMSpent time:-
Target version:-

Description

Recently, the ELSE block became optional.
However, only in the end of a function, no ELSE block can occur a fatal error during the type checking :

TC > else expected
syntax error

Example :

fun anyFunction (arg)=
  if arg then
    // do something ;;

While waiting, add a statment, like '0' or something else.

fun anyFunction (arg)=
  if arg then
    // do something ;
  0;;

Also available in: Atom PDF