snazzy-d / sdc

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

Issue diagnostic message if module name mismatches file #325

Closed 0xEAB closed 9 months ago

0xEAB commented 10 months 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 9 months 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 9 months ago

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