1. 20 4月, 2021 5 次提交
  2. 19 4月, 2021 4 次提交
  3. 18 4月, 2021 2 次提交
    • R
      Add coverage to continue statements · 448e52d9
      Rich Kadel 提交于
      `continue` statements were missing coverage. This was particularly
      noticeable in a match pattern that contained only a `continue`
      statement, leaving the branch appear uncounted. This PR addresses the
      problem and adds tests to prove it.
      448e52d9
    • S
      Don't set `fast`(-math) for certain simd ops · 487e2735
      Simonas Kazlauskas 提交于
      `fast-math` implies things like functions not being able to accept as an
      argument or return as a result, say, `inf` which made these functions
      confusingly named or behaving incorrectly, depending on how you
      interpret it. Since the time when these intrinsics have been implemented
      the intrinsics user's (stdsimd) approach has changed significantly and
      so now it is required that these intrinsics operate normally rather than
      in "whatever" way.
      
      Fixes #84268
      487e2735
  4. 17 4月, 2021 3 次提交
  5. 16 4月, 2021 5 次提交
  6. 15 4月, 2021 2 次提交
    • A
      Run buffered lints attached to anon consts · 19c9d93a
      Aaron Hill 提交于
      Fixes #84195
      19c9d93a
    • J
      Add more SIMD math.h intrinsics · 003b8ead
      Jubilee Young 提交于
      LLVM supports many functions from math.h in its IR. Many of these have
      single-instruction variants on various platforms. So, let's add them so
      std::arch can use them.
      
      Yes, exact comparison is intentional: rounding must always return a
      valid integer-equal value, except for inf/NAN.
      003b8ead
  7. 14 4月, 2021 4 次提交
  8. 13 4月, 2021 6 次提交
  9. 12 4月, 2021 3 次提交
  10. 11 4月, 2021 5 次提交
    • H
      2fd4dd20
    • A
      Implement token-based handling of attributes during expansion · a93c4f05
      Aaron Hill 提交于
      This PR modifies the macro expansion infrastructure to handle attributes
      in a fully token-based manner. As a result:
      
      * Derives macros no longer lose spans when their input is modified
        by eager cfg-expansion. This is accomplished by performing eager
        cfg-expansion on the token stream that we pass to the derive
        proc-macro
      * Inner attributes now preserve spans in all cases, including when we
        have multiple inner attributes in a row.
      
      This is accomplished through the following changes:
      
      * New structs `AttrAnnotatedTokenStream` and `AttrAnnotatedTokenTree` are introduced.
        These are very similar to a normal `TokenTree`, but they also track
        the position of attributes and attribute targets within the stream.
        They are built when we collect tokens during parsing.
        An `AttrAnnotatedTokenStream` is converted to a regular `TokenStream` when
        we invoke a macro.
      * Token capturing and `LazyTokenStream` are modified to work with
        `AttrAnnotatedTokenStream`. A new `ReplaceRange` type is introduced, which
        is created during the parsing of a nested AST node to make the 'outer'
        AST node aware of the attributes and attribute target stored deeper in the token stream.
      * When we need to perform eager cfg-expansion (either due to `#[derive]` or `#[cfg_eval]`),
      we tokenize and reparse our target, capturing additional information about the locations of
      `#[cfg]` and `#[cfg_attr]` attributes at any depth within the target.
      This is a performance optimization, allowing us to perform less work
      in the typical case where captured tokens never have eager cfg-expansion run.
      a93c4f05
    • T
      Match against attribute name when validating attributes · 985ae0b5
      Tomasz Miąsko 提交于
      Extract attribute name once and match it against symbols that are being
      validated, instead of using `Session::check_name` for each symbol
      individually.
      
      Assume that all validated attributes are used, instead of marking them
      as such, since the attribute check should be exhaustive.
      985ae0b5
    • A
      Expand derive invocations in left-to-right order · 21e6cc19
      Aaron Hill 提交于
      While derives were being collected in left-to-order order, the
      corresponding `Invocation`s were being pushed in the wrong order.
      21e6cc19
    • A
      Add `bad_asm_style` to HardwiredLints · e9d3085c
      Amanieu d'Antras 提交于
      e9d3085c
  11. 10 4月, 2021 1 次提交