rrevenantt / antlr4rust

ANTLR4 parser generator runtime for Rust programming laguage
Other
398 stars 70 forks source link

antlr does not compile due to depricated raw feature #25

Closed jessberg closed 3 years ago

jessberg commented 3 years ago

If one uses nightly <=1.53, this crate compiles and works as expected. However, once the switch is made to 1.55, it no longer works and gives the error

 error[E0635]: unknown feature `raw`
 --> /home/runner/.cargo/registry/src/github.com-1ecc6299db9ec823/antlr-rust-0.2.0/src/lib.rs:4:12
  |
4 | #![feature(raw)]
  | 

I am importing this crate through

antlr-rust = "=0.2"

as mentioned in the readme.

I believe the error is because as mentioned here in the Rust documentation, the raw feature has been deprecated. Can this be updated so antlr doesn't use the raw feature?

newca12 commented 3 years ago

It seem that this feature is not even use. Unfortunatly Rust cannot actually detect unused feature : https://github.com/rust-lang/rust/issues/44232 Until the author publish a version without this unfortunate feature included, you can remove it yourself locally and add the local dependency to your project.

[dependencies]
antlr-rust = { path = "../antlr4/runtime/Rust" }
jessberg commented 3 years ago

That worked for me - thanks!