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

bug: change as_ref() calls as needed to build in Rust beta 1.61.0 #711

Merged
merged 2 commits into from
Apr 27, 2022

Conversation

ClementTsang
Copy link
Owner

@ClementTsang ClementTsang commented Apr 27, 2022

Description

A description of the change and what it does. If relevant (such as any change that modifies the UI), please provide screenshots of the change:

This changes various as_ref() calls as needed in order for bottom to successfully build in Rust beta 1.61, as they were causing type inference issues. These calls were either removed or changed to an alternative that does build (e.g. as_slice()).

Functionally, there should be no change.

Issue

If applicable, what issue does this address?

Closes: #708

Testing

If relevant, please state how this was tested. All changes must be tested to work:

Please also indicate which platforms were tested. All platforms directly affected by the change must be tested:

  • Windows
  • macOS
  • Linux

Checklist

If relevant, ensure the following have been met:

  • Areas your change affects have been linted using rustfmt (cargo fmt)
  • The change has been tested and doesn't appear to cause any unintended breakage
  • Documentation has been added/updated if needed (README.md, help menu, etc.)
  • The pull request passes the provided CI pipeline
  • There are no merge conflicts

@codecov-commenter
Copy link

codecov-commenter commented Apr 27, 2022

Codecov Report

Merging #711 (f5bd095) into master (6fa04de) will decrease coverage by 0.00%.
The diff coverage is 6.09%.

❗ Current head f5bd095 differs from pull request most recent head 86918a2. Consider uploading reports for the commit 86918a2 to get more accurate results

@@            Coverage Diff            @@
##           master    #711      +/-   ##
=========================================
- Coverage    7.84%   7.84%   -0.01%     
=========================================
  Files          53      53              
  Lines        8269    8274       +5     
=========================================
  Hits          649     649              
- Misses       7620    7625       +5     
Impacted Files Coverage Δ
src/app.rs 0.00% <0.00%> (ø)
src/app/data_farmer.rs 0.00% <0.00%> (ø)
src/canvas.rs 0.00% <0.00%> (ø)
src/canvas/dialogs/dd_dialog.rs 0.00% <0.00%> (ø)
src/canvas/widgets/battery_display.rs 0.00% <0.00%> (ø)
src/canvas/widgets/cpu_basic.rs 0.00% <0.00%> (ø)
src/canvas/widgets/cpu_graph.rs 0.00% <0.00%> (ø)
src/canvas/widgets/disk_table.rs 0.00% <0.00%> (ø)
src/canvas/widgets/mem_graph.rs 0.00% <0.00%> (ø)
src/canvas/widgets/network_graph.rs 0.00% <0.00%> (ø)
... and 5 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2b893ea...86918a2. Read the comment docs.

@ClementTsang ClementTsang force-pushed the avoid_as_ref branch 2 times, most recently from f1ee90c to f5bd095 Compare April 27, 2022 22:24
For context, see:
- #708
- rust-lang/rust#96074

This changes the calls from `as_ref()`, which was causing type
inference issues, to just `as_slice()` which works fine.
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.

Failed to install in rust 1.61.0-beta.4
2 participants