rustwasm / wasm-bindgen

Facilitating high-level interactions between Wasm modules and JavaScript

Home Page:https://rustwasm.github.io/docs/wasm-bindgen/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`wasm-bindgen` appears to trigger new `clippy` lint `clippy::empty_docs`

kflansburg opened this issue · comments

Summary

From what I can tell, Rust 1.78 introduced some new clippy lints that appear to be triggering within the wasm-bindgen macro.

warning: empty doc comment
 --> worker-sys/src/ext/abort_controller.rs:6:5
  |
6 |     #[wasm_bindgen]
  |     ^^^^^^^^^^^^^^^
  |
  = help: consider removing or filling it
  = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_docs
  = note: `#[warn(clippy::empty_docs)]` on by default
  = note: this warning originates in the attribute macro `wasm_bindgen` (in Nightly builds, run with -Z macro-backtrace for more info)

Same with tsify

error: empty doc comment
  --> [RUST_FILE]:11:10
   |
11 | #[derive(Tsify, Serialize, Deserialize, Debug, Clone)]
   |          ^^^^^
   |
   = help: consider removing or filling it
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#empty_docs
   = note: this error originates in the attribute macro `wasm_bindgen` (in Nightly builds, run with -Z macro-backtrace for more info)

+1. cargo expand suggests an empty docstring is generated both for structures and each of their methods.