J-F-Liu / pom

PEG parser combinators using operator overloading without macros.
MIT License
496 stars 30 forks source link

POM isn't building on latest Rust nightly… #19

Closed bwinton closed 6 years ago

bwinton commented 6 years ago

nightly-x86_64-unknown-linux-gnu - rustc 1.27.0-nightly (9fae15374 2018-05-13)


  --> /home/bwinton/.cargo/registry/src/github.com-1ecc6299db9ec823/pom-2.0.0/src/set.rs:34:32
   |
34 |         (self as &Range<T>).contains(*elem)
   |                                      ^^^^^
   |                                      |
   |                                      expected &T, found type parameter
   |                                      help: consider borrowing here: `&*elem`
   |
   = note: expected type `&T`
              found type `T`

error[E0308]: mismatched types
  --> /home/bwinton/.cargo/registry/src/github.com-1ecc6299db9ec823/pom-2.0.0/src/set.rs:40:36
   |
40 |         (self as &RangeFrom<T>).contains(*elem)
   |                                          ^^^^^
   |                                          |
   |                                          expected &T, found type parameter
   |                                          help: consider borrowing here: `&*elem`
   |
   = note: expected type `&T`
              found type `T`

error[E0308]: mismatched types
  --> /home/bwinton/.cargo/registry/src/github.com-1ecc6299db9ec823/pom-2.0.0/src/set.rs:46:34
   |
46 |         (self as &RangeTo<T>).contains(*elem)
   |                                        ^^^^^
   |                                        |
   |                                        expected &T, found type parameter
   |                                        help: consider borrowing here: `&*elem`
   |
   = note: expected type `&T`
              found type `T`

error: aborting due to 3 previous errors

For more information about this error, try `rustc --explain E0308`.
error: Could not compile `pom`.```
J-F-Liu commented 6 years ago

Since impl Trait is stabilized, I'm considering target Rust 1.26.

J-F-Liu commented 6 years ago

Fixed.