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

Plugin interface cleanup #85296

Merged
merged 1 commit into from
Aug 12, 2021
Merged

Plugin interface cleanup #85296

merged 1 commit into from
Aug 12, 2021

Conversation

bjorn3
Copy link
Member

@bjorn3 bjorn3 commented May 14, 2021

The first commit performs two uncontroversial cleanups. The second commit removes #[plugin_registrar] and instead requires you to export a __rustc_plugin_registrar function, this will require a change to servo's script_plugins (cc @jdm)

@bjorn3 bjorn3 added C-cleanup Category: PRs that clean code up or issues documenting cleanup. A-plugin Area: compiler plugins, doc.rust-lang.org/nightly/unstable-book/language-features/plugin.html T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 14, 2021
@rust-highfive
Copy link
Collaborator

r? @matthewjasper

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 14, 2021
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@petrochenkov
Copy link
Contributor

r? @petrochenkov

@rust-log-analyzer

This comment has been minimized.

@petrochenkov
Copy link
Contributor

I think removing #[plugin_registrar] is fine.
The functionality is deeply deprecated and as long as servo still can access it somehow it doesn't matter much how exactly it happens, through an attribute or through an exported symbol.

@petrochenkov
Copy link
Contributor

Could you add a test making sure that two plugins from two different crates still can be loaded together despite the identical names of the plugin registrar symbols?

@petrochenkov petrochenkov added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 15, 2021
@bors

This comment has been minimized.

@crlf0710
Copy link
Member

crlf0710 commented Jun 5, 2021

@bjorn3 Ping from triage, any updates on this?

@JohnCSimon
Copy link
Member

@bjorn3 Ping again from triage, any updates on this?

@bjorn3
Copy link
Member Author

bjorn3 commented Jun 23, 2021

Rebased, but I still need to at the requested test.

@rust-log-analyzer

This comment has been minimized.

@bors

This comment has been minimized.

@bjorn3 bjorn3 force-pushed the plugin_cleanup branch 2 times, most recently from 447dac6 to 8611d9b Compare August 8, 2021 10:16
@rust-log-analyzer

This comment has been minimized.

@petrochenkov
Copy link
Contributor

r=me with the failing test updated and commits squashed.

@bjorn3 bjorn3 force-pushed the plugin_cleanup branch 4 times, most recently from 2589a62 to 023936a Compare August 9, 2021 19:57
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@bjorn3
Copy link
Member Author

bjorn3 commented Aug 10, 2021

Opened servo/servo#28564 for the servo changes.

r=me with the failing test updated and commits squashed.

Fixed all failing tests and squashed all commits.

@bors r=petrochenkov

@bors
Copy link
Contributor

bors commented Aug 10, 2021

📌 Commit a501308 has been approved by petrochenkov

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Aug 10, 2021
@bors
Copy link
Contributor

bors commented Aug 12, 2021

⌛ Testing commit a501308 with merge eb2226b...

@bors
Copy link
Contributor

bors commented Aug 12, 2021

☀️ Test successful - checks-actions
Approved by: petrochenkov
Pushing eb2226b to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Aug 12, 2021
@bors bors merged commit eb2226b into rust-lang:master Aug 12, 2021
@rustbot rustbot added this to the 1.56.0 milestone Aug 12, 2021
@bjorn3 bjorn3 deleted the plugin_cleanup branch August 13, 2021 11:06
bors-servo added a commit to servo/servo that referenced this pull request Aug 13, 2021
Update script_plugin for rust-lang/rust#85296

This will update the script_plugin for the plugin interface changes in rust-lang/rust#85296.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because it is a fix for rustc changes.
bors-servo added a commit to servo/servo that referenced this pull request Aug 14, 2021
Update script_plugin for rust-lang/rust#85296

This will update the script_plugin for the plugin interface changes in rust-lang/rust#85296.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because it is a fix for rustc changes.
bors added a commit to rust-lang/cargo that referenced this pull request Aug 15, 2021
Fix plugin registrar change.

The plugin tests were broken due to a change in rust-lang/rust#85296 which removed the `plugin_registrar` attribute.
ehuss pushed a commit to ehuss/cargo that referenced this pull request Aug 20, 2021
…hton

Fix plugin registrar change.

The plugin tests were broken due to a change in rust-lang/rust#85296 which removed the `plugin_registrar` attribute.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-plugin Area: compiler plugins, doc.rust-lang.org/nightly/unstable-book/language-features/plugin.html C-cleanup Category: PRs that clean code up or issues documenting cleanup. merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants