TMI: external crates: lost and found
May. 16th, 2013 06:06 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
I more-or-less finished external crate inference, at least in the local-crate case. I spent most of the time on that fighting with the borrow checker. To add the right directories into the session's list of additional library search path, I wrote some visitor code that looks at all the view_items in the crate. There are two types of view_items: extern mod directives and use directives. For this, I only care about extern mod directives.
The problem is that the visitor wants an @-closure, which can't use borrowed pointers, so accumulating a mutable vector of found extern mod thing seems... hard. I eventually gave up and worked around it with massive amounts of copying.
Once I get some tidy stuff cleaned up, and figure out the copy issue, I'll be ready to check that in and close #5681.
If I can finish #6407 (allowing extern mod directives to name remote packages) and #5683 (the test runner for rustpkg, which I've already started a rudimentary version of) tomorrow, then I'll be on-schedule so far. It might happen.
The problem is that the visitor wants an @-closure, which can't use borrowed pointers, so accumulating a mutable vector of found extern mod thing seems... hard. I eventually gave up and worked around it with massive amounts of copying.
Once I get some tidy stuff cleaned up, and figure out the copy issue, I'll be ready to check that in and close #5681.
If I can finish #6407 (allowing extern mod directives to name remote packages) and #5683 (the test runner for rustpkg, which I've already started a rudimentary version of) tomorrow, then I'll be on-schedule so far. It might happen.
(no subject)
Date: 2013-05-17 09:09 am (UTC)(no subject)
Date: 2013-05-18 12:11 am (UTC)