Add a C++ backend for LibertyXDR
Also change the C backend so that it also de/serializes unions without any other fields besides the tag.
This commit is contained in:
@@ -439,7 +439,7 @@ function codegen_struct(name, cg, gotype) {
|
||||
delete cg[i]
|
||||
}
|
||||
|
||||
function codegen_union_tag(d, cg) {
|
||||
function codegen_union_tag(name, d, cg) {
|
||||
cg["tagtype"] = d["type"]
|
||||
cg["tagname"] = snaketocamel(d["name"])
|
||||
# The tag is implied from the type of struct stored in the interface.
|
||||
|
||||
Reference in New Issue
Block a user