@@ -103,6 +103,35 @@ type Foozer struct {
103
103
Embed struct{ CustomJSON }
104
104
105
105
Unsupported map[int]string
106
+
107
+ OptionalOmitEmptyJSON string `json:"optionalOmitEmptyJSON,omitempty"`
108
+
109
+ OptionalOmitEmptyYAML string `yaml:"optionalOmitEmptyYAML,omitempty"`
110
+
111
+ // +optional
112
+ OptionalComment string `json:"optionalComment"`
113
+
114
+ //+optional
115
+ OptionalCommentNoSpace string `json:"optionalCommentNoSpace"`
116
+
117
+ // Something before
118
+ //
119
+ // +optional
120
+ //
121
+ // Something after
122
+ OptionalCommentExtra string `json:"optionalCommentExtra"`
123
+
124
+ // +optional=
125
+ OptionalCommentTag string `json:"optionalCommentTag"`
126
+
127
+ // +optional=some-value
128
+ OptionalCommentTagValue string `json:"optionalCommentTagValue"`
129
+
130
+ // some-prefix+optional
131
+ RequiredCommentPrefix string `json:"requiredCommentPrefix"`
132
+
133
+ // +optional-some-suffix
134
+ RequiredCommentSuffix string `json:"requiredCommentSuffix"`
106
135
}
107
136
108
137
type Identifier string
@@ -293,6 +322,33 @@ import (
293
322
Embed: {
294
323
CustomJSON: #CustomJSON
295
324
} @go(,struct{CustomJSON})
325
+ optionalOmitEmptyJSON?: string @go(OptionalOmitEmptyJSON)
326
+ optionalOmitEmptyYAML?: string @go(OptionalOmitEmptyYAML)
327
+
328
+ // +optional
329
+ optionalComment?: string @go(OptionalComment)
330
+
331
+ //+optional
332
+ optionalCommentNoSpace?: string @go(OptionalCommentNoSpace)
333
+
334
+ // Something before
335
+ //
336
+ // +optional
337
+ //
338
+ // Something after
339
+ optionalCommentExtra?: string @go(OptionalCommentExtra)
340
+
341
+ // +optional=
342
+ optionalCommentTag?: string @go(OptionalCommentTag)
343
+
344
+ // +optional=some-value
345
+ optionalCommentTagValue?: string @go(OptionalCommentTagValue)
346
+
347
+ // some-prefix+optional
348
+ requiredCommentPrefix: string @go(RequiredCommentPrefix)
349
+
350
+ // +optional-some-suffix
351
+ requiredCommentSuffix: string @go(RequiredCommentSuffix)
296
352
}
297
353
298
354
#Identifier: string // #enumIdentifier
0 commit comments