projects
/
reactos.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
679f8ce
)
[WIDL]
author
Thomas Faber
<thomas.faber@reactos.org>
Tue, 16 Oct 2012 06:43:32 +0000
(06:43 +0000)
committer
Thomas Faber
<thomas.faber@reactos.org>
Tue, 16 Oct 2012 06:43:32 +0000
(06:43 +0000)
- Forward-declare coclasses as 'class' in C++ to fix MSVC warnings. Already applied upstream.
CORE-6587 #resolve
svn path=/trunk/; revision=57566
reactos/tools/widl/header.c
patch
|
blob
|
history
diff --git
a/reactos/tools/widl/header.c
b/reactos/tools/widl/header.c
index
309eaf8
..
98301d2
100644
(file)
--- a/
reactos/tools/widl/header.c
+++ b/
reactos/tools/widl/header.c
@@
-1300,7
+1300,11
@@
static void write_coclass_forward(FILE *header, type_t *cocl)
{
fprintf(header, "#ifndef __%s_FWD_DEFINED__\n", cocl->name);
fprintf(header, "#define __%s_FWD_DEFINED__\n", cocl->name);
+ fprintf(header, "#ifdef __cplusplus\n");
+ fprintf(header, "typedef class %s %s;\n", cocl->name, cocl->name);
+ fprintf(header, "#else\n");
fprintf(header, "typedef struct %s %s;\n", cocl->name, cocl->name);
+ fprintf(header, "#endif /* defined __cplusplus */\n");
fprintf(header, "#endif /* defined __%s_FWD_DEFINED__ */\n\n", cocl->name );
}