1. 31 1月, 2022 6 次提交
  2. 30 1月, 2022 15 次提交
    • G
    • B
      Auto merge of #93468 - matthiaskrgr:rollup-vxullvd, r=matthiaskrgr · 7cc28c12
      bors 提交于
      Rollup of 8 pull requests
      
      Successful merges:
      
       - #93256 (Make `join!` description more accurate)
       - #93358 (Add note suggesting that predicate may be satisfied, but is not `const`)
       - #93362 (Do not register infer var for GAT projection in RPIT)
       - #93391 (rustdoc: remove tooltip from source link)
       - #93414 (Move unstable is_{arch}_feature_detected! macros to std::arch)
       - #93441 (rustdoc: load the set of in-scope traits for modules with no docstring)
       - #93459 (fs: Don't copy d_name from struct dirent)
       - #93463 (Rename _args -> args in format_args expansion)
      
      Failed merges:
      
      r? `@ghost`
      `@rustbot` modify labels: rollup
      7cc28c12
    • J
      rustdoc: small fixes to mobile navigation · a998a374
      Jacob Hoffman-Andrews 提交于
      - Make sure the mobile-topbar doesn't overflow its height if the user
        sets a bigger font.
      
      - Make sure the sidebar can be scrolled all the way to the bottom by
        shortening it to accommodate the mobile-topbar.
      
      - Make the item name in the mobile-topbar clickable to go to the top of
        the page.
      
      - Remove excess padding sidebar in mobile mode.
      a998a374
    • M
      Rollup merge of #93463 - dtolnay:_args, r=cjgillot · 9f6d0cb0
      Matthias Krüger 提交于
      Rename _args -> args in format_args expansion
      
      As observed in https://github.com/rust-lang/rust/pull/91359#discussion_r786058960, prior to that PR this variable was sometimes never used, such as in the case of:
      
      ```rust
      println!("");
      
      // used to expand to:
      ::std::io::_print(
          ::core::fmt::Arguments::new_v1(
              &["\n"],
              &match () {
                  _args => [],
              },
          ),
      );
      ```
      
      so the leading underscore in `_args` was used to suppress an unused variable lint. However after #91359 the variable is always used when present, as the unused case would instead expand to:
      
      ```rust
      ::std::io::_print(::core::fmt::Arguments::new_v1(&["\n"], &[]));
      ```
      9f6d0cb0
    • M
      Rollup merge of #93459 - tavianator:dirent-copy-only-reclen, r=cuviper · 0d08bbc8
      Matthias Krüger 提交于
      fs: Don't copy d_name from struct dirent
      
      The dirent returned from readdir() is only guaranteed to be valid for
      d_reclen bytes on common platforms.  Since we copy the name separately
      anyway, we can copy everything except d_name into DirEntry::entry.
      
      Fixes #93384.
      0d08bbc8
    • M
      Rollup merge of #93441 - notriddle:notriddle/collect-crate-doc-links-very-early, r=petrochenkov · 605ffd61
      Matthias Krüger 提交于
      rustdoc: load the set of in-scope traits for modules with no docstring
      
      Fixes #93428
      
      This fix is a response to a couple of special cases related to the `module_id`, which is eventually used for trait candidates:
      
        * The module id is always set to the current crate, when checking `crate::`.
      
          Normally, the set of in-scope traits would be set in `load_links_in_attrs`, but if there are no doc comments, then that loop will never run.
      
        * the module id is set to the parent module, when resolving a module that is spelled like this:
      
              // Notice how we use an outlined doc comment here!
              // [`Test::my_fn`]
              mod something {
              }
      
          As with the above problem with `crate::`, we need to make sure the module gets its traits in scope resolved, even if it has no doc comments of its own.
      605ffd61
    • M
      Rollup merge of #93414 - Amanieu:std_arch_detect, r=m-ou-se · 329753e2
      Matthias Krüger 提交于
      Move unstable is_{arch}_feature_detected! macros to std::arch
      
      These macros are unstable, except for `is_x86_feature_detected` which is still exported from the crate root for backwards-compatibility.
      
      This should unblock the stabilization of `is_aarch64_feature_detected`.
      
      r? ```@m-ou-se```
      329753e2
    • M
      Rollup merge of #93391 - notriddle:notriddle/remove-srclink-tooltip, r=jsha,GuillaumeGomez · 0b2359ba
      Matthias Krüger 提交于
      rustdoc: remove tooltip from source link
      
      This made more sense back when it was abbreviated, but now it seems redundant.
      0b2359ba
    • M
      Rollup merge of #93362 - compiler-errors:ice-gat-in-rpit, r=oli-obk · 4484165c
      Matthias Krüger 提交于
      Do not register infer var for GAT projection in RPIT
      
      Fixes #93340
      Fixes #91603
      
      r? ```@oli-obk```
      4484165c
    • M
      Rollup merge of #93358 - compiler-errors:is-not-const, r=fee1-dead · 103c3a38
      Matthias Krüger 提交于
      Add note suggesting that predicate may be satisfied, but is not `const`
      
      Not sure if we should be printing this in addition to, or perhaps _instead_ of the help message:
      ```
      help: the trait `~const Add` is not implemented for `NonConstAdd`
      ```
      
      Also added `ParamEnv::is_const` and `PolyTraitPredicate::is_const_if_const` and, in a separate commit, used those in other places instead of `== hir::Constness::Const`, etc.
      
      r? ````@fee1-dead````
      103c3a38
    • M
      Rollup merge of #93256 - EFanZh:patch-1, r=joshtriplett · 6e2593d3
      Matthias Krüger 提交于
      Make `join!` description more accurate
      6e2593d3
    • T
      fs: Add a regression test for #93384 · d0c8b29e
      Tavian Barnes 提交于
      d0c8b29e
    • T
      fs: Don't copy d_name from struct dirent · f8f4c405
      Tavian Barnes 提交于
      The dirent returned from readdir() is only guaranteed to be valid for
      d_reclen bytes on common platforms.  Since we copy the name separately
      anyway, we can copy everything except d_name into DirEntry::entry.
      
      Fixes #93384.
      f8f4c405
    • D
      Rename _args -> args in format_args expansion · 6667d785
      David Tolnay 提交于
      6667d785
    • B
      Auto merge of #93457 - matthiaskrgr:rollup-e43ry1l, r=matthiaskrgr · a00e130d
      bors 提交于
      Rollup of 8 pull requests
      
      Successful merges:
      
       - #88205 (Add Explanation For Error E0772)
       - #92274 (Add `intrinsics::const_deallocate`)
       - #93236 (Make `NonNull::new` `const`)
       - #93299 (Fix dot separator when there is no source link)
       - #93410 (kmc-solid: Implement `net::FileDesc::duplicate`)
       - #93424 (fix nit)
       - #93431 (remove unused `jemallocator` crate)
       - #93453 (Add GUI theme change test)
      
      Failed merges:
      
      r? `@ghost`
      `@rustbot` modify labels: rollup
      a00e130d
  3. 29 1月, 2022 19 次提交