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

Run clippy::pedantic on sway-lsp #5939

Merged
merged 4 commits into from May 1, 2024
Merged

Run clippy::pedantic on sway-lsp #5939

merged 4 commits into from May 1, 2024

Conversation

JoshuaBatty
Copy link
Member

Description

The command I used was cargo clippy -- -W clippy::pedantic -A clippy::must_use_candidate -A clippy::module_name_repetitions -A clippy::missing_errors_doc -A clippy::cast_sign_loss -A clippy::missing_panics_doc -A clippy::cast_possible_truncation -A clippy::doc_markdown

Was actually pretty helpful, will likely run this on other workspace members in the repo also.

No new code, just clippy suggestions.

Checklist

  • I have linked to any relevant issues.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have updated the documentation where relevant (API docs, the reference, and the Sway book).
  • I have added tests that prove my fix is effective or that my feature works.
  • I have added (or requested a maintainer to add) the necessary Breaking* or New Feature labels where relevant.
  • I have done my best to ensure that my PR adheres to the Fuel Labs Code Review Standards.
  • I have requested a review from the relevant team or maintainers.

@JoshuaBatty JoshuaBatty self-assigned this May 1, 2024
@JoshuaBatty JoshuaBatty requested review from a team May 1, 2024 06:22
Copy link

github-actions bot commented May 1, 2024

Benchmark for e9124ad

Click to view benchmark
Test Base PR %
code_action 5.3±0.09ms 5.4±0.20ms +1.89%
code_lens 294.2±10.44ns 339.8±11.46ns +15.50%
compile 6.2±0.04s 6.3±0.09s +1.61%
completion 4.8±0.01ms 4.9±0.06ms +2.08%
did_change_with_caching 6.1±0.04s 6.3±0.12s +3.28%
document_symbol 1005.8±45.27µs 974.2±39.96µs -3.14%
format 87.2±0.59ms 87.4±0.86ms +0.23%
goto_definition 364.4±4.72µs 363.2±10.20µs -0.33%
highlight 8.8±0.22ms 8.7±0.04ms -1.14%
hover 603.5±6.30µs 609.5±14.37µs +0.99%
idents_at_position 124.1±0.54µs 124.4±1.03µs +0.24%
inlay_hints 658.6±10.71µs 657.5±10.08µs -0.17%
on_enter 489.7±13.46ns 479.7±13.96ns -2.04%
parent_decl_at_position 3.6±0.05ms 3.6±0.04ms 0.00%
prepare_rename 354.2±6.31µs 362.7±15.37µs +2.40%
rename 9.2±0.10ms 9.3±0.15ms +1.09%
semantic_tokens 1060.0±13.06µs 1060.9±4.77µs +0.08%
token_at_position 355.3±1.99µs 354.4±2.46µs -0.25%
tokens_at_position 3.6±0.02ms 3.6±0.03ms 0.00%
tokens_for_file 431.0±6.13µs 427.9±1.57µs -0.72%
traverse 48.5±2.54ms 50.6±2.35ms +4.33%

@JoshuaBatty JoshuaBatty requested a review from a team May 1, 2024 07:11
@JoshuaBatty JoshuaBatty enabled auto-merge (squash) May 1, 2024 07:22
Copy link

github-actions bot commented May 1, 2024

Benchmark for c1ac4f1

Click to view benchmark
Test Base PR %
code_action 5.6±0.40ms 5.4±0.27ms -3.57%
code_lens 294.4±18.80ns 339.3±11.99ns +15.25%
compile 6.6±0.22s 6.2±0.04s -6.06%
completion 5.2±0.47ms 4.8±0.07ms -7.69%
did_change_with_caching 6.2±0.05s 6.3±0.06s +1.61%
document_symbol 1018.3±17.42µs 993.9±34.22µs -2.40%
format 91.8±1.55ms 85.5±0.78ms -6.86%
goto_definition 366.7±5.69µs 362.6±5.51µs -1.12%
highlight 9.5±0.65ms 8.7±0.15ms -8.42%
hover 614.4±29.98µs 617.7±16.66µs +0.54%
idents_at_position 122.9±0.37µs 124.1±3.99µs +0.98%
inlay_hints 662.2±31.96µs 652.8±23.57µs -1.42%
on_enter 476.0±15.39ns 491.3±15.29ns +3.21%
parent_decl_at_position 3.6±0.07ms 3.6±0.03ms 0.00%
prepare_rename 360.9±3.55µs 360.2±7.00µs -0.19%
rename 9.7±0.43ms 9.5±0.02ms -2.06%
semantic_tokens 1018.3±16.41µs 1045.8±15.83µs +2.70%
token_at_position 357.3±2.91µs 355.4±4.07µs -0.53%
tokens_at_position 3.6±0.03ms 3.6±0.21ms 0.00%
tokens_for_file 426.5±6.61µs 425.5±9.44µs -0.23%
traverse 50.6±1.96ms 52.2±2.17ms +3.16%

@JoshuaBatty JoshuaBatty merged commit 5a0bbed into master May 1, 2024
37 checks passed
@JoshuaBatty JoshuaBatty deleted the josh/lsp_clippy branch May 1, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants