snazzy-d / sdc

The Snazzy D Compiler
MIT License
250 stars 55 forks source link

Issue diagnostic message if module name mismatches file #325

Closed 0xEAB closed 1 year ago

0xEAB commented 1 year ago

Currently SDC asserts whether the module name matches filename + file hierarchy, but produces an ICE if this check fails. How about throwing a CompileException carrying the location of the declaration statement?

deadalnix commented 1 year ago

Sorry, just seeing this now, because github...

In any case, thanks for taking care of this, this is definitively something that needs doing.

0xEAB commented 1 year ago

Is locationDeclarationName better? …or which name would you prefer (any suggestions)?