Skip to content

Add DrawSettings::new() #441

Add DrawSettings::new()

Add DrawSettings::new() #441

Triggered via pull request June 22, 2024 13:11
Status Success
Total duration 1m 18s
Artifacts

rust.yml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

14 warnings
initializer for `thread_local` value can be made `const`: src/sl.rs#L107
warning: initializer for `thread_local` value can be made `const` --> src/sl.rs:107:65 | 107 | static MAP: RefCell<BTreeMap<TypeId, Rc<StructType>>> = RefCell::new(BTreeMap::new()); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace with: `const { RefCell::new(BTreeMap::new()) }` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#thread_local_initializer_can_be_made_const = note: `#[warn(clippy::thread_local_initializer_can_be_made_const)]` on by default
docs for unsafe trait missing `# Safety` section: src/sl/sig.rs#L8
warning: docs for unsafe trait missing `# Safety` section --> src/sl/sig.rs:8:1 | 8 | pub unsafe trait Const {} | ^^^^^^^^^^^^^^^^^^^^^^ | = 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/sl/interpolant.rs#L13
warning: docs for unsafe trait missing `# Safety` section --> src/sl/interpolant.rs:13:1 | 13 | pub unsafe trait Interpolant: Value { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = 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
match expression looks like `matches!` macro: src/gl/raw/image.rs#L193
warning: match expression looks like `matches!` macro --> src/gl/raw/image.rs:193:9 | 193 | / match self { 194 | | DepthF32 => true, 195 | | _ => false, 196 | | } | |_________^ help: try: `matches!(self, DepthF32)` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro = note: `#[warn(clippy::match_like_matches_macro)]` on by default
the loop variable `i` is used to index `self`: src/interface/uniform_interface.rs#L204
warning: the loop variable `i` is used to index `self` --> src/interface/uniform_interface.rs:204:18 | 204 | for i in 0..N { | ^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_range_loop = note: `#[warn(clippy::needless_range_loop)]` on by default help: consider using an iterator and enumerate() | 204 | for (i, <item>) in self.iter().enumerate().take(N) { | ~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
function `call_func_def` is never used: src/sl/primitives.rs#L192
warning: function `call_func_def` is never used --> src/sl/primitives.rs:192:8 | 192 | pub fn call_func_def<R: Value>(def: FuncDef, args: Vec<Rc<Expr>>) -> R { | ^^^^^^^^^^^^^
function `built_in_4` is never used: src/sl/primitives.rs#L154
warning: function `built_in_4` is never used --> src/sl/primitives.rs:154:15 | 154 | pub(crate) fn built_in_4<U, V, W, X, R>( | ^^^^^^^^^^
method `is_empty` is never used: src/gl/raw/buffer.rs#L81
warning: method `is_empty` is never used --> src/gl/raw/buffer.rs:81:12 | 40 | impl Buffer { | ----------- method in this implementation ... 81 | pub fn is_empty(&self) -> bool { | ^^^^^^^^ | = note: `#[warn(dead_code)]` on by default
unneeded unit expression: src/sl/interpolant.rs#L86
warning: unneeded unit expression --> src/sl/interpolant.rs:86:17 | 86 | / ( 87 | | $($name::shader_input(&join_ident_path(path, stringify!($name))),)* 88 | | ) | |_________________^ help: remove the final `()` ... 94 | smaller_tuples_too!(tuple_impl, T0, T1, T2, T3, T4, T5, T6, T7); | --------------------------------------------------------------- in this macro invocation | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit = note: `#[warn(clippy::unused_unit)]` on by default = note: this warning originates in the macro `tuple_impl` which comes from the expansion of the macro `smaller_tuples_too` (in Nightly builds, run with -Z macro-backtrace for more info)
useless use of `vec!`: derive/src/utils.rs#L117
warning: useless use of `vec!` --> derive/src/utils.rs:117:24 | 117 | let fragment_tys = vec!["ColorAttachment"]; | ^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `["ColorAttachment"]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec
useless use of `vec!`: derive/src/utils.rs#L115
warning: useless use of `vec!` --> derive/src/utils.rs:115:22 | 115 | let vertex_tys = vec!["Block"]; | ^^^^^^^^^^^^^ help: you can use an array directly: `["Block"]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec = note: `#[warn(clippy::useless_vec)]` on by default
method `attrs` is never used: derive/src/utils.rs#L56
warning: method `attrs` is never used --> derive/src/utils.rs:56:12 | 16 | impl StructFields { | ----------------- method in this implementation ... 56 | pub fn attrs(&self) -> Vec<&[Attribute]> { | ^^^^^ | = note: `#[warn(dead_code)]` on by default
build
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions-rs/clippy-check@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
build
The following actions uses node12 which is deprecated and will be forced to run on node16: 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/