radon-project / radon

The Radon Programming Language
https://radon-project.github.io
GNU General Public License v3.0
23 stars 2 forks source link

`raise` statement inhancement. #137

Closed Almas-Ali closed 4 months ago

Almas-Ali commented 4 months ago

Describe the bug When I import a error function from other file it is not showing the full function path like as Python do.

Screenshots or Code snippets

Code

import somefile

raise somefile.ValueError("Some -- error")

Issue

Radiation (most recent call last):
  File tests/radiation-errors.rn, line 8
somefile: Some -- error

raise somefile.ValueError("Some -- error")
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Should have to be:

Radiation (most recent call last):
  File tests/radiation-errors.rn, line 8
somefile.ValueError: Some -- error

raise somefile.ValueError("Some -- error")
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Same as caller file somefile.ValueError.