-
Notifications
You must be signed in to change notification settings - Fork 6k
[iOS text input] move FlutterTextInputView
implementation to a different file
#38044
[iOS text input] move FlutterTextInputView
implementation to a different file
#38044
Conversation
d207439
to
09ca27e
Compare
Gold has detected about 16 new digest(s) on patchset 5. |
b8f748c
to
c7859f9
Compare
c7859f9
to
6491f7a
Compare
@stuartmorgan You mentioned concerns about having MRC in ARC code base, which I agree. Are you concerned about having ARC code in MRC? |
Trying to write MRC code in an ARC file just won't compile, so there's no danger there.
In the context of an active transition, I don't think "in" is really a meaningful concept; there will be context switches back and forth, which means increased chances of messing up in an MRC file on accident, and that's not ideal. But it's unavoidable temporarily when migrating a codebase of any non-trivial size. The important thing IMO is to move toward a homogenous codebase, ideally minimizing the transition time as much as is reasonable to do. (By "reasonable" I mean to exclude things like "do the migration in a branch and then land it on My comments about MRC-in-ARC were about concerns about a final state where we permanently leave some MRC files among mostly-ARC code, because those files become permanent landmines. |
The only thing I can think of is having an instance variable in MRC is unsafely unretained (which compiles), and the same code in ARC would create a strong pointer. I think this is a good "fix" anyway so it is still ok.
I think for now it is "fine" since we only have a few files in ARC so we are still treating the codebase as MRC by default. I agree there will be a mentality change at some point where majority of the code in the code base is ARC and the codebase is treated as an ARC code base. We will need to have a plan before that happens and have the migration done in as less time as possible. |
also /cc @hellohuanlin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like you are doing 2 things in the same PR: 1. covert to ARC; 2. some refactoring works like moving code around.
Github didn't pick up those moving codes, which makes it pretty hard to review. Is it possible to split up those so that Github shows those changes side by side?
@@ -917,7 +917,7 @@ - (void)flutterTextInputView:(FlutterTextInputView*)textInputView | |||
arguments:@[ @(client), stateString, position ]]; | |||
} | |||
|
|||
- (void)flutterTextInputView:(FlutterTextInputView*)textInputView | |||
- (void)flutterTextInputView:(UIView<FlutterTextInputClient>*)textInputView |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are these change required as part of the ARC migration?
Extracted the ARC migration part to #38179 |
334fe56
to
152d076
Compare
FlutterTextInputView
implementation to a different fileFlutterTextInputView
implementation to a different file
WIP
Pre-launch Checklist
///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.