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

TYPE: Fold Macro/MacroExpansion/Macro2 #3745

Merged
merged 3 commits into from Apr 25, 2019

Conversation

Projects
None yet
3 participants
@ice1000
Copy link
Contributor

commented Apr 23, 2019

Signed-off-by: ice1000 ice1000kotlin@foxmail.com

Before folding:
Screenshot from 2019-04-22 21-00-41

After completely fold everything:
Screenshot from 2019-04-22 21-00-30

Only fold MacroExpansion blocks:
Screenshot from 2019-04-22 21-06-30

Before:
Screenshot from 2019-04-22 21-11-31

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 23, 2019

I'm working on test fixtures

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 23, 2019

Done, it's now ready for review

@Undin Undin added the feature label Apr 23, 2019

@ice1000 ice1000 changed the title Fold Macro/MacroExpansion/Macro2 TYPE: Fold Macro/MacroExpansion/Macro2 Apr 23, 2019

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 24, 2019

bors ping

@bors

This comment has been minimized.

Copy link
Contributor

commented Apr 24, 2019

pong

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 24, 2019

Rebased onto current master.

@mchernyavsky mchernyavsky self-assigned this Apr 24, 2019

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 25, 2019

bors ping

@bors

This comment has been minimized.

Copy link
Contributor

commented Apr 25, 2019

pong

@mchernyavsky
Copy link
Member

left a comment

Hi @ice1000! Please sign our CLA.

ice1000 added some commits Apr 23, 2019

TYPE: Fold Macro/MacroExpansion/Macro2
Signed-off-by: ice1000 <ice1000kotlin@foxmail.com>
T: Add tests for the folding builder,
... and add my name to the contributor list by the way

Signed-off-by: ice1000 <ice1000kotlin@foxmail.com>
TYPE: Fold macro2's braces even when there are parenthesises
Signed-off-by: ice1000 <ice1000kotlin@foxmail.com>
@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 25, 2019

Add comments addressed, CLA signed. Please take a look?

@mchernyavsky

This comment has been minimized.

Copy link
Member

commented Apr 25, 2019

Thanks!
bors r+

bors bot added a commit that referenced this pull request Apr 25, 2019

Merge #3745 #3758
3745: TYPE: Fold Macro/MacroExpansion/Macro2 r=mchernyavsky a=ice1000

Signed-off-by: ice1000 <ice1000kotlin@foxmail.com>

<!--
Hello and thank you for the pull request!

We don't have any strict rules about pull requests, but you might check
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTING.md
for some hints!

Note that we need an electronic CLA for contributions:
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTING.md#cla

After you sign the CLA, please add your name to
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTORS.txt

:)
-->

Before folding:
![Screenshot from 2019-04-22 21-00-41](https://user-images.githubusercontent.com/16398479/56544608-086baf80-6543-11e9-9ef4-75e6644bbd67.png)

After completely fold everything:
![Screenshot from 2019-04-22 21-00-30](https://user-images.githubusercontent.com/16398479/56544629-13bedb00-6543-11e9-9997-14dd97a82916.png)

Only fold `MacroExpansion` blocks:
![Screenshot from 2019-04-22 21-06-30](https://user-images.githubusercontent.com/16398479/56544647-1de0d980-6543-11e9-9332-ec61a5409bd2.png)

Before:
![Screenshot from 2019-04-22 21-11-31](https://user-images.githubusercontent.com/16398479/56544696-381ab780-6543-11e9-81c2-1179e5321ffb.png)


3758: CLEAN: fix typo r=vlad20012 a=vlad20012

bors r+

Co-authored-by: ice1000 <ice1000kotlin@foxmail.com>
Co-authored-by: vlad20012 <beskvlad@gmail.com>
@bors

This comment has been minimized.

Copy link
Contributor

commented Apr 25, 2019

Timed out (retrying...)

bors bot added a commit that referenced this pull request Apr 25, 2019

Merge #3745
3745: TYPE: Fold Macro/MacroExpansion/Macro2 r=mchernyavsky a=ice1000

Signed-off-by: ice1000 <ice1000kotlin@foxmail.com>

<!--
Hello and thank you for the pull request!

We don't have any strict rules about pull requests, but you might check
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTING.md
for some hints!

Note that we need an electronic CLA for contributions:
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTING.md#cla

After you sign the CLA, please add your name to
https://github.com/intellij-rust/intellij-rust/blob/master/CONTRIBUTORS.txt

:)
-->

Before folding:
![Screenshot from 2019-04-22 21-00-41](https://user-images.githubusercontent.com/16398479/56544608-086baf80-6543-11e9-9ef4-75e6644bbd67.png)

After completely fold everything:
![Screenshot from 2019-04-22 21-00-30](https://user-images.githubusercontent.com/16398479/56544629-13bedb00-6543-11e9-9997-14dd97a82916.png)

Only fold `MacroExpansion` blocks:
![Screenshot from 2019-04-22 21-06-30](https://user-images.githubusercontent.com/16398479/56544647-1de0d980-6543-11e9-9332-ec61a5409bd2.png)

Before:
![Screenshot from 2019-04-22 21-11-31](https://user-images.githubusercontent.com/16398479/56544696-381ab780-6543-11e9-81c2-1179e5321ffb.png)


Co-authored-by: ice1000 <ice1000kotlin@foxmail.com>
@mchernyavsky

This comment has been minimized.

Copy link
Member

commented Apr 25, 2019

bors retry

@bors

This comment has been minimized.

Copy link
Contributor

commented Apr 25, 2019

Already running a review

@ice1000

This comment has been minimized.

Copy link
Contributor Author

commented Apr 25, 2019

Maybe we should fix this warning?

   Compiling pretty_printers_test v0.1.0 (/home/travis/build/intellij-rust/intellij-rust/pretty_printers_tests)
warning: use of deprecated item 'core::str::<impl str>::trim_left': superseded by `trim_start`
   --> src/test_runner.rs:288:31
    |
288 |                     line[2..].trim_left()
    |                               ^^^^^^^^^
    |
    = note: #[warn(deprecated)] on by default
@bors

This comment has been minimized.

Copy link
Contributor

commented Apr 25, 2019

@bors bors bot merged commit bc1b76b into intellij-rust:master Apr 25, 2019

2 checks passed

bors Build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@ice1000 ice1000 deleted the ice1000:fold-macros branch Apr 25, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.