mirror of
https://github.com/google/pebble
synced 2026-10-18 01:04:12 +02:00
Import of the watch repository from Pebble
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
# Regression test for #746:
|
||||
# Name conflict when generating default values for message
|
||||
|
||||
Import("env")
|
||||
|
||||
env.NanopbProto("test.proto")
|
||||
env.Object("test.pb.c")
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
syntax = "proto2"; // must be "proto2", proto3 requires enums starting with 0.
|
||||
|
||||
enum Enum
|
||||
{
|
||||
enumerand = 1; // must be non-zero
|
||||
}
|
||||
|
||||
message Outer1
|
||||
{
|
||||
message Inner
|
||||
{
|
||||
optional Enum enum1 = 1; // can also be "required"
|
||||
}
|
||||
}
|
||||
|
||||
message Outer2
|
||||
{
|
||||
message Inner
|
||||
{
|
||||
// further trouble of this is also named "enum1"
|
||||
optional Enum enum2 = 1; // can also be "required"
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user