Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix unused code warnings #1087

Merged
merged 1 commit into from
Feb 27, 2022
Merged

Conversation

orhun
Copy link
Contributor

@orhun orhun commented Feb 22, 2022

This PR is doing what title suggests 🐻

I came across this while updating the Arch Linux package and thought they should be fixed :)

Log:

warning: field is never read: `rows`
  --> zellij-server/src/ui/overlay/mod.rs:27:5
   |
27 |     rows: usize,
   |     ^^^^^^^^^^^
   |
   = note: `#[warn(dead_code)]` on by default

warning: field is never read: `cols`
  --> zellij-server/src/ui/overlay/mod.rs:28:5
   |
28 |     cols: usize,
   |     ^^^^^^^^^^^

warning: field is never read: `plugin_own_data_dir`
  --> zellij-server/src/wasm_vm.rs:76:5
   |
76 |     plugin_own_data_dir: PathBuf,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: `zellij-server` (lib) generated 3 warnings

@orhun orhun changed the title refactor: fix unused code warnings Fix unused code warnings Feb 22, 2022
@imsnif
Copy link
Member

imsnif commented Feb 24, 2022

Thanks @orhun - you are always super fast updating the Arch version!

@a-kenji - if I'm not mistaken this is part of some ongoing work you're doing. Are you still counting on this? Maybe we can add a dead_code exception as @ken-matsui suggested instead?

@jaeheonji
Copy link
Member

@imsnif Oh.. I didn't know this @a-kenji was working on. So I suggested to @ken-matsui that getting rid of this is better than using dead_code.

If this is part of @a-kenji work, it would be good to include dead_code.

@a-kenji
Copy link
Contributor

a-kenji commented Feb 27, 2022

@orhun,
Yes it is part of some work I am doing, but it is fine to delete it for now, since I think I wont have merge conflicts inside the file.

I do recommend however to apply the dead code to the plugin data dir, since that is something that Brooks is still working on.

@orhun
Copy link
Contributor Author

orhun commented Feb 27, 2022

I do recommend however to apply the dead code to the plugin data dir, since that is something that Brooks is still working on.

Done! 631fa06

@a-kenji
Copy link
Contributor

a-kenji commented Feb 27, 2022

@orhun,
Awesome, thanks!

@a-kenji a-kenji merged commit 4d64742 into zellij-org:main Feb 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants