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

DiffOptions: allow controlling use of ANSI markers #885

Merged
merged 1 commit into from
Jan 21, 2025

Conversation

kitbellew
Copy link
Contributor

Also, exclude munit.internal. from MIMA.

)

// for MIMA compatibility
@deprecated("Use version with implicit DiffOptions", "1.0.4")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it will work, though if someone is overriding the method it will show an error.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this provides binary compatibility (the parameters, same order) except I'm not sure if private is sufficient, too; and the new method is source-compatible.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though if we override it wil fail the compilation or am I missing something:

trait Location
trait A{
  def locs(a: String, b: Int, l: Location): Nothing = ???
}

class B extends A{
  override def locs(a : String, b: Int)(implicit l : Location) = ???
}

This will fail, so I assume your change should also fail

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think that it wouldn't fail, or else mina would complain.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would think so, which is why I am bit confused. It might be a bug in Mima or alternatively the code produced is binary compatible, just not source compatible.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, mima checks for binary. well, if there's minor source incompatibility, increasing the minor version, as you suggested, should be enough. wdyt?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the odds of someone overwriting the fail method are pretty low 🤔 We should be fine then

Also, exclude `munit.internal.` from MIMA.
@kitbellew
Copy link
Contributor Author

@tgodzik thank you. i have no more changes to propose, should i release 1.1.0?

@kitbellew kitbellew merged commit 80f980b into scalameta:main Jan 21, 2025
9 checks passed
@kitbellew kitbellew deleted the 885 branch January 21, 2025 15:15
@tgodzik
Copy link
Contributor

tgodzik commented Jan 21, 2025

@tgodzik thank you. i have no more changes to propose, should i release 1.1.0?

Nothing from me.

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.

2 participants