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

Check deprecation of inline methods #19914

Merged
merged 1 commit into from
Mar 19, 2024
Merged

Conversation

nicolasstucki
Copy link
Contributor

We must check these constraint just before inlining as later on there on the call might completely disappear. We do the same as we did for experimental definition checks.

Fixes #19913

Changes

  • Define CrossVersionChecks.checkRef that checks both deprecation and experimental.
    • Used in Inlines and PostTyper to check the deprecation of inlined calls.
  • Rename checkDeprecated to checkDeprecatedRef
  • Move checkDeprecatedRef and skipWarning to object CrossVersionChecks

tests/warn/i19913.scala Show resolved Hide resolved
We must check these constraint just before inlining as later on there on
the call might completely disappear. We do the same as we did for
experimental definition checks.

Fixes scala#19913
@nicolasstucki nicolasstucki merged commit 1eb466c into scala:main Mar 19, 2024
18 checks passed
@nicolasstucki nicolasstucki deleted the fix-19913 branch March 19, 2024 15:04
@Kordyjan Kordyjan added this to the 3.4.2 milestone Mar 28, 2024
WojciechMazur added a commit that referenced this pull request Jul 4, 2024
Backports #19914 to the LTS branch.

PR submitted by the release tooling.
[skip ci]
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.

Deprecated inline method does not generate deprecation warning
3 participants