-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* reproducing the issue * dupe can only make allocator errors, and this was hard to handle for the compiler.
- Loading branch information
Showing
23 changed files
with
2,800 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
// Code generated by protoc-gen-zig | ||
///! package opentelemetry.proto.common.v1 | ||
const std = @import("std"); | ||
const Allocator = std.mem.Allocator; | ||
const ArrayList = std.ArrayList; | ||
|
||
const protobuf = @import("protobuf"); | ||
const ManagedString = protobuf.ManagedString; | ||
const fd = protobuf.fd; | ||
|
||
pub const AnyValue = struct { | ||
value: ?value_union, | ||
|
||
pub const _value_case = enum { | ||
string_value, | ||
bool_value, | ||
int_value, | ||
double_value, | ||
array_value, | ||
kvlist_value, | ||
bytes_value, | ||
}; | ||
pub const value_union = union(_value_case) { | ||
string_value: ManagedString, | ||
bool_value: bool, | ||
int_value: i64, | ||
double_value: f64, | ||
array_value: ArrayValue, | ||
kvlist_value: KeyValueList, | ||
bytes_value: ManagedString, | ||
pub const _union_desc = .{ | ||
.string_value = fd(1, .String), | ||
.bool_value = fd(2, .{ .Varint = .Simple }), | ||
.int_value = fd(3, .{ .Varint = .Simple }), | ||
.double_value = fd(4, .{ .FixedInt = .I64 }), | ||
.array_value = fd(5, .{ .SubMessage = {} }), | ||
.kvlist_value = fd(6, .{ .SubMessage = {} }), | ||
.bytes_value = fd(7, .Bytes), | ||
}; | ||
}; | ||
|
||
pub const _desc_table = .{ | ||
.value = fd(null, .{ .OneOf = value_union }), | ||
}; | ||
|
||
pub usingnamespace protobuf.MessageMixins(@This()); | ||
}; | ||
|
||
pub const ArrayValue = struct { | ||
values: ArrayList(AnyValue), | ||
|
||
pub const _desc_table = .{ | ||
.values = fd(1, .{ .List = .{ .SubMessage = {} } }), | ||
}; | ||
|
||
pub usingnamespace protobuf.MessageMixins(@This()); | ||
}; | ||
|
||
pub const KeyValueList = struct { | ||
values: ArrayList(KeyValue), | ||
|
||
pub const _desc_table = .{ | ||
.values = fd(1, .{ .List = .{ .SubMessage = {} } }), | ||
}; | ||
|
||
pub usingnamespace protobuf.MessageMixins(@This()); | ||
}; | ||
|
||
pub const KeyValue = struct { | ||
key: ManagedString = .Empty, | ||
value: ?AnyValue = null, | ||
|
||
pub const _desc_table = .{ | ||
.key = fd(1, .String), | ||
.value = fd(2, .{ .SubMessage = {} }), | ||
}; | ||
|
||
pub usingnamespace protobuf.MessageMixins(@This()); | ||
}; | ||
|
||
pub const InstrumentationScope = struct { | ||
name: ManagedString = .Empty, | ||
version: ManagedString = .Empty, | ||
attributes: ArrayList(KeyValue), | ||
dropped_attributes_count: u32 = 0, | ||
|
||
pub const _desc_table = .{ | ||
.name = fd(1, .String), | ||
.version = fd(2, .String), | ||
.attributes = fd(3, .{ .List = .{ .SubMessage = {} } }), | ||
.dropped_attributes_count = fd(4, .{ .Varint = .Simple }), | ||
}; | ||
|
||
pub usingnamespace protobuf.MessageMixins(@This()); | ||
}; |
Oops, something went wrong.