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

Fix unidoc #2314

Merged
merged 3 commits into from Dec 20, 2021
Merged

Fix unidoc #2314

merged 3 commits into from Dec 20, 2021

Conversation

jackkoenig
Copy link
Contributor

Unidoc was apparently not running in CI and it was broken by #2277. The issue isn't that #2277 is broken, it's that it exposed the fact that unidoc actually runs the same scalacOptions on all of the files being built into 1 doc. This is a problem because Chisel3 core needs to not have the compiler plugin run on it, while the downstream chisel project does. This is a hacky solution, but it's the best I have, see sbt/sbt-unidoc#107.

Note that this has 3 useful commits. There is a little of refactoring of how the plugin skips components (a component is a Scalac compiler phase).

Contributor Checklist

  • [NA] Did you add Scaladoc to every public function/method?
  • Did you add at least one test demonstrating the PR?
  • Did you delete any extraneous printlns/debugging code?
  • Did you specify the type of improvement?
  • [NA] Did you add appropriate documentation in docs/src?
  • Did you state the API impact?
  • Did you specify the code generation impact?
  • Did you request a desired merge strategy?
  • [NA] Did you add text to be included in the Release Notes for this change?

Type of Improvement

  • bug fix
  • documentation

API Impact

This adds an argument to the chisel3 plugin -P:chiselplugin:INTERNALskipFile:<filename>, note this is only intended to be used for internal unidoc generation.

Backend Code Generation Impact

No impact

Desired Merge Strategy

  • Rebase

Release Notes

Reviewer Checklist (only modified by reviewer)

  • Did you add the appropriate labels?
  • Did you mark the proper milestone (Bug fix: 3.3.x, [small] API extension: 3.4.x, API modification or big change: 3.5.0)?
  • Did you review?
  • Did you check whether all relevant Contributor checkboxes have been checked?
  • Did you mark as Please Merge?

It is always true. The scalacOption to enable it is still supported and
prints a warning that the option no longer does anything.
This enables skipping files in the compiler plugin, only needed for
unidoc generation.
@jackkoenig jackkoenig merged commit df1b4aa into master Dec 20, 2021
@jackkoenig jackkoenig deleted the fix-unidoc branch December 20, 2021 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants