Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
678ce987
Commit
678ce987
authored
Jul 28, 2006
by
Dan Hipschman
Committed by
Alexandre Julliard
Jul 29, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Encode coclass types in typelibs.
parent
9265d775
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
2 deletions
+12
-2
parser.y
tools/widl/parser.y
+3
-0
widltypes.h
tools/widl/widltypes.h
+3
-1
write_msft.c
tools/widl/write_msft.c
+6
-1
No files found.
tools/widl/parser.y
View file @
678ce987
...
...
@@ -638,6 +638,7 @@ int_std: tINT { $$ = make_type(RPC_FC_LONG, &std_int); } /* win32 only */
coclass: tCOCLASS aIDENTIFIER { $$ = make_class($2); }
| tCOCLASS aKNOWNTYPE { $$ = find_type($2, 0);
if ($$->defined) yyerror("multiple definition error");
if ($$->kind != TKIND_COCLASS) yyerror("%s was not declared a coclass", $2);
}
;
...
...
@@ -1060,6 +1061,7 @@ static type_t *make_type(unsigned char type, type_t *ref)
{
type_t *t = xmalloc(sizeof(type_t));
t->name = NULL;
t->kind = TKIND_PRIMITIVE;
t->type = type;
t->ref = ref;
t->attrs = NULL;
...
...
@@ -1153,6 +1155,7 @@ static type_t *make_class(char *name)
{
type_t *c = make_type(0, NULL);
c->name = name;
c->kind = TKIND_COCLASS;
INIT_LINK(c);
return c;
}
...
...
tools/widl/widltypes.h
View file @
678ce987
...
...
@@ -160,7 +160,8 @@ enum expr_type
enum
type_kind
{
TKIND_ENUM
=
0
,
TKIND_PRIMITIVE
=
-
1
,
TKIND_ENUM
,
TKIND_RECORD
,
TKIND_MODULE
,
TKIND_INTERFACE
,
...
...
@@ -199,6 +200,7 @@ struct _expr_t {
struct
_type_t
{
const
char
*
name
;
enum
type_kind
kind
;
unsigned
char
type
;
struct
_type_t
*
ref
;
const
attr_t
*
attrs
;
...
...
tools/widl/write_msft.c
View file @
678ce987
...
...
@@ -740,6 +740,7 @@ static importinfo_t *find_importinfo(msft_typelib_t *typelib, const char *name)
static
void
add_structure_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
structure
);
static
void
add_interface_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
interface
);
static
void
add_enum_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
enumeration
);
static
void
add_coclass_typeinfo
(
msft_typelib_t
*
typelib
,
type_t
*
cls
);
/****************************************************************************
...
...
@@ -973,7 +974,11 @@ static int encode_type(
add_enum_typeinfo
(
typelib
,
type
);
break
;
case
0
:
error
(
"encode_type: VT_USERDEFINED - can't yet add typedef's on the fly
\n
"
);
if
(
type
->
kind
==
TKIND_COCLASS
)
add_coclass_typeinfo
(
typelib
,
type
);
else
error
(
"encode_type: VT_USERDEFINED - can't yet add typedef's on the fly
\n
"
);
break
;
default:
error
(
"encode_type: VT_USERDEFINED - unhandled type %d
\n
"
,
type
->
type
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment