Skip to content

feat: enum example #136

feat: enum example

feat: enum example #136

Triggered via push September 25, 2023 16:45
Status Failure
Total duration 3m 40s
Artifacts

checks.yml

on: push
Fit to window
Zoom out
Zoom in

Annotations

4 errors and 112 warnings
fmt
The process '/home/runner/.cargo/bin/cargo' failed with exit code 1
useless lint attribute: parser/src/parsers/mod.rs#L14
error: useless lint attribute --> parser/src/parsers/mod.rs:14:1 | 14 | #[allow(ambiguous_glob_reexports)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: if you just forgot a `!`, use: `#![allow(ambiguous_glob_reexports)]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_attribute = note: `#[deny(clippy::useless_attribute)]` on by default
useless lint attribute: parser/src/parsers/mod.rs#L14
error: useless lint attribute --> parser/src/parsers/mod.rs:14:1 | 14 | #[allow(ambiguous_glob_reexports)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: if you just forgot a `!`, use: `#![allow(ambiguous_glob_reexports)]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_attribute = note: `#[deny(clippy::useless_attribute)]` on by default
clippy
Clippy had exited with the 101 exit code
fmt
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
this expression creates a reference which is immediately dereferenced by the compiler: parser/src/parsers/expr.rs#L35
warning: this expression creates a reference which is immediately dereferenced by the compiler --> parser/src/parsers/expr.rs:35:30 | 35 | if Operator::is_binary(&op) && op.get_prec() <= prec { | ^^^ help: change this to: `op` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow = note: `#[warn(clippy::needless_borrow)]` on by default
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L362
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:362:40 | 362 | ProgramStmt::Tip { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L361
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:361:41 | 361 | ProgramStmt::Stmt { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L360
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:360:45 | 360 | ProgramStmt::TypeDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L359
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:359:47 | 359 | ProgramStmt::StructDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L358
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:358:44 | 358 | ProgramStmt::ValDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L357
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:357:44 | 357 | ProgramStmt::VarDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L356
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:356:49 | 356 | ProgramStmt::FunctionDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L355
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:355:43 | 355 | ProgramStmt::Extern { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L354
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:354:43 | 354 | ProgramStmt::Import { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L292
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:292:36 | 292 | Stmt::Assign { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L291
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:291:34 | 291 | Stmt::Expr { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L290
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:290:33 | 290 | Stmt::Tip { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L289
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:289:35 | 289 | Stmt::Block { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L288
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:288:37 | 288 | Stmt::ValDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L287
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:287:37 | 287 | Stmt::VarDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L286
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:286:36 | 286 | Stmt::Return { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L285
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:285:35 | 285 | Stmt::Break { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L284
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:284:38 | 284 | Stmt::Continue { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L283
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:283:35 | 283 | Stmt::While { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L282
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:282:32 | 282 | Stmt::If { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L221
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:221:39 | 221 | IdentVal::Slice { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L220
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:220:39 | 220 | IdentVal::Index { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L219
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:219:43 | 219 | IdentVal::Arguments { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L218
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:218:42 | 218 | IdentVal::Selector { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L149
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:149:34 | 149 | Expr::Cond { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L148
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:148:36 | 148 | Expr::Binary { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L147
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:147:35 | 147 | Expr::Unary { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy = note: `#[warn(clippy::clone_on_copy)]` on by default
writing `&Vec` instead of `&[_]` involves a new object where a slice will do: ast/src/lib.rs#L102
warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do --> ast/src/lib.rs:102:29 | 102 | pub fn vec_to_type(types: &Vec<IdentTyped>) -> Vec<TypedIdent> { | ^^^^^^^^^^^^^^^^ help: change this to: `&[IdentTyped]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg
writing `&Vec` instead of `&[_]` involves a new object where a slice will do: ast/src/lib.rs#L73
warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do --> ast/src/lib.rs:73:29 | 73 | pub fn vec_to_type(types: &Vec<IdentType>) -> Vec<Type> { | ^^^^^^^^^^^^^^^ help: change this to: `&[IdentType]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg = note: `#[warn(clippy::ptr_arg)]` on by default
single-character string constant used as pattern: preprocessor/src/lib.rs#L66
warning: single-character string constant used as pattern --> preprocessor/src/lib.rs:66:32 | 66 | if file_name.starts_with("@") { | ^^^ help: try using a `char` instead: `'@'` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern = note: `#[warn(clippy::single_char_pattern)]` on by default
this `match` can be collapsed into the outer `match`: preprocessor/src/lib.rs#L45
warning: this `match` can be collapsed into the outer `match` --> preprocessor/src/lib.rs:45:34 | 45 | Token::Literal(lit) => match lit { | __________________________________^ 46 | | Literal::Str(s) => s, 47 | | _ => { 48 | | return self ... | 51 | | } 52 | | }, | |___________^ | help: the outer pattern can be modified to include the inner pattern --> preprocessor/src/lib.rs:45:26 | 45 | Token::Literal(lit) => match lit { | ^^^ replace this binding 46 | Literal::Str(s) => s, | ^^^^^^^^^^^^^^^ with this pattern = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match = note: `#[warn(clippy::collapsible_match)]` on by default
deref which would be done by auto-deref: lexer/src/lib.rs#L363
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:363:22 | 363 | inner.push_str(&*string); | ^^^^^^^^ help: try this: `&string` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L348
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:348:9 | 348 | &*dec, | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L342
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:342:62 | 342 | Ok(Token::Literal(Literal::Int(Lexer::usize_from_hex(&*hex)))) | ^^^^^ help: try this: `&hex` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L336
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:336:64 | 336 | Ok(Token::Literal(Literal::Int(Lexer::usize_from_octal(&*oct)))) | ^^^^^ help: try this: `&oct` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L329
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:329:11 | 329 | &*bin, | ^^^^^ help: try this: `&bin` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L302
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:302:28 | 302 | float.push_str(&*dec); | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L282
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:282:26 | 282 | float.push_str(&*dec); | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L276
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:276:22 | 276 | float.push_str(&*start); | ^^^^^^^ help: try this: `&start` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L139
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:139:24 | 139 | inner.push_str(&*string); | ^^^^^^^^ help: try this: `&string` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref = note: `#[warn(clippy::explicit_auto_deref)]` on by default
deref on an immutable reference: lexer/src/lib.rs#L61
warning: deref on an immutable reference --> lexer/src/lib.rs:61:27 | 61 | usize::from_str_radix(&*hex, 16).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `hex` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref
deref on an immutable reference: lexer/src/lib.rs#L57
warning: deref on an immutable reference --> lexer/src/lib.rs:57:27 | 57 | usize::from_str_radix(&*oct, 8).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `oct` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref
deref on an immutable reference: lexer/src/lib.rs#L53
warning: deref on an immutable reference --> lexer/src/lib.rs:53:27 | 53 | usize::from_str_radix(&*bin, 2).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `bin` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref = note: `#[warn(clippy::borrow_deref_ref)]` on by default
you should consider adding a `Default` implementation for `DiagnosticHandler`: common/src/error/mod.rs#L25
warning: you should consider adding a `Default` implementation for `DiagnosticHandler` --> common/src/error/mod.rs:25:3 | 25 | / pub fn new() -> Self { 26 | | Self { 27 | | errors: Vec::new(), 28 | | warnings: Vec::new(), 29 | | } 30 | | } | |___^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default = note: `#[warn(clippy::new_without_default)]` on by default help: try adding this | 24 + impl Default for DiagnosticHandler { 25 + fn default() -> Self { 26 + Self::new() 27 + } 28 + } |
this expression creates a reference which is immediately dereferenced by the compiler: parser/src/parsers/expr.rs#L35
warning: this expression creates a reference which is immediately dereferenced by the compiler --> parser/src/parsers/expr.rs:35:30 | 35 | if Operator::is_binary(&op) && op.get_prec() <= prec { | ^^^ help: change this to: `op` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow = note: `#[warn(clippy::needless_borrow)]` on by default
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L362
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:362:40 | 362 | ProgramStmt::Tip { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L361
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:361:41 | 361 | ProgramStmt::Stmt { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L360
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:360:45 | 360 | ProgramStmt::TypeDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L359
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:359:47 | 359 | ProgramStmt::StructDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L358
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:358:44 | 358 | ProgramStmt::ValDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L357
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:357:44 | 357 | ProgramStmt::VarDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L356
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:356:49 | 356 | ProgramStmt::FunctionDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L355
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:355:43 | 355 | ProgramStmt::Extern { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L354
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:354:43 | 354 | ProgramStmt::Import { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L292
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:292:36 | 292 | Stmt::Assign { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L291
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:291:34 | 291 | Stmt::Expr { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L290
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:290:33 | 290 | Stmt::Tip { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L289
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:289:35 | 289 | Stmt::Block { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L288
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:288:37 | 288 | Stmt::ValDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L287
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:287:37 | 287 | Stmt::VarDecl { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L286
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:286:36 | 286 | Stmt::Return { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L285
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:285:35 | 285 | Stmt::Break { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L284
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:284:38 | 284 | Stmt::Continue { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L283
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:283:35 | 283 | Stmt::While { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L282
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:282:32 | 282 | Stmt::If { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L221
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:221:39 | 221 | IdentVal::Slice { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L220
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:220:39 | 220 | IdentVal::Index { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L219
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:219:43 | 219 | IdentVal::Arguments { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L218
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:218:42 | 218 | IdentVal::Selector { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L149
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:149:34 | 149 | Expr::Cond { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L148
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:148:36 | 148 | Expr::Binary { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy
using `clone` on type `Span` which implements the `Copy` trait: ast/src/lib.rs#L147
warning: using `clone` on type `Span` which implements the `Copy` trait --> ast/src/lib.rs:147:35 | 147 | Expr::Unary { span, .. } => span.clone(), | ^^^^^^^^^^^^ help: try dereferencing it: `*span` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#clone_on_copy = note: `#[warn(clippy::clone_on_copy)]` on by default
writing `&Vec` instead of `&[_]` involves a new object where a slice will do: ast/src/lib.rs#L102
warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do --> ast/src/lib.rs:102:29 | 102 | pub fn vec_to_type(types: &Vec<IdentTyped>) -> Vec<TypedIdent> { | ^^^^^^^^^^^^^^^^ help: change this to: `&[IdentTyped]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg
writing `&Vec` instead of `&[_]` involves a new object where a slice will do: ast/src/lib.rs#L73
warning: writing `&Vec` instead of `&[_]` involves a new object where a slice will do --> ast/src/lib.rs:73:29 | 73 | pub fn vec_to_type(types: &Vec<IdentType>) -> Vec<Type> { | ^^^^^^^^^^^^^^^ help: change this to: `&[IdentType]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#ptr_arg = note: `#[warn(clippy::ptr_arg)]` on by default
single-character string constant used as pattern: preprocessor/src/lib.rs#L66
warning: single-character string constant used as pattern --> preprocessor/src/lib.rs:66:32 | 66 | if file_name.starts_with("@") { | ^^^ help: try using a `char` instead: `'@'` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern = note: `#[warn(clippy::single_char_pattern)]` on by default
this `match` can be collapsed into the outer `match`: preprocessor/src/lib.rs#L45
warning: this `match` can be collapsed into the outer `match` --> preprocessor/src/lib.rs:45:34 | 45 | Token::Literal(lit) => match lit { | __________________________________^ 46 | | Literal::Str(s) => s, 47 | | _ => { 48 | | return self ... | 51 | | } 52 | | }, | |___________^ | help: the outer pattern can be modified to include the inner pattern --> preprocessor/src/lib.rs:45:26 | 45 | Token::Literal(lit) => match lit { | ^^^ replace this binding 46 | Literal::Str(s) => s, | ^^^^^^^^^^^^^^^ with this pattern = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match = note: `#[warn(clippy::collapsible_match)]` on by default
deref which would be done by auto-deref: lexer/src/lib.rs#L363
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:363:22 | 363 | inner.push_str(&*string); | ^^^^^^^^ help: try this: `&string` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L348
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:348:9 | 348 | &*dec, | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L342
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:342:62 | 342 | Ok(Token::Literal(Literal::Int(Lexer::usize_from_hex(&*hex)))) | ^^^^^ help: try this: `&hex` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L336
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:336:64 | 336 | Ok(Token::Literal(Literal::Int(Lexer::usize_from_octal(&*oct)))) | ^^^^^ help: try this: `&oct` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L329
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:329:11 | 329 | &*bin, | ^^^^^ help: try this: `&bin` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L302
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:302:28 | 302 | float.push_str(&*dec); | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L282
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:282:26 | 282 | float.push_str(&*dec); | ^^^^^ help: try this: `&dec` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L276
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:276:22 | 276 | float.push_str(&*start); | ^^^^^^^ help: try this: `&start` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
deref which would be done by auto-deref: lexer/src/lib.rs#L139
warning: deref which would be done by auto-deref --> lexer/src/lib.rs:139:24 | 139 | inner.push_str(&*string); | ^^^^^^^^ help: try this: `&string` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref = note: `#[warn(clippy::explicit_auto_deref)]` on by default
deref on an immutable reference: lexer/src/lib.rs#L61
warning: deref on an immutable reference --> lexer/src/lib.rs:61:27 | 61 | usize::from_str_radix(&*hex, 16).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `hex` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref
deref on an immutable reference: lexer/src/lib.rs#L57
warning: deref on an immutable reference --> lexer/src/lib.rs:57:27 | 57 | usize::from_str_radix(&*oct, 8).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `oct` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref
deref on an immutable reference: lexer/src/lib.rs#L53
warning: deref on an immutable reference --> lexer/src/lib.rs:53:27 | 53 | usize::from_str_radix(&*bin, 2).unwrap() | ^^^^^ help: if you would like to reborrow, try removing `&*`: `bin` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#borrow_deref_ref = note: `#[warn(clippy::borrow_deref_ref)]` on by default
you should consider adding a `Default` implementation for `DiagnosticHandler`: common/src/error/mod.rs#L25
warning: you should consider adding a `Default` implementation for `DiagnosticHandler` --> common/src/error/mod.rs:25:3 | 25 | / pub fn new() -> Self { 26 | | Self { 27 | | errors: Vec::new(), 28 | | warnings: Vec::new(), 29 | | } 30 | | } | |___^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default = note: `#[warn(clippy::new_without_default)]` on by default help: try adding this | 24 + impl Default for DiagnosticHandler { 25 + fn default() -> Self { 26 + Self::new() 27 + } 28 + } |
clippy
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
test
some crates are on edition 2021 which defaults to `resolver = "2"`, but virtual workspaces default to `resolver = "1"`
check
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
check
some crates are on edition 2021 which defaults to `resolver = "2"`, but virtual workspaces default to `resolver = "1"`
check
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
check
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
check
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
check
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/