Closed
Conversation
Take a new struct Variables instead of two &mut [] vectors for static and dynamic variables.
Replace all potentially-failing operations with Err returns and add tests. Remove the Char parameter type; characters are represented as Numbers. Fix integer constants to work properly when there are multiple constants in the same capability string. Tweak loop to use iterators instead of indexing into cap.
Implement the %?, %t, %e, and %; operators. Also implement the %<, %=, %> operators, without which conditionals aren't very useful. Fix the order of parameters for the arithmetic operators. Implement the missing %^ operator.
Contributor
Author
|
r? @thestinger |
bors
added a commit
that referenced
this pull request
Jun 15, 2013
Implement conditional support in terminfo, along with a few other related operators. Fix implementation of non-commutative arithmetic operators. Remove all known cases of task failure from `terminfo::parm::expand`, and change the method signature. Fix some other miscellaneous issues.
Contributor
There was a problem hiding this comment.
It's a bit late for this, but does this do the correct thing? I would've though the copy means that mparams[0] and mparams[1] are not modified by the +='s below.
Contributor
Author
There was a problem hiding this comment.
Hah, good point. I don't think the tests covered this case.
flip1995
pushed a commit
to flip1995/rust
that referenced
this pull request
May 20, 2021
Add `needless_bitwise_bool` lint fixes rust-lang#6827 fixes rust-lang#1594 changelog: Add ``[`needless_bitwise_bool`]`` lint Creates a new `bitwise_bool` lint to convert `x & y` to `x && y` when both `x` and `y` are booleans. I also had to adjust thh `needless_bool` lint slightly, and fix a couple failing dogfood tests. I made it a correctness lint as per flip1995's comment [here](rust-lang/rust-clippy#3385 (comment)), from a previous WIP attempt at this lint.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implement conditional support in terminfo, along with a few other related operators.
Fix implementation of non-commutative arithmetic operators.
Remove all known cases of task failure from
terminfo::parm::expand, and change the method signature.Fix some other miscellaneous issues.