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

refactor: replace format! with concat! for string literals #2012

Merged
merged 2 commits into from
Dec 9, 2024

Conversation

Integral-Tech
Copy link
Contributor

  • Although format! macro is very powerful, it introduces overhead of memory allocation on the heap compared to &str. Therefore, when format! macro is unnecessary, we should avoid using it.

yazi-dds/src/body/hi.rs Outdated Show resolved Hide resolved
@Integral-Tech
Copy link
Contributor Author

@sxyazi Done :)

yazi-dds/src/body/hey.rs Outdated Show resolved Hide resolved
@sxyazi sxyazi force-pushed the main branch 2 times, most recently from 1394fb4 to 62ac224 Compare December 9, 2024 02:28
Copy link
Owner

@sxyazi sxyazi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@sxyazi sxyazi changed the title refactor: replace format! with concat! for string literals refactor: replace format! with concat! for string literals Dec 9, 2024
@sxyazi sxyazi merged commit a743488 into sxyazi:main Dec 9, 2024
6 checks passed
@Integral-Tech Integral-Tech deleted the format-concat branch December 9, 2024 13:25
tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Dec 11, 2024
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [sxyazi/yazi](https://github.com/sxyazi/yazi) | patch | `v0.4.0` -> `v0.4.1` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>sxyazi/yazi (sxyazi/yazi)</summary>

### [`v0.4.1`](https://github.com/sxyazi/yazi/releases/tag/v0.4.1)

[Compare Source](sxyazi/yazi@v0.4.0...v0.4.1)

This is a quick patch version with 4 fixes:

-   Fixed an issue where Yazi would freeze when waiting for terminal response, in old tmux versions (v3.2a or lower), or 2-layer nested terminal setup (tmux -> Neovim's `:terminal` -> Yazi).
-   Fixed a bug in the Überzug++ backend where certain image dimension parsing failed, preventing images from displaying.
-   Fixed a build failure for Android 32-bit architectures.
-   Fixed an issue with the preset `archive` and `json` plugins not handling CRLF properly on Windows.

#### What's Changed

-   fix: disable passthrough when the user launches Yazi in Neovim inside tmux by [@&#8203;sxyazi](https://github.com/sxyazi) in sxyazi/yazi#2014
-   refactor: replace `format!` with `concat!` for string literals by [@&#8203;Integral-Tech](https://github.com/Integral-Tech) in sxyazi/yazi#2012
-   fix: correctly handle CRLF on Windows in preset `archive` and `json` plugins by [@&#8203;sxyazi](https://github.com/sxyazi) in sxyazi/yazi#2017
-   fix: failed to parse certain image dimensions for Überzug++ backend by [@&#8203;sxyazi](https://github.com/sxyazi) in sxyazi/yazi#2020
-   chore: bump version to 0.4.1 by [@&#8203;sxyazi](https://github.com/sxyazi) in sxyazi/yazi#2022

**Full Changelog**: sxyazi/yazi@v0.4.0...v0.4.1

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40NDAuNyIsInVwZGF0ZWRJblZlciI6IjM3LjQ0MC43IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJSZW5vdmF0ZSBCb3QiXX0=-->
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 9, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants