Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restrict where in the tree platform-specific cfgs may be mentioned #36807

Merged
merged 7 commits into from
Oct 3, 2016

Commits on Oct 1, 2016

  1. Configuration menu
    Copy the full SHA
    e6457bb View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5c21562 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    fea1bd4 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    d311079 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    0fb8379 View commit details
    Browse the repository at this point in the history

Commits on Oct 2, 2016

  1. Add a platform-abstraction tidy script

    This is intended to maintain existing standards of code organization
    in hopes that the standard library will continue to be refactored to
    isolate platform-specific bits, making porting easier; where "standard
    library" roughly means "all the dependencies of the std and test
    crates".
    
    This generally means placing restrictions on where `cfg(unix)`,
    `cfg(windows)`, `cfg(target_os)` and `cfg(target_env)` may appear,
    the basic objective being to isolate platform-specific code to the
    platform-specific `std::sys` modules, and to the allocation,
    unwinding, and libc crates.
    
    Following are the basic rules, though there are currently
    exceptions:
    
    - core may not have platform-specific code
    - liballoc_system may have platform-specific code
    - liballoc_jemalloc may have platform-specific code
    - libpanic_abort may have platform-specific code
    - libpanic_unwind may have platform-specific code
    - other crates in the std facade may not
    - std may have platform-specific code in the following places
      - sys/unix/
      - sys/windows/
      - os/
    
    There are plenty of exceptions today though, noted in the whitelist.
    brson committed Oct 2, 2016
    Configuration menu
    Copy the full SHA
    29e0235 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4d76ac8 View commit details
    Browse the repository at this point in the history