Commit ff7ac00
Allocate
This change is prerequisite to supporting split fields with removed arena pointers. Split field types which have removed arena pointers have a larger representation on the arena which holds a copy of `InternalMetadata` from the parent message, since they need to be able to find a nearby `InternalMetadata` within a 32-bit offset. This is exactly how directly arena-allocated field types with arena offsets will work, but this logic is currently only implemented in `DoCreateMessage`. We will do the same trick here to construct this larger type when allocating in `Arena::DefaultConstruct`, which is the API split fields use.
PiperOrigin-RevId: 814896561FieldArenaRep type in Arena::DefaultConstruct when using arenas.1 parent 5ef4ee1 commit ff7ac00
1 file changed
+19
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
741 | 741 | | |
742 | 742 | | |
743 | 743 | | |
744 | | - | |
745 | | - | |
746 | 744 | | |
747 | | - | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
748 | 751 | | |
| 752 | + | |
| 753 | + | |
749 | 754 | | |
750 | | - | |
| 755 | + | |
751 | 756 | | |
752 | | - | |
| 757 | + | |
753 | 758 | | |
| 759 | + | |
| 760 | + | |
| 761 | + | |
| 762 | + | |
| 763 | + | |
| 764 | + | |
| 765 | + | |
| 766 | + | |
| 767 | + | |
754 | 768 | | |
755 | | - | |
756 | 769 | | |
757 | 770 | | |
758 | 771 | | |
| |||
0 commit comments