[BUG REPORT] simc test.c gives an unexpected error
shobhit10058 opened this issue · comments
Shobhit Gupta commented
Description of the bug
when simc is run with a file not with .simc extension it gives an unexpected error
Traceback (most recent call last):
File "/home/shobhit/.local/bin/simc", line 8, in <module>
sys.exit(run())
File "/home/shobhit/.local/lib/python3.8/site-packages/simc/simc.py", line 25, in run
error("Incorrect file extension", line_num)
NameError: name 'line_num' is not defined
NameError should not come.
Steps To Reproduce
simply run simc test.c.
Expected behavior
It should simply give Incorrect file extension
Shobhit Gupta commented
We can simply fix it by replacing line_num with -1 or something.
Siddhartha Dhar Choudhury commented
Hey thanks @shobhit10058 for submitting the bug report, do you want to work on this?
Shobhit Gupta commented
yes
Shobhit Gupta commented
I think the suggestion is enough, so should I add it -1.
Siddhartha Dhar Choudhury commented
Yeah that would work, assigning this to you.
Siddhartha Dhar Choudhury commented
Merged.