]> git.lizzy.rs Git - rust.git/commit
Auto merge of #32167 - jseyfried:refactor_prelude, r=nikomatsakis
authorbors <bors@rust-lang.org>
Fri, 25 Mar 2016 22:53:16 +0000 (15:53 -0700)
committerbors <bors@rust-lang.org>
Fri, 25 Mar 2016 22:53:16 +0000 (15:53 -0700)
commita1e29daf1a9ca4e26719887b0c934de5d1695031
tree5da1402523312269a5fb7c7e5e7aa48abdfd8f60
parentcf9274b727423306121c223681022ac0531c6091
parent54cd4d1472508af604e2fed328951dd5c622ecbc
Auto merge of #32167 - jseyfried:refactor_prelude, r=nikomatsakis

resolve: Refactor how the prelude is handled

This PR refactors how the prelude is handled in `resolve`.

Instead of importing names from the prelude into each module's `resolutions`, this PR adds a new field `prelude: RefCell<Option<Module>>` to `ModuleS` that is set during import resolution but used only when resolving in a lexical scope (i.e. the scope of an initial segment of a relative path).

r? @nikomatsakis