diff options
| author | Michael Williamson <mike@zwobble.org> | 2026-03-21 12:45:59 +0000 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2026-03-21 12:45:59 +0000 |
| commit | f0e1c8c32732ea37e508fae3ff5d5cf085042733 (patch) | |
| tree | 4d858208ee4ad8d269de0be9f5a1da7bfbd027c8 /src/main/java/org | |
| parent | bef5f2a093007b4554c1746d1af550b64272dd34 (diff) | |
Serialize Patio mutable data element declaration
Diffstat (limited to 'src/main/java/org')
| -rw-r--r-- | src/main/java/org/shedlang/compiler/patio/protobuf/PatioToProtobuf.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/org/shedlang/compiler/patio/protobuf/PatioToProtobuf.java b/src/main/java/org/shedlang/compiler/patio/protobuf/PatioToProtobuf.java index 9ed1789e..71e74967 100644 --- a/src/main/java/org/shedlang/compiler/patio/protobuf/PatioToProtobuf.java +++ b/src/main/java/org/shedlang/compiler/patio/protobuf/PatioToProtobuf.java @@ -80,7 +80,11 @@ public class PatioToProtobuf { ); case DATA_ELEMENT_MUTABLE_DECLARATION -> - throw new UnsupportedOperationException("TODO"); + new PatioDataElementMutableDeclaration( + elementProtobuf.getDataElementMutableDeclaration().getName(), + deserializeDataLayout(elementProtobuf.getDataElementMutableDeclaration().getLayout()), + deserializeSource(elementProtobuf.getDataElementMutableDeclaration().getSource(), parentSource) + ); case DATA_ELEMENT_MUTABLE_DEFINITION -> throw new UnsupportedOperationException("TODO"); @@ -109,6 +113,7 @@ public class PatioToProtobuf { var builder = PatioProtobuf.PatioDataElementMutableDeclaration.newBuilder(); builder.setSource(serializeSource(element.source(), parentSource)); builder.setName(element.name()); + builder.setLayout(serializeDataLayout(element.layout())); return builder.build(); } |
