feat: enable explicit backing fields#20500
Merged
criticalAY merged 1 commit intoankidroid:mainfrom Mar 22, 2026
Merged
Conversation
fefaa29 to
8882ffd
Compare
8882ffd to
30fe025
Compare
david-allison
approved these changes
Mar 20, 2026
30fe025 to
5199797
Compare
Member
|
Can't force push myself right now, but make the change to the commit title of: Low risk, and it's blocking you from doing something awesome |
5199797 to
9d68bd4
Compare
This file contains hidden or 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
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 / Description
I want to Enable field backing for Kotlin (Kotlin automatically generates a backing field for properties that reference the field keyword in their custom accessors, though in experimental phase)
Here is what it will look like for VMs since most of the time we use this pattern in VMs
Before
After
Fixes
NA
Approach
I simply added "-Xexplicit-backing-fields" but there was warning in code for which I did a workaround to fix it, I have commented on the
valto better explanationHow Has This Been Tested?
Compiled the code and tried adding
fieldproperty to a classLearning (optional, can help others)
Checklist
Please, go through these checks before submitting the PR.