diff options
Diffstat (limited to 'ppapi/generators/test_cgen')
-rw-r--r-- | ppapi/generators/test_cgen/enum_typedef.h | 10 | ||||
-rw-r--r-- | ppapi/generators/test_cgen/enum_typedef.idl | 6 | ||||
-rw-r--r-- | ppapi/generators/test_cgen/interface.h | 36 | ||||
-rw-r--r-- | ppapi/generators/test_cgen/interface.idl | 4 | ||||
-rw-r--r-- | ppapi/generators/test_cgen/structs.h | 2 | ||||
-rw-r--r-- | ppapi/generators/test_cgen/structs.idl | 4 |
6 files changed, 48 insertions, 14 deletions
diff --git a/ppapi/generators/test_cgen/enum_typedef.h b/ppapi/generators/test_cgen/enum_typedef.h index b7ef0c1..6eb1a0c 100644 --- a/ppapi/generators/test_cgen/enum_typedef.h +++ b/ppapi/generators/test_cgen/enum_typedef.h @@ -4,7 +4,7 @@ * found in the LICENSE file. */ -/* From test_cgen/enum_typedef.idl modified Mon Aug 22 15:15:49 2011. */ +/* From test_cgen/enum_typedef.idl modified Wed Dec 5 13:08:05 2012. */ #ifndef PPAPI_C_TEST_CGEN_ENUM_TYPEDEF_H_ #define PPAPI_C_TEST_CGEN_ENUM_TYPEDEF_H_ @@ -41,11 +41,11 @@ typedef enum { /* typedef int32_t i; */ typedef int32_t i; -/* typedef int32_t i2[2]; */ -typedef int32_t i2[2]; +/* typedef int32_t i2[3]; */ +typedef int32_t i2[3]; -/* typedef int32_t (*i_func)(); */ -typedef int32_t (*i_func)(); +/* typedef int32_t (*i_func)(void); */ +typedef int32_t (*i_func)(void); /* typedef int32_t (*i_func_i)(int32_t i); */ typedef int32_t (*i_func_i)(int32_t i); diff --git a/ppapi/generators/test_cgen/enum_typedef.idl b/ppapi/generators/test_cgen/enum_typedef.idl index 2454104..60d0a67 100644 --- a/ppapi/generators/test_cgen/enum_typedef.idl +++ b/ppapi/generators/test_cgen/enum_typedef.idl @@ -14,10 +14,10 @@ enum et1 { A=1, B=2, C=3, D=A+B, E=~D }; /* typedef int32_t i; */ typedef int32_t i; -/* typedef int32_t i2[2]; */ -typedef int32_t[2] i2; +/* typedef int32_t i2[3]; */ +typedef int32_t[3] i2; -/* typedef int32_t (*i_func)(); */ +/* typedef int32_t (*i_func)(void); */ typedef int32_t i_func(); /* typedef int32_t (*i_func_i)(int32_t i); */ diff --git a/ppapi/generators/test_cgen/interface.h b/ppapi/generators/test_cgen/interface.h index 6a187e4..fccafcb 100644 --- a/ppapi/generators/test_cgen/interface.h +++ b/ppapi/generators/test_cgen/interface.h @@ -4,7 +4,7 @@ * found in the LICENSE file. */ -/* From test_cgen/interface.idl modified Mon Aug 22 15:15:43 2011. */ +/* From test_cgen/interface.idl modified Wed Nov 21 14:22:50 2012. */ #ifndef PPAPI_C_TEST_CGEN_INTERFACE_H_ #define PPAPI_C_TEST_CGEN_INTERFACE_H_ @@ -12,6 +12,11 @@ #include "ppapi/c/pp_macros.h" #include "ppapi/c/test_cgen/stdint.h" +#define IFACEFOO_INTERFACE_1_0 "ifaceFoo;1.0" +#define IFACEFOO_INTERFACE IFACEFOO_INTERFACE_1_0 + +#define IFACEBAR_INTERFACE_1_0 "ifaceBar;1.0" +#define IFACEBAR_INTERFACE IFACEBAR_INTERFACE_1_0 /** * @file @@ -36,16 +41,41 @@ struct ist { * @{ */ /* - * struct iface1 { + * struct ifaceFoo_1_0 { * int8_t (*mem1)(int16_t x, int32_t y); * int32_t (*mem2)(const struct ist* a); * int32_t (*mem3)(struct ist* b); + * int32_t (*mem4)(const void** ptr); + * int32_t (*mem5)(void** ptr); * }; + * typedef struct ifaceFoo_1_0 ifaceFoo; */ -struct iface1 { +struct ifaceFoo_1_0 { int8_t (*mem1)(int16_t x, int32_t y); int32_t (*mem2)(const struct ist* a); int32_t (*mem3)(struct ist* b); + int32_t (*mem4)(const void** ptr); + int32_t (*mem5)(void** ptr); +}; + +typedef struct ifaceFoo_1_0 ifaceFoo; + +struct ifaceBar_1_0 { + int8_t (*testIface)(const struct ifaceFoo_1_0* foo, int32_t y); + struct ifaceFoo_1_0* (*createIface)(const char* name); +}; + +typedef struct ifaceBar_1_0 ifaceBar; +/** + * @} + */ + +/** + * @addtogroup Structs + * @{ + */ +struct struct2 { + struct ifaceBar_1_0* bar; }; /** * @} diff --git a/ppapi/generators/test_cgen/interface.idl b/ppapi/generators/test_cgen/interface.idl index 22a4a03..d7ca86e 100644 --- a/ppapi/generators/test_cgen/interface.idl +++ b/ppapi/generators/test_cgen/interface.idl @@ -18,14 +18,14 @@ struct ist { }; /* - * struct iface1 { + * struct ifaceFoo_1_0 { * int8_t (*mem1)(int16_t x, int32_t y); * int32_t (*mem2)(const struct ist* a); * int32_t (*mem3)(struct ist* b); * int32_t (*mem4)(const void** ptr); * int32_t (*mem5)(void** ptr); - * int32_t (*mem6)(void** ptr); * }; + * typedef struct ifaceFoo_1_0 ifaceFoo; */ interface ifaceFoo { int8_t mem1([in] int16_t x, [in] int32_t y); diff --git a/ppapi/generators/test_cgen/structs.h b/ppapi/generators/test_cgen/structs.h index bcc6b44..352e08e 100644 --- a/ppapi/generators/test_cgen/structs.h +++ b/ppapi/generators/test_cgen/structs.h @@ -4,7 +4,7 @@ * found in the LICENSE file. */ -/* From test_cgen/structs.idl modified Mon Aug 22 15:15:38 2011. */ +/* From test_cgen/structs.idl modified Wed Nov 21 11:02:50 2012. */ #ifndef PPAPI_C_TEST_CGEN_STRUCTS_H_ #define PPAPI_C_TEST_CGEN_STRUCTS_H_ diff --git a/ppapi/generators/test_cgen/structs.idl b/ppapi/generators/test_cgen/structs.idl index ecf7163..b91949c 100644 --- a/ppapi/generators/test_cgen/structs.idl +++ b/ppapi/generators/test_cgen/structs.idl @@ -8,6 +8,10 @@ * This file will test that the IDL snippet matches the comment. */ +label Chrome { + M14=1.0 +}; + /* typedef uint8_t s_array[3]; */ typedef uint8_t[3] s_array; |