lua-rs icon indicating copy to clipboard operation
lua-rs copied to clipboard

error[E0277]: the trait bound `u8: Buf` is not satisfied

Open Mte90 opened this issue 5 years ago • 2 comments

I get this error trying on compile that tool:

error[E0277]: the trait bound `u8: Buf` is not satisfied
   --> src/scanner.rs:257:25
    |
257 |         self.buffer.put(c as u8)
    |                         ^^^^^^^ the trait `Buf` is not implemented for `u8`

warning: unreachable expression
   --> src/scanner.rs:352:9
    |
314 | /         loop {
315 | |             match self.current {
316 | |                 EOF => {
317 | |                     if is_comment {
...   |
350 | |             }
351 | |         }
    | |_________- any code following this expression is unreachable
352 |           unreachable!()
    |           ^^^^^^^^^^^^^^ unreachable expression
    |
    = note: `#[warn(unreachable_code)]` on by default
    = note: this warning originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)

error: aborting due to previous error; 1 warning emitted

Mte90 avatar Jan 16 '21 16:01 Mte90

I encountered the same problem.

imjdl avatar Feb 03 '21 10:02 imjdl

me toooooooo~~~ i got the same problem. 💯

rhettli avatar Mar 10 '21 02:03 rhettli