File tree Expand file tree Collapse file tree 2 files changed +53
-0
lines changed
betterproto/tests/inputs/namespace_builtin_types Expand file tree Collapse file tree 2 files changed +53
-0
lines changed Original file line number Diff line number Diff line change
1
+ {
2
+ "int" : " value-for-int" ,
3
+ "float" : " value-for-float" ,
4
+ "complex" : " value-for-complex" ,
5
+ "list" : " value-for-list" ,
6
+ "tuple" : " value-for-tuple" ,
7
+ "range" : " value-for-range" ,
8
+ "str" : " value-for-str" ,
9
+ "bytearray" : " value-for-bytearray" ,
10
+ "bytes" : " value-for-bytes" ,
11
+ "memoryview" : " value-for-memoryview" ,
12
+ "set" : " value-for-set" ,
13
+ "frozenset" : " value-for-frozenset" ,
14
+ "map" : " value-for-map" ,
15
+ "bool" : " value-for-bool"
16
+ }
Original file line number Diff line number Diff line change
1
+ syntax = "proto3" ;
2
+
3
+ // Tests that messages may contain fields with names that are python types
4
+
5
+ message Test {
6
+ // https://docs.python.org/2/library/stdtypes.html#numeric-types-int-float-long-complex
7
+ string int = 1 ;
8
+ string float = 2 ;
9
+ string complex = 3 ;
10
+
11
+ // https://docs.python.org/3/library/stdtypes.html#generator-types
12
+ string list = 10 ;
13
+ string tuple = 11 ;
14
+ string range = 12 ;
15
+
16
+ // https://docs.python.org/3/library/stdtypes.html#str
17
+ string str = 21 ;
18
+
19
+ // https://docs.python.org/3/library/stdtypes.html#bytearray-objects
20
+ string bytearray = 22 ;
21
+
22
+ // https://docs.python.org/3/library/stdtypes.html#bytes-and-bytearray-operations
23
+ string bytes = 23 ;
24
+
25
+ // https://docs.python.org/3/library/stdtypes.html#memory-views
26
+ string memoryview = 24 ;
27
+
28
+ // https://docs.python.org/3/library/stdtypes.html#set-types-set-frozenset
29
+ string set = 25 ;
30
+ string frozenset = 26 ;
31
+
32
+ // https://docs.python.org/3/library/stdtypes.html#dict
33
+ string map = 27 ;
34
+
35
+ // https://docs.python.org/3/library/stdtypes.html#boolean-values
36
+ string bool = 28 ;
37
+ }
You can’t perform that action at this time.
0 commit comments