You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
catamorphism opened this issue
Mar 16, 2012
· 3 comments
Labels
A-resolveArea: Name/path resolution done by `rustc_resolve` specificallyC-cleanupCategory: PRs that clean code up or issues documenting cleanup.E-hardCall for participation: Hard difficulty. Experience needed to fix: A lot.
This is probably blocked on rewriting resolve. I want the exports from libc to have the following characteristics:
There is a list of explicit exports-from-libc that is statically checked to ensure those definitions are present on all platforms. In the rewrite this will probably take the form of a list of pub import ... directives.
There are a bunch of residual globs that pick up and re-export everything else beyond the intersection list, so that when you're on platform foo that has a libc definition funcs::os::extras::bar() you can just call libc::bar() and it'll build on that platform. But you will have made platform-specific code by doing so. This will be a list of pub import ...* globs.
Currently, export globs don't work terribly well. They kinda work for exporting a bunch of items, but not for re-exporting a glob-import from somewhere else. And I think there was an ordering problem of some sort. I eventually gave up and left it as-is, with the few platform-specific cases explicitly glob-importing definitions from the inner modules of libc. Which is undesirable in the longer term.
A-resolveArea: Name/path resolution done by `rustc_resolve` specificallyC-cleanupCategory: PRs that clean code up or issues documenting cleanup.E-hardCall for participation: Hard difficulty. Experience needed to fix: A lot.
core::libc
has FIXMEs about cleaning up exports. I'm not sure I exactly understand what needs to be done, so am just filing it.The text was updated successfully, but these errors were encountered: