103 if (
attr->type ==
t)
return 1;
111 if (
attr->type ==
t)
return attr->u.pval;
119 if (
attr->type ==
t)
return attr->u.ival;
126 fprintf(
f,
"DEFINE_GUID(%s_%s, 0x%08x, 0x%04x, 0x%04x, 0x%02x,0x%02x, 0x%02x,"
127 "0x%02x,0x%02x,0x%02x,0x%02x,0x%02x);\n",
136 fprintf(
f,
"#ifdef __CRT_UUID_DECL\n");
137 fprintf(
f,
"__CRT_UUID_DECL(%s, 0x%08x, 0x%04x, 0x%04x, 0x%02x,0x%02x, 0x%02x,"
138 "0x%02x,0x%02x,0x%02x,0x%02x,0x%02x)\n",
150 sprintf(
buf,
"%08x-%04x-%04x-%02x%02x-%02x%02x%02x%02x%02x%02x",
199 unsigned nameless_struct_cnt = 0, nameless_struct_i = 0, nameless_union_cnt = 0, nameless_union_i = 0;
207 if (!
v || !
v->type)
continue;
212 nameless_struct_cnt++;
215 nameless_union_cnt++;
223 if (!
v || !
v->type)
continue;
233 if(nameless_struct_cnt == 1) {
234 name =
"__C89_NAMELESSSTRUCTNAME";
235 }
else if(nameless_struct_i < 5 ) {
236 sprintf(
buf,
"__C89_NAMELESSSTRUCTNAME%d", ++nameless_struct_i);
244 if(nameless_union_cnt == 1) {
245 name =
"__C89_NAMELESSUNIONNAME";
246 }
else if(nameless_union_i < 8 ) {
247 sprintf(
buf,
"__C89_NAMELESSUNIONNAME%d", ++nameless_union_i);
313 if (!declonly &&
t->defined && !
t->written) {
326 if (!declonly &&
t->defined && !
t->written) {
341 if (!declonly &&
t->defined && !
t->written) {
342 if (
t->name)
fprintf(
h,
"union %s {\n",
t->name);
350 else fprintf(
h,
"union %s",
t->name ?
t->name :
"");
455 fprintf(
h,
"[%s]", is_field ?
"1" :
"");
506 if (ptr_level)
fputc(
'(',
h);
507 if (callconv)
fprintf(
h,
"%s ", callconv);
508 for (
i = 0;
i < ptr_level;
i++)
520 if (ptr_level)
fputc(
')',
h);
540 int save_written =
t->written;
544 fprintf(
f,
"} /* extern \"C\" */\n");
551 t->written = save_written;
601 unsigned int index = 0;
607 else error(
"internal error: %s is not a context handle\n",
type->name );
614 error(
"internal error: %s is not registered as a context handle\n",
type->name );
621 unsigned int index = 0;
627 else error(
"internal error: %s is not a generic handle\n",
type->name );
634 error(
"internal error: %s is not registered as a generic handle\n",
type->name );
651 if (
type->user_types_registered)
break;
652 type->user_types_registered = 1;
746 for (type_entry = iface_stmt->
u.
type_list; type_entry; type_entry = type_entry->
next)
767 fprintf(
header,
"unsigned char * __RPC_USER %s_UserMarshal (ULONG *, unsigned char *, %s *);\n",
name,
name);
768 fprintf(
header,
"unsigned char * __RPC_USER %s_UserUnmarshal(ULONG *, unsigned char *, %s *);\n",
name,
name);
808 for (
t =
var->type; ; )
868 unsigned char *explicit_fc,
unsigned char *implicit_fc )
873 *explicit_fc = *implicit_fc = 0;
959 char inherit_name[256];
984 char inherit_name[256];
1005 static char buff[255];
1016 int first_iface = 1;
1085 const var_t *tail_arg;
1089 if(tail_arg ==
arg) {
1126 if (!callconv) callconv =
"STDMETHODCALLTYPE";
1129 fprintf(
header,
"#ifdef WIDL_EXPLICIT_AGGREGATE_RETURNS\n");
1187 int first_iface = 1;
1243 int first_iface = 1;
1269 if (!callconv) callconv =
"STDMETHODCALLTYPE";
1318 if (!callconv) callconv =
"STDMETHODCALLTYPE";
1327 fprintf(
header,
" IRpcChannelBuffer* pRpcChannelBuffer,\n");
1337 =
"/* WIDL-generated stub. You must provide an implementation for this. */";
1364 fprintf(fp,
" return E_NOTIMPL;\n");
1369 fprintf(fp,
" memset(&rv, 0, sizeof rv);\n");
1415 fprintf(local_stubs,
"#include <objbase.h>\n");
1427 if (!callconv) callconv =
"__cdecl";
1455 fprintf(
header,
"/*****************************************************************************\n");
1456 fprintf(
header,
" * %s %sinterface\n", iface->
name, dispinterface ?
"disp" :
"");
1458 fprintf(
header,
"#ifndef __%s_%sINTERFACE_DEFINED__\n", iface->
c_name, dispinterface ?
"DISP" :
"");
1459 fprintf(
header,
"#define __%s_%sINTERFACE_DEFINED__\n\n", iface->
c_name, dispinterface ?
"DISP" :
"");
1472 fprintf(
header,
"#if defined(__cplusplus) && !defined(CINTERFACE)\n");
1543 fprintf(
header,
"#endif /* __%s_%sINTERFACE_DEFINED__ */\n\n", iface->
c_name, dispinterface ?
"DISP" :
"");
1551 fprintf(
header,
"/*****************************************************************************\n");
1569 fprintf(
header,
"extern RPC_IF_HANDLE %s%s_v%d_%d_c_ifspec;\n",
1571 fprintf(
header,
"extern RPC_IF_HANDLE %s%s_v%d_%d_s_ifspec;\n",
1585 fprintf(
header,
"/*****************************************************************************\n");
1621 p = hname +
strlen(hname) - 2;
1756 for (; type_entry; type_entry = type_entry->
next)
1774 if (prefixes_differ)
1804 fprintf(
header,
"#define __REQUIRED_RPCNDR_H_VERSION__ 475\n");
1835 fprintf(
header,
"/* Begin additional prototypes for all interfaces */\n");
char * strcat(char *DstString, const char *SrcString)
int strcmp(const char *String1, const char *String2)
ACPI_SIZE strlen(const char *String)
char * strcpy(char *DstString, const char *SrcString)
static ITypeLib * typelib
char * xstrdup(const char *s)
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
static const WCHAR indent[]
void write_expr(FILE *h, const expr_t *e, int brackets, int toplevel, const char *toplevel_prefix, const type_t *cont_type, const char *local_var_prefix)
static unsigned char buff[32768]
GLuint GLuint GLsizei GLenum type
GLuint GLuint GLsizei count
GLenum GLuint GLenum GLsizei const GLchar * buf
GLboolean GLboolean GLboolean GLboolean a
GLfloat GLfloat GLfloat GLfloat h
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
_Check_return_opt_ _CRTIMP int __cdecl fprintf(_Inout_ FILE *_File, _In_z_ _Printf_format_string_ const char *_Format,...)
_Check_return_opt_ _CRTIMP int __cdecl vfprintf(_Inout_ FILE *_File, _In_z_ _Printf_format_string_ const char *_Format, va_list _ArgList)
_Check_return_ _CRTIMP FILE *__cdecl fopen(_In_z_ const char *_Filename, _In_z_ const char *_Mode)
_Check_return_opt_ _CRTIMP int __cdecl fputc(_In_ int _Ch, _Inout_ FILE *_File)
_Check_return_opt_ _CRTIMP int __cdecl fclose(_Inout_ FILE *_File)
#define sprintf(buf, format,...)
#define comment(fmt, arg1)
static const struct encodedInt enums[]
#define LIST_FOR_EACH_ENTRY(elem, list, type, field)
__WINE_SERVER_LIST_INLINE struct list * list_next(const struct list *list, const struct list *elem)
#define LIST_FOR_EACH_ENTRY_REV(elem, list, type, field)
static const void * body(MD5_CTX *ctx, const void *data, unsigned long size)
union _statement_t::@5026 u
struct _type_list_t * next
union _type_t::@5025 details
struct iface_details * iface
struct namespace * parent
char * format_namespace(struct namespace *namespace, const char *prefix, const char *separator, const char *suffix)
const char * type_get_name(const type_t *type, enum name_type name_type)
static int type_array_is_decl_as_ptr(const type_t *type)
static enum type_type type_get_type(const type_t *type)
static const expr_t * type_bitfield_get_bits(const type_t *type)
static int type_basic_get_sign(const type_t *type)
static type_t * type_function_get_rettype(const type_t *type)
static var_list_t * type_union_get_cases(const type_t *type)
static type_t * type_bitfield_get_field(const type_t *type)
static enum type_basic_type type_basic_get_type(const type_t *type)
static type_t * type_alias_get_aliasee(const type_t *type)
static int type_is_defined(const type_t *type)
static var_list_t * type_struct_get_fields(const type_t *type)
static int type_is_complete(const type_t *type)
static var_list_t * type_encapsulated_union_get_fields(const type_t *type)
static int type_is_alias(const type_t *type)
static type_t * type_iface_get_inherit(const type_t *type)
static type_t * type_array_get_element(const type_t *type)
static var_list_t * type_function_get_args(const type_t *type)
static unsigned int type_array_get_dim(const type_t *type)
static statement_list_t * type_iface_get_stmts(const type_t *type)
static type_t * type_pointer_get_ref(const type_t *type)
static var_list_t * type_enum_get_values(const type_t *type)
void start_cplusplus_guard(FILE *fp)
const char * prefix_server
void end_cplusplus_guard(FILE *fp)
const char * prefix_client
@ TYPE_ENCAPSULATED_UNION
static enum type_type type_get_type_detect_alias(const type_t *type)
static var_list_t * type_get_function_args(const type_t *func_type)
static int is_global_namespace(const struct namespace *namespace)
@ TYPE_BASIC_ERROR_STATUS_T
#define STATEMENTS_FOR_EACH_FUNC(stmt, stmts)
void int int ULONGLONG int va_list * ap