sacalon / sacalon

Sacalon is a general purpose and open source programming language designed to build optimal, maintainable, reliable and efficient software.

Home Page:https://sacalon.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Not erroring when there is no return values in main()

mehanalavimajd opened this issue · comments

Is your feature request related to a problem? Please describe.
This following code:

function main():int{
    print("Hello world")
}

Would return the error:

Error : Function 'main' should return a value at end of function block:1

So In other languages like c++ There is no need to put return 0; in latest versions.
Basically, We must ignore not returning if function name is main

commented

Merged!