cimplec / sim-c

A dynamically typed high-level front end for C

Home Page:https://cimplec.github.io/docs/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[BUG REPORT] Incorrect error message when function is not defined

frankhart2018 opened this issue · comments

Describe the bug
When a function is not defined but is called the error message should be like:- "Function is not defined", but it throws an error regarding the mismatch of number of formal and actual params.

sim-C Code

MAIN
    sum(1, 2)
END_MAIN

Error Message

[Line 2] Error: Expected not more than 0 arguments but got 2 in function sum

Which file has to be corrected?

You need to look into parser/simc_parser.py and parser/function_parser.py. Would you like to work on this?

Yeah. I would like to do it.

Assigning this to you then @nishihere19.