Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

When you write 'mod foo;' in a Rust file (say, main.rs), Rust will look for the source code for the module named foo in one of two places: a file named foo.rs in the same directory as the file declaring the module, or a folder named foo/ with a file named mod.rs inside it.

That's great. Something like this is what C# can also aim for, while retaining full backward compatibility.



This would break every codebase in C# where a file lives in a folder where it is NOT in sync with the file system.


This can be opt in, and not break any existing code.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: