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
Provide code actions to fix invalid transferring of an isolated value out from a lock statement #42734
Open
nipunayf
wants to merge
11
commits into
ballerina-platform:master
Choose a base branch
from
nipunayf:fix-42333
base: master
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nipunayf
added
the
Team/LanguageServer
Language Server Implementation related issues. #Compiler
label
May 10, 2024
nipunayf
changed the title
Provide code actions to fix invalid attempts to transfer out a value from a lock statement
[WIP] Provide code actions to fix invalid attempts to transfer out a value from a lock statement
May 10, 2024
nipunayf
changed the title
[WIP] Provide code actions to fix invalid attempts to transfer out a value from a lock statement
[WIP] Provide code actions to fix invalid transferring of an isolated value out from a lock statement
May 10, 2024
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #42734 +/- ##
=========================================
Coverage 77.26% 77.27%
- Complexity 51304 51331 +27
=========================================
Files 2929 2931 +2
Lines 204423 204485 +62
Branches 26668 26678 +10
=========================================
+ Hits 157947 158006 +59
- Misses 37890 37891 +1
- Partials 8586 8588 +2 ☔ View full report in Codecov by Sentry. |
nipunayf
requested review from
mohanvive,
sameerajayasoma and
hasithaa
as code owners
May 21, 2024 04:27
nipunayf
changed the title
[WIP] Provide code actions to fix invalid transferring of an isolated value out from a lock statement
Provide code actions to fix invalid transferring of an isolated value out from a lock statement
May 21, 2024
nipunayf
force-pushed
the
fix-42333
branch
2 times, most recently
from
May 21, 2024 13:41
1a70974
to
320c306
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose
$title.
Fixes #42333
Approach
Introduced two code actions, namely
clone value
andadd readonly type
, to fix the respective scenarios.Samples
Clone the value
Screen.Recording.2024-05-10.at.5.21.20.PM.mov
Clone as a readonly value
Screen.Recording.2024-05-10.at.5.21.29.PM.mov
Add readonly to type
Screen.Recording.2024-05-20.at.11.04.55.PM.mov
Remarks
Add readonly
code action as their original location points to the definition.Check List