fmease / lushui

The reference compiler of the Lushui programming language
Apache License 2.0
5 stars 0 forks source link

Test the performance of the name resolver by generating very large Lushui files #98

Open fmease opened 3 years ago

fmease commented 3 years ago

I suspect that do a lot of wasteful allocations in the name resolver which should be avoided. Mainly, I am looking at crate::ast::Path and crate::ast::Path::tail where we store a vector of path segments and clone every time we call tail when we could just use a slice-like mechanism: Some unsized PathView type.

Also I wonder how bad the lowering of complex use-path trees is (not strictly related to the name resolver) and whether it is advisable to not expand them in the lowerer (very likely!). See #93.