aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_assists/src/assists/apply_demorgan.rs
Commit message (Collapse)AuthorAgeFilesLines
* use more consistent namingAleksey Kladov2019-10-271-1/+1
| | | | | I think this is the first time I use global rename for rust-analyzer itself :-)
* add blank lines for readabilityAleksey Kladov2019-10-261-0/+2
|
* generate more assists docsAleksey Kladov2019-10-251-9/+17
|
* [#1807] Refactor file structureLúcás Meier2019-10-041-33/+33
| | | | | Use the more conventional way of importing the ast types, and put the assist at the top of the file.
* Fix formattingLúcás Meier2019-10-041-22/+9
|
* Create an assist for applying De Morgan's lawLúcás Meier2019-10-031-0/+115
Fixes #1807 This assist can transform expressions of the form `!x || !y` into `!(x && y)`. This also works with `&&`. This assist will only trigger if the cursor is on the central logical operator. The main limitation of this current implementation is that both operands need to be an explicit negation, either of the form `!x`, or `x != y`. More operands could be accepted, but this would complicate the implementation quite a bit.