Files
react-native/packages
Gabriel Donadel 4c9490c702 generate-artifacts-executor: fix parsing .class in complex classes (#51813)
Summary:
There is an edge case in the codegen `findRCTComponentViewProtocolClass` function where the parsing of the Component Class will fail if there is another `.class` call in the same file after the `Class<RCTComponentViewProtocol>` function. This ends up resulting in a `RCTThirdPartyComponentsProvider.mm` file that looks like the image bellow

<img width="1052" alt="image" src="https://github.com/user-attachments/assets/26ce93be-0370-4852-a949-9da21762ff7f" />

You can reproduce this with the following

```
Class<RCTComponentViewProtocol> XYZCls(void)
{
  return XYZ.class;
}
// this comment breaks codegen .class
```

## Changelog:

[IOS] [FIXED] - Fix codegen extracting `.class` from complex component classes

Pull Request resolved: https://github.com/facebook/react-native/pull/51813

Test Plan: Run codegen locally, use this patch in the expo/expo repo and CI should be green

Reviewed By: cipolleschi

Differential Revision: D75964424

Pulled By: cortinico

fbshipit-source-id: 50e45aa2ac6e43c75ee6fdd76791c591d81d4df7
2025-06-09 13:59:33 +00:00
..
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 17:53:41 +00:00
2025-06-02 16:25:27 +00:00
2025-06-02 16:25:27 +00:00