Skip to content

Fix argument types in expansion of bytecode-callable functions #229

Fix argument types in expansion of bytecode-callable functions

Fix argument types in expansion of bytecode-callable functions #229

Triggered via pull request August 27, 2023 15:47
Status Success
Total duration 2m 56s
Artifacts

clippy.yml

on: pull_request
Matrix: clippy
Fit to window
Zoom out
Zoom in

Annotations

24 warnings
this argument is a mutable reference, but not used mutably: src/memory.rs#L218
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:218:9 | 218 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L200
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:200:34 | 200 | pub fn alloc_box<A: 'static>(cr: &mut OCamlRuntime, data: A) -> OCaml<DynBox<A>> { | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L152
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:152:9 | 152 | cr: &mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L138
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:138:9 | 138 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = warning: changing this function will impact semver compatibility = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L129
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:129:34 | 129 | pub unsafe fn alloc_tuple<T>(cr: &mut OCamlRuntime, size: usize) -> OCaml<T> { | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = warning: changing this function will impact semver compatibility = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L118
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:118:9 | 118 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L107
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:107:9 | 107 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L96
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:96:9 | 96 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L87
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:87:25 | 87 | pub fn alloc_double(cr: &mut OCamlRuntime, d: f64) -> OCaml<OCamlFloat> { | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L83
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:83:24 | 83 | pub fn alloc_int64(cr: &mut OCamlRuntime, i: i64) -> OCaml<OCamlInt64> { | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L79
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:79:24 | 79 | pub fn alloc_int32(cr: &mut OCamlRuntime, i: i32) -> OCaml<OCamlInt32> { | ^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L69
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:69:29 | 69 | pub fn alloc_string<'a>(cr: &'a mut OCamlRuntime, s: &str) -> OCaml<'a, String> { | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/memory.rs#L59
warning: this argument is a mutable reference, but not used mutably --> src/memory.rs:59:28 | 59 | pub fn alloc_bytes<'a>(cr: &'a mut OCamlRuntime, s: &[u8]) -> OCaml<'a, OCamlBytes> { | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
this argument is a mutable reference, but not used mutably: src/closure.rs#L70
warning: this argument is a mutable reference, but not used mutably --> src/closure.rs:70:13 | 70 | cr: &'a mut OCamlRuntime, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&OCamlRuntime` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut = note: `#[warn(clippy::needless_pass_by_ref_mut)]` on by default
the following explicit lifetimes could be elided: 'b: src/memory.rs#L117
warning: the following explicit lifetimes could be elided: 'b --> src/memory.rs:117:24 | 117 | pub fn alloc_error<'a, 'b, A, Err>( | ^^ 118 | cr: &'a mut OCamlRuntime, 119 | err: OCamlRef<'b, Err>, | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 117 ~ pub fn alloc_error<'a, A, Err>( 118 | cr: &'a mut OCamlRuntime, 119 ~ err: OCamlRef<'_, Err>, |
the following explicit lifetimes could be elided: 'b: src/memory.rs#L106
warning: the following explicit lifetimes could be elided: 'b --> src/memory.rs:106:21 | 106 | pub fn alloc_ok<'a, 'b, A, Err>( | ^^ 107 | cr: &'a mut OCamlRuntime, 108 | value: OCamlRef<'b, A>, | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes help: elide the lifetimes | 106 ~ pub fn alloc_ok<'a, A, Err>( 107 | cr: &'a mut OCamlRuntime, 108 ~ value: OCamlRef<'_, A>, |
the following explicit lifetimes could be elided: 'b: src/memory.rs#L95
warning: the following explicit lifetimes could be elided: 'b --> src/memory.rs:95:23 | 95 | pub fn alloc_some<'a, 'b, A>( | ^^ 96 | cr: &'a mut OCamlRuntime, 97 | value: OCamlRef<'b, A>, | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes = note: `#[warn(clippy::needless_lifetimes)]` on by default help: elide the lifetimes | 95 ~ pub fn alloc_some<'a, A>( 96 | cr: &'a mut OCamlRuntime, 97 ~ value: OCamlRef<'_, A>, |
docs for unsafe trait missing `# Safety` section: src/conv/to_ocaml.rs#L22
warning: docs for unsafe trait missing `# Safety` section --> src/conv/to_ocaml.rs:22:1 | 22 | pub unsafe trait ToOCaml<T> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc
docs for unsafe trait missing `# Safety` section: src/conv/from_ocaml.rs#L10
warning: docs for unsafe trait missing `# Safety` section --> src/conv/from_ocaml.rs:10:1 | 10 | pub unsafe trait FromOCaml<T> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc = note: `#[warn(clippy::missing_safety_doc)]` on by default
clippy (ubuntu-latest, 4.14.1)
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions/cache@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 (ubuntu-latest, 4.14.1)
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 (ubuntu-latest, 4.14.1)
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 (ubuntu-latest, 4.14.1)
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 (ubuntu-latest, 4.14.1)
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/