mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-01-28 22:04:43 -08:00
Rebase against f72ef20e88fba67254caf0124ab8713e3d15fa2a.
This commit is contained in:
parent
bd135b1477
commit
5c5a8f3b2c
@ -51,7 +51,7 @@ usage()
|
||||
# Get the upstream commit sha
|
||||
upstream_commit()
|
||||
{
|
||||
echo "24b9203d3544001dd51894f1c1edd99819367198"
|
||||
echo "f72ef20e88fba67254caf0124ab8713e3d15fa2a"
|
||||
}
|
||||
|
||||
# Show version information
|
||||
@ -4478,29 +4478,33 @@ fi
|
||||
# | * [#49998] widl - Support WinRT idls
|
||||
# |
|
||||
# | Modified files:
|
||||
# | * include/windows.foundation.idl, include/windows.media.speechsynthesis.idl, tools/widl/expr.c, tools/widl/hash.c,
|
||||
# | tools/widl/hash.h, tools/widl/header.c, tools/widl/parser.l, tools/widl/parser.y, tools/widl/typegen.c,
|
||||
# | tools/widl/typelib.c, tools/widl/typetree.c, tools/widl/typetree.h, tools/widl/utils.c, tools/widl/utils.h,
|
||||
# | tools/widl/widltypes.h
|
||||
# | * include/windows.foundation.idl, include/windows.media.speechsynthesis.idl, include/winnt.h, tools/widl/expr.c,
|
||||
# | tools/widl/hash.c, tools/widl/hash.h, tools/widl/header.c, tools/widl/parser.l, tools/widl/parser.y,
|
||||
# | tools/widl/typegen.c, tools/widl/typelib.c, tools/widl/typetree.c, tools/widl/typetree.h, tools/widl/utils.c,
|
||||
# | tools/widl/utils.h, tools/widl/widltypes.h
|
||||
# |
|
||||
if test "$enable_widl_winrt_support" -eq 1; then
|
||||
patch_apply widl-winrt-support/0005-widl-Support-WinRT-runtimeclass-type.patch
|
||||
patch_apply widl-winrt-support/0006-widl-Support-WinRT-eventadd-eventremove-attributes.patch
|
||||
patch_apply widl-winrt-support/0007-widl-Support-WinRT-flags-attribute-parsing.patch
|
||||
patch_apply widl-winrt-support/0008-widl-Support-using-qualified-names-for-interfaces.patch
|
||||
patch_apply widl-winrt-support/0009-widl-Support-WinRT-static-attribute-parsing.patch
|
||||
patch_apply widl-winrt-support/0010-widl-Support-WinRT-requires-keyword.patch
|
||||
patch_apply widl-winrt-support/0011-widl-Support-WinRT-activatable-attribute.patch
|
||||
patch_apply widl-winrt-support/0012-widl-Support-WinRT-parameterized-type-parsing.patch
|
||||
patch_apply widl-winrt-support/0013-widl-Introduce-new-strappend-helper.patch
|
||||
patch_apply widl-winrt-support/0014-widl-Support-partially-specialized-parameterized-typ.patch
|
||||
patch_apply widl-winrt-support/0015-widl-Support-WinRT-parameterized-interface-type.patch
|
||||
patch_apply widl-winrt-support/0016-widl-Support-WinRT-delegate-type.patch
|
||||
patch_apply widl-winrt-support/0017-widl-Support-WinRT-parameterized-delegate-type.patch
|
||||
patch_apply widl-winrt-support/0018-widl-Compute-signatures-for-parameterized-types.patch
|
||||
patch_apply widl-winrt-support/0019-widl-Compute-uuids-for-parameterized-types.patch
|
||||
patch_apply widl-winrt-support/0020-widl-Generate-helper-macros-for-WinRT-implementation.patch
|
||||
patch_apply widl-winrt-support/0021-include-Add-IVectorView-HSTRING-declaration-to-windo.patch
|
||||
patch_apply widl-winrt-support/0001-include-Define-DECLSPEC_SELECTANY-on-MinGW.patch
|
||||
patch_apply widl-winrt-support/0002-widl-Generate-WinRT-runtimeclass-name-constants.patch
|
||||
patch_apply widl-winrt-support/0003-widl-Support-WinRT-eventadd-eventremove-attributes.patch
|
||||
patch_apply widl-winrt-support/0004-widl-Support-WinRT-flags-attribute-parsing.patch
|
||||
patch_apply widl-winrt-support/0005-widl-Support-using-qualified-names-for-interfaces.patch
|
||||
patch_apply widl-winrt-support/0006-widl-Support-WinRT-static-attribute-parsing.patch
|
||||
patch_apply widl-winrt-support/0007-widl-Support-WinRT-requires-keyword.patch
|
||||
patch_apply widl-winrt-support/0008-widl-Support-WinRT-activatable-attribute.patch
|
||||
patch_apply widl-winrt-support/0009-widl-Support-WinRT-parameterized-type-parsing.patch
|
||||
patch_apply widl-winrt-support/0010-widl-Introduce-new-strappend-helper.patch
|
||||
patch_apply widl-winrt-support/0011-widl-Support-partially-specialized-parameterized-typ.patch
|
||||
patch_apply widl-winrt-support/0012-widl-Support-WinRT-parameterized-interface-type.patch
|
||||
patch_apply widl-winrt-support/0013-widl-Support-WinRT-delegate-type.patch
|
||||
patch_apply widl-winrt-support/0014-widl-Support-WinRT-parameterized-delegate-type.patch
|
||||
patch_apply widl-winrt-support/0015-widl-Compute-signatures-for-parameterized-types.patch
|
||||
patch_apply widl-winrt-support/0016-widl-Compute-uuids-for-parameterized-types.patch
|
||||
patch_apply widl-winrt-support/0017-widl-Generate-helper-macros-for-WinRT-implementation.patch
|
||||
patch_apply widl-winrt-support/0018-include-Add-IVectorView-HSTRING-declaration-to-windo.patch
|
||||
patch_apply widl-winrt-support/0019-widl-Never-use-the-namespace-ABI-prefix-for-global-t.patch
|
||||
patch_apply widl-winrt-support/0020-widl-Precompute-qualified-type-names-and-use-them-fo.patch
|
||||
patch_apply widl-winrt-support/0021-widl-Define-the-C-type-name-as-an-alias-for-the-C-qu.patch
|
||||
fi
|
||||
|
||||
# Patchset windows.media.speech.dll
|
||||
|
@ -0,0 +1,25 @@
|
||||
From 9c00130e319055e1b8fb336338e656f8ca5d64b9 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 19 Jan 2021 13:47:45 +0100
|
||||
Subject: [PATCH] include: Define DECLSPEC_SELECTANY on MinGW.
|
||||
|
||||
---
|
||||
include/winnt.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/include/winnt.h b/include/winnt.h
|
||||
index 5b3efe61385..bb045fa2745 100644
|
||||
--- a/include/winnt.h
|
||||
+++ b/include/winnt.h
|
||||
@@ -110,6 +110,8 @@ extern "C" {
|
||||
#ifndef DECLSPEC_SELECTANY
|
||||
#if defined(_MSC_VER) && (_MSC_VER >= 1100)
|
||||
#define DECLSPEC_SELECTANY __declspec(selectany)
|
||||
+#elif defined(__MINGW32__)
|
||||
+#define DECLSPEC_SELECTANY __attribute__((selectany))
|
||||
#else
|
||||
#define DECLSPEC_SELECTANY
|
||||
#endif
|
||||
--
|
||||
2.29.2
|
||||
|
@ -0,0 +1,35 @@
|
||||
From 41ffc864a47b18e138fe92e6f5be78d9cc1e7936 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 19 Jan 2021 13:51:25 +0100
|
||||
Subject: [PATCH] widl: Generate WinRT runtimeclass name constants.
|
||||
|
||||
---
|
||||
tools/widl/header.c | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index ad205df0d05..153437971cc 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -1698,6 +1698,7 @@ static void write_runtimeclass(FILE *header, type_t *runtimeclass)
|
||||
{
|
||||
expr_t *contract = get_attrp(runtimeclass->attrs, ATTR_CONTRACT);
|
||||
char *name, *c_name;
|
||||
+ size_t i, len;
|
||||
name = format_namespace(runtimeclass->namespace, "", ".", runtimeclass->name, NULL);
|
||||
c_name = format_namespace(runtimeclass->namespace, "", "_", runtimeclass->name, NULL);
|
||||
fprintf(header, "/*\n");
|
||||
@@ -1706,6 +1707,10 @@ static void write_runtimeclass(FILE *header, type_t *runtimeclass)
|
||||
if (contract) write_apicontract_guard_start(header, contract);
|
||||
fprintf(header, "#ifndef RUNTIMECLASS_%s_DEFINED\n", c_name);
|
||||
fprintf(header, "#define RUNTIMECLASS_%s_DEFINED\n", c_name);
|
||||
+ /* FIXME: MIDL generates extern const here but GCC warns if extern is initialized */
|
||||
+ fprintf(header, "/*extern*/ const DECLSPEC_SELECTANY WCHAR RuntimeClass_%s[] = {", c_name);
|
||||
+ for (i = 0, len = strlen(name); i < len; ++i) fprintf(header, "'%c',", name[i]);
|
||||
+ fprintf(header, "0};\n");
|
||||
fprintf(header, "#endif /* RUNTIMECLASS_%s_DEFINED */\n", c_name);
|
||||
free(c_name);
|
||||
free(name);
|
||||
--
|
||||
2.29.2
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 0b5447c4b3f89a00c295acdd124f532550079b4c Mon Sep 17 00:00:00 2001
|
||||
From 6ecf89d3afe33a136e41c0106adeb0b27fe74c7f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Thu, 1 Oct 2020 20:10:02 +0200
|
||||
Subject: [PATCH] widl: Support WinRT eventadd/eventremove attributes.
|
||||
@ -11,10 +11,10 @@ Subject: [PATCH] widl: Support WinRT eventadd/eventremove attributes.
|
||||
4 files changed, 15 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index 93bcb4f5214..ae392fe7de4 100644
|
||||
index 153437971cc..4db244fef5d 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -187,6 +187,10 @@ const char *get_name(const var_t *v)
|
||||
@@ -185,6 +185,10 @@ const char *get_name(const var_t *v)
|
||||
{
|
||||
static char *buffer;
|
||||
free( buffer );
|
||||
@ -26,7 +26,7 @@ index 93bcb4f5214..ae392fe7de4 100644
|
||||
return buffer = strmake( "get_%s", v->name );
|
||||
if (is_attr( v->attrs, ATTR_PROPPUT ))
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 80a6bc38afb..4932e0adbe2 100644
|
||||
index 6bbfed5e80b..a0b9714dfa0 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -359,6 +359,8 @@ static const struct keyword attr_keywords[] =
|
||||
@ -39,7 +39,7 @@ index 80a6bc38afb..4932e0adbe2 100644
|
||||
{"explicit_handle", tEXPLICITHANDLE, 0},
|
||||
{"fault_status", tFAULTSTATUS, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 93714ebf712..b19fb16efd0 100644
|
||||
index d12caa06b63..537b4f332f3 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -197,6 +197,7 @@ static typelib_t *current_typelib;
|
||||
@ -78,7 +78,7 @@ index 93714ebf712..b19fb16efd0 100644
|
||||
if (is_attr(func->attrs, ATTR_PROPPUT) != is_attr(func_iter->attrs, ATTR_PROPPUT)) continue;
|
||||
if (is_attr(func->attrs, ATTR_PROPPUTREF) != is_attr(func_iter->attrs, ATTR_PROPPUTREF)) continue;
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 77313b30c0f..75510ee50b1 100644
|
||||
index 46a44dac039..51d325ce930 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -103,6 +103,8 @@ enum attr_type
|
@ -1,4 +1,4 @@
|
||||
From 025a89076222bff7f5abb7c1c8992c93eaf92be6 Mon Sep 17 00:00:00 2001
|
||||
From 837aa860559609889bd9dbf189960a3dca021ce5 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Mon, 12 Oct 2020 18:02:59 +0200
|
||||
Subject: [PATCH] widl: Support WinRT flags attribute parsing.
|
||||
@ -10,7 +10,7 @@ Subject: [PATCH] widl: Support WinRT flags attribute parsing.
|
||||
3 files changed, 5 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 4932e0adbe2..51142ded6e6 100644
|
||||
index a0b9714dfa0..7e20d30e7f0 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -364,6 +364,7 @@ static const struct keyword attr_keywords[] =
|
||||
@ -22,7 +22,7 @@ index 4932e0adbe2..51142ded6e6 100644
|
||||
{"free", tFREE, 0},
|
||||
{"handle", tHANDLE, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index b19fb16efd0..110b570f4e4 100644
|
||||
index 537b4f332f3..480552e3723 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -202,6 +202,7 @@ static typelib_t *current_typelib;
|
||||
@ -50,7 +50,7 @@ index b19fb16efd0..110b570f4e4 100644
|
||||
/* ATTR_HANDLE */ { 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "handle" },
|
||||
/* ATTR_HELPCONTEXT */ { 0, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, "helpcontext" },
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 75510ee50b1..a3283761256 100644
|
||||
index 51d325ce930..0fba33d6a09 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -108,6 +108,7 @@ enum attr_type
|
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
From 82858b36352aac56942221757ed5ecf9bc40e42b Mon Sep 17 00:00:00 2001
|
||||
From 2719c1018570b5fed5058541f54a3334044de160 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Fri, 25 Sep 2020 17:13:47 +0200
|
||||
Subject: [PATCH] widl: Support using qualified names for interfaces.
|
||||
@ -11,10 +11,10 @@ the lookup namespace if it's active.
|
||||
2 files changed, 38 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/include/windows.media.speechsynthesis.idl b/include/windows.media.speechsynthesis.idl
|
||||
index 90bc9f279c6..89fe616b9b3 100644
|
||||
index 71c51b74c0c..502261f79c6 100644
|
||||
--- a/include/windows.media.speechsynthesis.idl
|
||||
+++ b/include/windows.media.speechsynthesis.idl
|
||||
@@ -65,7 +65,7 @@ namespace Windows {
|
||||
@@ -64,7 +64,7 @@ namespace Windows {
|
||||
]
|
||||
runtimeclass VoiceInformation
|
||||
{
|
||||
@ -24,7 +24,7 @@ index 90bc9f279c6..89fe616b9b3 100644
|
||||
}
|
||||
}
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 110b570f4e4..6f1a7a68e9c 100644
|
||||
index 480552e3723..1e3e254ec8c 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -75,6 +75,8 @@ static void append_chain_callconv(type_t *chain, char *callconv);
|
@ -1,72 +1,16 @@
|
||||
From d8ed7fe746a0ae8506683ea7aeadfb33ac6e0fa3 Mon Sep 17 00:00:00 2001
|
||||
From 0a3ad97a115851c604c6291de3fc71ef7c418cba Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 13 Oct 2020 14:30:32 +0200
|
||||
Subject: [PATCH] widl: Support WinRT static attribute parsing.
|
||||
|
||||
---
|
||||
tools/widl/header.c | 30 ++++++++++++++++++++++++++++++
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 8 ++++++++
|
||||
tools/widl/widltypes.h | 1 +
|
||||
4 files changed, 40 insertions(+)
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 8 ++++++++
|
||||
tools/widl/widltypes.h | 1 +
|
||||
3 files changed, 10 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index ae392fe7de4..cb8231f213d 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -109,6 +109,17 @@ int is_attr(const attr_list_t *list, enum attr_type t)
|
||||
return 0;
|
||||
}
|
||||
|
||||
+static void get_attr_statics(const attr_list_t *attrs, expr_list_t *list)
|
||||
+{
|
||||
+ const attr_t *attr;
|
||||
+ if (!attrs) return;
|
||||
+ LIST_FOR_EACH_ENTRY( attr, attrs, const attr_t, entry )
|
||||
+ {
|
||||
+ if (attr->type != ATTR_STATIC) continue;
|
||||
+ list_add_tail(list, &((expr_t *)attr->u.pval)->entry);
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
void *get_attrp(const attr_list_t *list, enum attr_type t)
|
||||
{
|
||||
const attr_t *attr;
|
||||
@@ -1495,6 +1506,8 @@ static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
{
|
||||
expr_t *contract = get_attrp(type->attrs, ATTR_CONTRACT);
|
||||
type_t *exclusiveto = get_attrp(type->attrs, ATTR_EXCLUSIVETO);
|
||||
+ expr_list_t statics = LIST_INIT(statics);
|
||||
+ get_attr_statics(type->attrs, &statics);
|
||||
fprintf(header, " *\n");
|
||||
if (contract)
|
||||
{
|
||||
@@ -1510,6 +1523,23 @@ static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
fprintf(header, " * Interface is a part of the implementation of type %s\n *\n", name);
|
||||
free(name);
|
||||
}
|
||||
+ if (!list_empty(&statics))
|
||||
+ {
|
||||
+ expr_t *expr;
|
||||
+ fprintf(header, " * RuntimeClass contains static methods.\n");
|
||||
+ LIST_FOR_EACH_ENTRY(expr, &statics, expr_t, entry)
|
||||
+ {
|
||||
+ const type_t *iface = expr->u.tref.type, *apicontract = expr->ref->u.tref.type;
|
||||
+ int version_req = expr->ref->ref->u.lval;
|
||||
+ char *iface_name = format_namespace(iface->namespace, "", ".", iface->name, NULL);
|
||||
+ char *name = format_namespace(apicontract->namespace, "", ".", apicontract->name, NULL);
|
||||
+ fprintf(header, " * Static Methods exist on the %s interface starting with version %d.%d of the %s API contract\n",
|
||||
+ iface_name, (version_req >> 16) & 0xffff, version_req & 0xffff, name);
|
||||
+ free(iface_name);
|
||||
+ free(name);
|
||||
+ }
|
||||
+ fprintf(header, " *\n");
|
||||
+ }
|
||||
if (type_get_type(type) == TYPE_RUNTIMECLASS)
|
||||
{
|
||||
ifref_list_t *ifaces = type_runtimeclass_get_ifaces(type);
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 51142ded6e6..2695e8cf622 100644
|
||||
index 7e20d30e7f0..dd7cdae5338 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -426,6 +426,7 @@ static const struct keyword attr_keywords[] =
|
||||
@ -78,7 +22,7 @@ index 51142ded6e6..2695e8cf622 100644
|
||||
{"string", tSTRING, 0},
|
||||
{"switch_is", tSWITCHIS, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 6f1a7a68e9c..908e7b6d4da 100644
|
||||
index 1e3e254ec8c..01cdbffe4c7 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -285,6 +285,7 @@ static typelib_t *current_typelib;
|
||||
@ -118,7 +62,7 @@ index 6f1a7a68e9c..908e7b6d4da 100644
|
||||
/* ATTR_STRING */ { 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, "string" },
|
||||
/* ATTR_SWITCHIS */ { 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, "switch_is" },
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index a3283761256..0e001f20cfb 100644
|
||||
index 0fba33d6a09..8e9ba3e4460 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -162,6 +162,7 @@ enum attr_type
|
@ -1,50 +1,18 @@
|
||||
From 191aa18a3ce42474ef07e81132247b9f388bbc82 Mon Sep 17 00:00:00 2001
|
||||
From ca531da15e6fb32e182d83e98857e6945163e083 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 13 Oct 2020 00:31:57 +0200
|
||||
Subject: [PATCH] widl: Support WinRT requires keyword.
|
||||
|
||||
---
|
||||
tools/widl/header.c | 13 +++++++++++
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 49 ++++++++++++++++++++++++++++++++----------
|
||||
tools/widl/typetree.c | 5 ++++-
|
||||
tools/widl/typetree.h | 9 +++++++-
|
||||
tools/widl/widltypes.h | 1 +
|
||||
6 files changed, 65 insertions(+), 13 deletions(-)
|
||||
5 files changed, 52 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index cb8231f213d..78f17b0eee2 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -1506,6 +1506,7 @@ static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
{
|
||||
expr_t *contract = get_attrp(type->attrs, ATTR_CONTRACT);
|
||||
type_t *exclusiveto = get_attrp(type->attrs, ATTR_EXCLUSIVETO);
|
||||
+ type_list_t *requires = type->type_type == TYPE_INTERFACE ? type_iface_get_requires(type) : NULL;
|
||||
expr_list_t statics = LIST_INIT(statics);
|
||||
get_attr_statics(type->attrs, &statics);
|
||||
fprintf(header, " *\n");
|
||||
@@ -1523,6 +1524,18 @@ static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
fprintf(header, " * Interface is a part of the implementation of type %s\n *\n", name);
|
||||
free(name);
|
||||
}
|
||||
+ if (requires)
|
||||
+ {
|
||||
+ type_list_t *req;
|
||||
+ fprintf(header, " * Any object which implements this interface must also implement the following interfaces:\n");
|
||||
+ for (req = requires; req; req = req->next)
|
||||
+ {
|
||||
+ char *name = format_namespace(req->type->namespace, "", ".", req->type->name, NULL);
|
||||
+ fprintf(header, " * %s\n", name);
|
||||
+ free(name);
|
||||
+ }
|
||||
+ fprintf(header, " *\n");
|
||||
+ }
|
||||
if (!list_empty(&statics))
|
||||
{
|
||||
expr_t *expr;
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 2695e8cf622..5b332abf455 100644
|
||||
index dd7cdae5338..0a5ef3c1b89 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -298,6 +298,7 @@ static const struct keyword keywords[] = {
|
||||
@ -56,7 +24,7 @@ index 2695e8cf622..5b332abf455 100644
|
||||
{"short", tSHORT, 0},
|
||||
{"signed", tSIGNED, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 908e7b6d4da..bf89ba771ac 100644
|
||||
index 01cdbffe4c7..b774b01cdd7 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -38,12 +38,6 @@
|
||||
@ -164,7 +132,7 @@ index 908e7b6d4da..bf89ba771ac 100644
|
||||
static attr_list_t *move_attr(attr_list_t *dst, attr_list_t *src, enum attr_type type)
|
||||
{
|
||||
attr_t *attr;
|
||||
@@ -3058,7 +3085,7 @@ static void check_async_uuid(type_t *iface)
|
||||
@@ -3060,7 +3087,7 @@ static void check_async_uuid(type_t *iface)
|
||||
stmts = append_statement(stmts, make_statement_declaration(finish_func));
|
||||
}
|
||||
|
||||
@ -174,7 +142,7 @@ index 908e7b6d4da..bf89ba771ac 100644
|
||||
}
|
||||
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index 107a2d36a2f..90c34302ca1 100644
|
||||
index a18ffe1f4a5..fa21766b253 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -463,7 +463,7 @@ static unsigned int compute_method_indexes(type_t *iface)
|
||||
@ -211,7 +179,7 @@ index 107a2d36a2f..90c34302ca1 100644
|
||||
compute_method_indexes(dispiface);
|
||||
}
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index 951084cf875..8c555b91656 100644
|
||||
index dc44c3f5fa7..a4ba4333bae 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -45,7 +45,7 @@ type_t *type_new_nonencapsulated_union(const char *name, int defined, var_list_t
|
||||
@ -223,7 +191,7 @@ index 951084cf875..8c555b91656 100644
|
||||
void type_dispinterface_define(type_t *iface, var_list_t *props, var_list_t *methods);
|
||||
void type_dispinterface_define_from_iface(type_t *dispiface, type_t *iface);
|
||||
void type_module_define(type_t *module, statement_list_t *stmts);
|
||||
@@ -169,6 +169,13 @@ static inline type_t *type_iface_get_inherit(const type_t *type)
|
||||
@@ -170,6 +170,13 @@ static inline type_t *type_iface_get_inherit(const type_t *type)
|
||||
return type->details.iface->inherit;
|
||||
}
|
||||
|
||||
@ -238,10 +206,10 @@ index 951084cf875..8c555b91656 100644
|
||||
{
|
||||
type = type_get_real_type(type);
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 0e001f20cfb..1848e891643 100644
|
||||
index 8e9ba3e4460..7db2deb1839 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -386,6 +386,7 @@ struct iface_details
|
||||
@@ -385,6 +385,7 @@ struct iface_details
|
||||
struct _type_t *inherit;
|
||||
struct _type_t *disp_inherit;
|
||||
struct _type_t *async_iface;
|
@ -1,46 +1,16 @@
|
||||
From 05b4b34e57597d00a0d80d2247356ee5ba05db95 Mon Sep 17 00:00:00 2001
|
||||
From 58ae5534e33ac94eaac4885bb0d9aa31abc5496d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 13 Oct 2020 11:35:29 +0200
|
||||
Subject: [PATCH] widl: Support WinRT activatable attribute.
|
||||
|
||||
---
|
||||
tools/widl/header.c | 11 +++++++++++
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 3 +++
|
||||
tools/widl/widltypes.h | 1 +
|
||||
4 files changed, 16 insertions(+)
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 3 +++
|
||||
tools/widl/widltypes.h | 1 +
|
||||
3 files changed, 5 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index 78f17b0eee2..dd4ba935af7 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -1505,6 +1505,7 @@ static char *format_apicontract_macro(const type_t *type)
|
||||
static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
{
|
||||
expr_t *contract = get_attrp(type->attrs, ATTR_CONTRACT);
|
||||
+ expr_t *activatable = get_attrp(type->attrs, ATTR_ACTIVATABLE);
|
||||
type_t *exclusiveto = get_attrp(type->attrs, ATTR_EXCLUSIVETO);
|
||||
type_list_t *requires = type->type_type == TYPE_INTERFACE ? type_iface_get_requires(type) : NULL;
|
||||
expr_list_t statics = LIST_INIT(statics);
|
||||
@@ -1518,6 +1519,16 @@ static void write_winrt_type_comments(FILE *header, const type_t *type)
|
||||
fprintf(header, " * Introduced to %s in version %d.%d\n *\n", name, (ver >> 16) & 0xffff, ver & 0xffff);
|
||||
free(name);
|
||||
}
|
||||
+ if (activatable)
|
||||
+ {
|
||||
+ const type_t *apicontract = activatable->u.tref.type;
|
||||
+ int version_req = activatable->ref->u.lval;
|
||||
+ char *name = format_namespace(apicontract->namespace, "", ".", apicontract->name, NULL);
|
||||
+ fprintf(header, " * RuntimeClass can be activated.\n");
|
||||
+ fprintf(header, " * Type can be activated via RoActivateInstance starting with version %d.%d of the %s API contract\n *\n",
|
||||
+ (version_req >> 16) & 0xffff, version_req & 0xffff, name);
|
||||
+ free(name);
|
||||
+ }
|
||||
if (exclusiveto)
|
||||
{
|
||||
char *name = format_namespace(exclusiveto->namespace, "", ".", exclusiveto->name, NULL);
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 5b332abf455..0b6b51b847e 100644
|
||||
index 0a5ef3c1b89..e09722d7023 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -321,6 +321,7 @@ static const struct keyword keywords[] = {
|
||||
@ -52,7 +22,7 @@ index 5b332abf455..0b6b51b847e 100644
|
||||
{"agile", tAGILE, 1},
|
||||
{"all_nodes", tALLNODES, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index bf89ba771ac..4a464d28120 100644
|
||||
index b774b01cdd7..e5a39872524 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -173,6 +173,7 @@ static typelib_t *current_typelib;
|
||||
@ -80,7 +50,7 @@ index bf89ba771ac..4a464d28120 100644
|
||||
/* ATTR_ALLOCATE */ { 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "allocate" },
|
||||
/* ATTR_ANNOTATION */ { 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "annotation" },
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 1848e891643..345d1a90d01 100644
|
||||
index 7db2deb1839..a3000a7417b 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -69,6 +69,7 @@ typedef struct list warning_list_t;
|
@ -1,4 +1,4 @@
|
||||
From 9c28d7140282cb09d7cc37f6b16d88789b49285f Mon Sep 17 00:00:00 2001
|
||||
From e0a0dba826b36993a81ae1df1186e53bfbe8e61c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 13 Oct 2020 16:31:16 +0200
|
||||
Subject: [PATCH] widl: Support WinRT parameterized type parsing.
|
||||
@ -79,10 +79,10 @@ index 13bd5a889aa..c83e9aa5ec0 100644
|
||||
break;
|
||||
case TYPE_ALIAS:
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index dd4ba935af7..4de34a59d22 100644
|
||||
index 4db244fef5d..344b6891747 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -501,6 +501,8 @@ void write_type_left(FILE *h, const decl_spec_t *ds, enum name_type name_type, i
|
||||
@@ -488,6 +488,8 @@ void write_type_left(FILE *h, const decl_spec_t *ds, enum name_type name_type, i
|
||||
break;
|
||||
}
|
||||
case TYPE_APICONTRACT:
|
||||
@ -91,7 +91,7 @@ index dd4ba935af7..4de34a59d22 100644
|
||||
/* shouldn't be here */
|
||||
assert(0);
|
||||
break;
|
||||
@@ -568,6 +570,8 @@ void write_type_right(FILE *h, type_t *t, int is_field)
|
||||
@@ -555,6 +557,8 @@ void write_type_right(FILE *h, type_t *t, int is_field)
|
||||
case TYPE_RUNTIMECLASS:
|
||||
break;
|
||||
case TYPE_APICONTRACT:
|
||||
@ -100,7 +100,7 @@ index dd4ba935af7..4de34a59d22 100644
|
||||
/* not supposed to be here */
|
||||
assert(0);
|
||||
break;
|
||||
@@ -1969,10 +1973,8 @@ static void write_header_stmts(FILE *header, const statement_list_t *stmts, cons
|
||||
@@ -1860,10 +1864,8 @@ static void write_header_stmts(FILE *header, const statement_list_t *stmts, cons
|
||||
write_apicontract(header, stmt->u.type);
|
||||
else if (type_get_type(stmt->u.type) == TYPE_RUNTIMECLASS)
|
||||
write_runtimeclass(header, stmt->u.type);
|
||||
@ -113,7 +113,7 @@ index dd4ba935af7..4de34a59d22 100644
|
||||
case STMT_TYPEREF:
|
||||
/* FIXME: shouldn't write out forward declarations for undefined
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 4a464d28120..48135d4372e 100644
|
||||
index e5a39872524..9083df8cf27 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -81,6 +81,8 @@ static var_t *reg_const(var_t *var);
|
||||
@ -288,7 +288,7 @@ index ace6424e3a0..6f6c5f3ccc8 100644
|
||||
assert(0);
|
||||
break;
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index 90c34302ca1..b9bc4a1f075 100644
|
||||
index fa21766b253..f451f8f3a1a 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -463,6 +463,36 @@ static unsigned int compute_method_indexes(type_t *iface)
|
||||
@ -329,7 +329,7 @@ index 90c34302ca1..b9bc4a1f075 100644
|
||||
{
|
||||
iface->details.iface = xmalloc(sizeof(*iface->details.iface));
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index 8c555b91656..b04a67f6b47 100644
|
||||
index a4ba4333bae..79c5a01ce3a 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -45,6 +45,8 @@ type_t *type_new_nonencapsulated_union(const char *name, int defined, var_list_t
|
||||
@ -341,7 +341,7 @@ index 8c555b91656..b04a67f6b47 100644
|
||||
void type_interface_define(type_t *iface, type_t *inherit, statement_list_t *stmts, type_list_t *requires);
|
||||
void type_dispinterface_define(type_t *iface, var_list_t *props, var_list_t *methods);
|
||||
void type_dispinterface_define_from_iface(type_t *dispiface, type_t *iface);
|
||||
@@ -234,6 +236,8 @@ static inline int type_is_complete(const type_t *type)
|
||||
@@ -235,6 +237,8 @@ static inline int type_is_complete(const type_t *type)
|
||||
case TYPE_RUNTIMECLASS:
|
||||
return TRUE;
|
||||
case TYPE_APICONTRACT:
|
||||
@ -351,10 +351,10 @@ index 8c555b91656..b04a67f6b47 100644
|
||||
break;
|
||||
}
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 345d1a90d01..8dd6958ba35 100644
|
||||
index a3000a7417b..2c0ac4003ce 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -437,6 +437,12 @@ struct runtimeclass_details
|
||||
@@ -436,6 +436,12 @@ struct runtimeclass_details
|
||||
ifref_list_t *ifaces;
|
||||
};
|
||||
|
||||
@ -367,7 +367,7 @@ index 345d1a90d01..8dd6958ba35 100644
|
||||
#define HASHMAX 64
|
||||
|
||||
struct namespace {
|
||||
@@ -465,6 +471,8 @@ enum type_type
|
||||
@@ -464,6 +470,8 @@ enum type_type
|
||||
TYPE_BITFIELD,
|
||||
TYPE_APICONTRACT,
|
||||
TYPE_RUNTIMECLASS,
|
||||
@ -376,7 +376,7 @@ index 345d1a90d01..8dd6958ba35 100644
|
||||
};
|
||||
|
||||
struct _type_t {
|
||||
@@ -486,6 +494,7 @@ struct _type_t {
|
||||
@@ -485,6 +493,7 @@ struct _type_t {
|
||||
struct bitfield_details bitfield;
|
||||
struct alias_details alias;
|
||||
struct runtimeclass_details runtimeclass;
|
@ -1,4 +1,4 @@
|
||||
From cbc4c4a9c0c7c1fc5c99fe665494e58008d67fc7 Mon Sep 17 00:00:00 2001
|
||||
From 99bc0225cdc921dc87d3906de145533690ad7816 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 1 Dec 2020 14:41:01 +0100
|
||||
Subject: [PATCH] widl: Introduce new strappend helper.
|
||||
@ -11,7 +11,7 @@ And use it for format_namespace to grow buffer as needed.
|
||||
3 files changed, 53 insertions(+), 31 deletions(-)
|
||||
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index b9bc4a1f075..3cf324cc7f6 100644
|
||||
index f451f8f3a1a..95c04c245b8 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -89,41 +89,25 @@ const char *type_get_name(const type_t *type, enum name_type name_type)
|
@ -1,4 +1,4 @@
|
||||
From 5d655b453867b46faf2fda420d08cad412b50729 Mon Sep 17 00:00:00 2001
|
||||
From 680c7575c78c63e8bc8e971d8f1385175bf5f106 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Mon, 12 Oct 2020 23:23:18 +0200
|
||||
Subject: [PATCH] widl: Support partially specialized parameterized type.
|
||||
@ -39,7 +39,7 @@ index ab7c4753c3b..5f7a49c38e4 100644
|
||||
contract(Windows.Foundation.FoundationContract, 1.0),
|
||||
uuid(bbe1fa4c-b0e3-4583-baef-1f1b2e483e56)
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 48135d4372e..14c9c5d007e 100644
|
||||
index 9083df8cf27..61bbe2a50ee 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -302,6 +302,8 @@ static typelib_t *current_typelib;
|
||||
@ -96,7 +96,7 @@ index 48135d4372e..14c9c5d007e 100644
|
||||
| base_type { $$ = $1; }
|
||||
| enumdef { $$ = $1; }
|
||||
| tENUM aIDENTIFIER { $$ = type_new_enum($2, current_namespace, FALSE, NULL); }
|
||||
@@ -3367,3 +3386,19 @@ static void check_def(const type_t *t)
|
||||
@@ -3369,3 +3388,19 @@ static void check_def(const type_t *t)
|
||||
error_loc("%s: redefinition error; original definition was at %s:%d\n",
|
||||
t->name, t->loc_info.input_name, t->loc_info.line_number);
|
||||
}
|
||||
@ -117,7 +117,7 @@ index 48135d4372e..14c9c5d007e 100644
|
||||
+ return type;
|
||||
+}
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index 3cf324cc7f6..e2d0a573c0d 100644
|
||||
index 95c04c245b8..d2c472fcca0 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -100,13 +100,40 @@ static size_t append_namespace(char **buf, size_t *len, size_t pos, struct names
|
||||
@ -180,7 +180,7 @@ index 3cf324cc7f6..e2d0a573c0d 100644
|
||||
{
|
||||
type_t *iface = make_type(TYPE_INTERFACE);
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index b04a67f6b47..472fdf2d5fc 100644
|
||||
index 79c5a01ce3a..c46a2629467 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -45,6 +45,8 @@ type_t *type_new_nonencapsulated_union(const char *name, int defined, var_list_t
|
||||
@ -193,10 +193,10 @@ index b04a67f6b47..472fdf2d5fc 100644
|
||||
void type_parameterized_interface_define(type_t *type, type_list_t *params, type_t *inherit, statement_list_t *stmts);
|
||||
void type_interface_define(type_t *iface, type_t *inherit, statement_list_t *stmts, type_list_t *requires);
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 8dd6958ba35..ff71a1859ae 100644
|
||||
index 2c0ac4003ce..be82342e31a 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -651,6 +651,7 @@ void init_loc_info(loc_info_t *);
|
||||
@@ -650,6 +650,7 @@ void init_loc_info(loc_info_t *);
|
||||
|
||||
char *format_namespace(struct namespace *namespace, const char *prefix, const char *separator, const char *suffix,
|
||||
const char *abi_prefix);
|
@ -1,4 +1,4 @@
|
||||
From 798ecb14bb4856d1bee11f97ab98158d81b9b504 Mon Sep 17 00:00:00 2001
|
||||
From 5ef017f5ca2e3676b9558f328b192033875d5ba1 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 1 Dec 2020 17:34:23 +0100
|
||||
Subject: [PATCH] widl: Support WinRT parameterized interface type.
|
||||
@ -8,19 +8,25 @@ blocks, in the same way MIDL does, generating a new interface to the
|
||||
header from the parameterized type template, replacing its parameters
|
||||
with the given types.
|
||||
---
|
||||
include/windows.media.speechsynthesis.idl | 23 +++
|
||||
include/windows.media.speechsynthesis.idl | 24 +++
|
||||
tools/widl/header.c | 7 +-
|
||||
tools/widl/parser.l | 1 +
|
||||
tools/widl/parser.y | 63 +++++-
|
||||
tools/widl/typetree.c | 238 ++++++++++++++++++++++
|
||||
tools/widl/typetree.h | 2 +
|
||||
6 files changed, 329 insertions(+), 5 deletions(-)
|
||||
6 files changed, 330 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/include/windows.media.speechsynthesis.idl b/include/windows.media.speechsynthesis.idl
|
||||
index 89fe616b9b3..40c45c82051 100644
|
||||
index 502261f79c6..7e9af77316a 100644
|
||||
--- a/include/windows.media.speechsynthesis.idl
|
||||
+++ b/include/windows.media.speechsynthesis.idl
|
||||
@@ -35,6 +35,18 @@ namespace Windows {
|
||||
@@ -29,11 +29,24 @@ namespace Windows {
|
||||
typedef enum VoiceGender VoiceGender;
|
||||
interface IInstalledVoicesStatic;
|
||||
interface IVoiceInformation;
|
||||
+ runtimeclass SpeechSynthesizer;
|
||||
runtimeclass VoiceInformation;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -39,7 +45,7 @@ index 89fe616b9b3..40c45c82051 100644
|
||||
namespace Windows {
|
||||
namespace Media {
|
||||
namespace SpeechSynthesis {
|
||||
@@ -59,6 +71,17 @@ namespace Windows {
|
||||
@@ -58,6 +71,17 @@ namespace Windows {
|
||||
[propget] HRESULT Gender([out] [retval] VoiceGender* value);
|
||||
}
|
||||
|
||||
@ -58,10 +64,10 @@ index 89fe616b9b3..40c45c82051 100644
|
||||
contract(Windows.Foundation.UniversalApiContract, 1.0),
|
||||
marshaling_behavior(agile)
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index 4de34a59d22..d607df5d1c9 100644
|
||||
index 344b6891747..e81c31aabb2 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -1492,7 +1492,8 @@ static void write_forward(FILE *header, type_t *iface)
|
||||
@@ -1479,7 +1479,8 @@ static void write_forward(FILE *header, type_t *iface)
|
||||
fprintf(header, "typedef interface %s %s;\n", iface->c_name, iface->c_name);
|
||||
fprintf(header, "#ifdef __cplusplus\n");
|
||||
write_namespace_start(header, iface->namespace);
|
||||
@ -71,7 +77,7 @@ index 4de34a59d22..d607df5d1c9 100644
|
||||
write_namespace_end(header, iface->namespace);
|
||||
fprintf(header, "#endif /* __cplusplus */\n");
|
||||
fprintf(header, "#endif\n\n" );
|
||||
@@ -1655,11 +1656,13 @@ static void write_com_interface_end(FILE *header, type_t *iface)
|
||||
@@ -1548,11 +1549,13 @@ static void write_com_interface_end(FILE *header, type_t *iface)
|
||||
write_namespace_start(header, iface->namespace);
|
||||
}
|
||||
if (uuid) {
|
||||
@ -87,7 +93,7 @@ index 4de34a59d22..d607df5d1c9 100644
|
||||
if (type_iface_get_inherit(iface))
|
||||
{
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 0b6b51b847e..44deb9fee5c 100644
|
||||
index e09722d7023..228e988530f 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -276,6 +276,7 @@ static const struct keyword keywords[] = {
|
||||
@ -99,7 +105,7 @@ index 0b6b51b847e..44deb9fee5c 100644
|
||||
{"dispinterface", tDISPINTERFACE, 0},
|
||||
{"double", tDOUBLE, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 14c9c5d007e..4d0390fd606 100644
|
||||
index 61bbe2a50ee..60268f1b7d4 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -84,6 +84,7 @@ static void push_lookup_namespace(const char *name);
|
||||
@ -192,7 +198,7 @@ index 14c9c5d007e..4d0390fd606 100644
|
||||
;
|
||||
|
||||
int_statements: { $$ = NULL; }
|
||||
@@ -3164,6 +3189,27 @@ static void check_async_uuid(type_t *iface)
|
||||
@@ -3166,6 +3191,27 @@ static void check_async_uuid(type_t *iface)
|
||||
iface->details.iface->async_iface = async_iface->details.iface->async_iface = async_iface;
|
||||
}
|
||||
|
||||
@ -220,7 +226,7 @@ index 14c9c5d007e..4d0390fd606 100644
|
||||
static void check_statements(const statement_list_t *stmts, int is_inside_library)
|
||||
{
|
||||
const statement_t *stmt;
|
||||
@@ -3345,6 +3391,15 @@ static statement_t *make_statement_typedef(declarator_list_t *decls, int declonl
|
||||
@@ -3347,6 +3393,15 @@ static statement_t *make_statement_typedef(declarator_list_t *decls, int declonl
|
||||
return stmt;
|
||||
}
|
||||
|
||||
@ -236,7 +242,7 @@ index 14c9c5d007e..4d0390fd606 100644
|
||||
static statement_list_t *append_statements(statement_list_t *l1, statement_list_t *l2)
|
||||
{
|
||||
if (!l2) return l1;
|
||||
@@ -3396,8 +3451,10 @@ type_t *find_parameterized_type(type_t *type, type_list_t *params, int t)
|
||||
@@ -3398,8 +3453,10 @@ type_t *find_parameterized_type(type_t *type, type_list_t *params, int t)
|
||||
assert(type->type_type == TYPE_PARAMETERIZED_TYPE);
|
||||
type = type_parameterized_type_specialize_partial(type, params);
|
||||
}
|
||||
@ -250,7 +256,7 @@ index 14c9c5d007e..4d0390fd606 100644
|
||||
free(name);
|
||||
return type;
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index e2d0a573c0d..a9a1ab390e8 100644
|
||||
index d2c472fcca0..a7c04a509e5 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -137,6 +137,41 @@ char *format_parameterized_type_name(type_t *type, type_list_t *params)
|
||||
@ -513,7 +519,7 @@ index e2d0a573c0d..a9a1ab390e8 100644
|
||||
{
|
||||
type_t *iface = make_type(TYPE_INTERFACE);
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index 472fdf2d5fc..e1a52d21d09 100644
|
||||
index c46a2629467..1e726d3a264 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -46,6 +46,8 @@ type_t *type_new_encapsulated_union(char *name, var_t *switch_field, var_t *unio
|
@ -1,4 +1,4 @@
|
||||
From 2226e8730b2a9a5170c34260448a16a2080ddf91 Mon Sep 17 00:00:00 2001
|
||||
From 4f91c256296729cd02b8ed85b5caf28ac7ff1e64 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Thu, 24 Sep 2020 00:00:54 +0200
|
||||
Subject: [PATCH] widl: Support WinRT delegate type.
|
||||
@ -28,10 +28,10 @@ index c83e9aa5ec0..88d59290d6b 100644
|
||||
break;
|
||||
case TYPE_ALIAS:
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index d607df5d1c9..37e96a8dcbe 100644
|
||||
index e81c31aabb2..e3a2aec08fe 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -483,6 +483,9 @@ void write_type_left(FILE *h, const decl_spec_t *ds, enum name_type name_type, i
|
||||
@@ -470,6 +470,9 @@ void write_type_left(FILE *h, const decl_spec_t *ds, enum name_type name_type, i
|
||||
case TYPE_RUNTIMECLASS:
|
||||
fprintf(h, "%s", type_get_name(type_runtimeclass_get_default_iface(t), name_type));
|
||||
break;
|
||||
@ -41,7 +41,7 @@ index d607df5d1c9..37e96a8dcbe 100644
|
||||
case TYPE_VOID:
|
||||
fprintf(h, "void");
|
||||
break;
|
||||
@@ -568,6 +571,7 @@ void write_type_right(FILE *h, type_t *t, int is_field)
|
||||
@@ -555,6 +558,7 @@ void write_type_right(FILE *h, type_t *t, int is_field)
|
||||
case TYPE_COCLASS:
|
||||
case TYPE_INTERFACE:
|
||||
case TYPE_RUNTIMECLASS:
|
||||
@ -49,7 +49,7 @@ index d607df5d1c9..37e96a8dcbe 100644
|
||||
break;
|
||||
case TYPE_APICONTRACT:
|
||||
case TYPE_PARAMETERIZED_TYPE:
|
||||
@@ -987,7 +991,7 @@ int has_out_arg_or_return(const var_t *func)
|
||||
@@ -974,7 +978,7 @@ int has_out_arg_or_return(const var_t *func)
|
||||
int is_object(const type_t *iface)
|
||||
{
|
||||
const attr_t *attr;
|
||||
@ -58,7 +58,7 @@ index d607df5d1c9..37e96a8dcbe 100644
|
||||
return 1;
|
||||
if (iface->attrs) LIST_FOR_EACH_ENTRY( attr, iface->attrs, const attr_t, entry )
|
||||
if (attr->type == ATTR_OBJECT || attr->type == ATTR_ODL) return 1;
|
||||
@@ -1904,9 +1908,10 @@ static void write_forward_decls(FILE *header, const statement_list_t *stmts)
|
||||
@@ -1795,9 +1799,10 @@ static void write_forward_decls(FILE *header, const statement_list_t *stmts)
|
||||
switch (stmt->type)
|
||||
{
|
||||
case STMT_TYPE:
|
||||
@ -70,7 +70,7 @@ index d607df5d1c9..37e96a8dcbe 100644
|
||||
if (is_object(iface) || is_attr(iface->attrs, ATTR_DISPINTERFACE))
|
||||
{
|
||||
write_forward(header, iface);
|
||||
@@ -1946,10 +1951,11 @@ static void write_header_stmts(FILE *header, const statement_list_t *stmts, cons
|
||||
@@ -1837,10 +1842,11 @@ static void write_header_stmts(FILE *header, const statement_list_t *stmts, cons
|
||||
switch (stmt->type)
|
||||
{
|
||||
case STMT_TYPE:
|
||||
@ -86,7 +86,7 @@ index d607df5d1c9..37e96a8dcbe 100644
|
||||
if (is_attr(stmt->u.type->attrs, ATTR_DISPINTERFACE) || is_object(stmt->u.type))
|
||||
{
|
||||
diff --git a/tools/widl/parser.l b/tools/widl/parser.l
|
||||
index 44deb9fee5c..6c1b0473ab4 100644
|
||||
index 228e988530f..c3d4b4ebd8e 100644
|
||||
--- a/tools/widl/parser.l
|
||||
+++ b/tools/widl/parser.l
|
||||
@@ -278,6 +278,7 @@ static const struct keyword keywords[] = {
|
||||
@ -98,7 +98,7 @@ index 44deb9fee5c..6c1b0473ab4 100644
|
||||
{"double", tDOUBLE, 0},
|
||||
{"enum", tENUM, 0},
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 4d0390fd606..569669dcfac 100644
|
||||
index 60268f1b7d4..3670da04715 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -120,6 +120,7 @@ static statement_t *make_statement_module(type_t *type);
|
||||
@ -167,7 +167,7 @@ index 4d0390fd606..569669dcfac 100644
|
||||
return FALSE;
|
||||
case TYPE_APICONTRACT:
|
||||
case TYPE_PARAMETERIZED_TYPE:
|
||||
@@ -3400,6 +3417,14 @@ static statement_t *make_statement_parameterized_type(type_t *type, type_list_t
|
||||
@@ -3402,6 +3419,14 @@ static statement_t *make_statement_parameterized_type(type_t *type, type_list_t
|
||||
return stmt;
|
||||
}
|
||||
|
||||
@ -231,7 +231,7 @@ index 6f6c5f3ccc8..8b2a2401367 100644
|
||||
|
||||
case TYPE_VOID:
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index a9a1ab390e8..89ebc0b5999 100644
|
||||
index a7c04a509e5..8c3ed223144 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -509,6 +509,14 @@ static unsigned int compute_method_indexes(type_t *iface)
|
||||
@ -286,7 +286,7 @@ index a9a1ab390e8..89ebc0b5999 100644
|
||||
{
|
||||
iface->details.iface = xmalloc(sizeof(*iface->details.iface));
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index e1a52d21d09..de3db4e7c7e 100644
|
||||
index 1e726d3a264..3b5db8f50f6 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -52,6 +52,7 @@ type_t *find_parameterized_type(type_t *type, type_list_t *params, int t);
|
||||
@ -297,7 +297,7 @@ index e1a52d21d09..de3db4e7c7e 100644
|
||||
void type_dispinterface_define(type_t *iface, var_list_t *props, var_list_t *methods);
|
||||
void type_dispinterface_define_from_iface(type_t *dispiface, type_t *iface);
|
||||
void type_module_define(type_t *module, statement_list_t *stmts);
|
||||
@@ -238,6 +239,7 @@ static inline int type_is_complete(const type_t *type)
|
||||
@@ -239,6 +240,7 @@ static inline int type_is_complete(const type_t *type)
|
||||
case TYPE_ARRAY:
|
||||
case TYPE_BITFIELD:
|
||||
case TYPE_RUNTIMECLASS:
|
||||
@ -320,10 +320,10 @@ index e1a52d21d09..de3db4e7c7e 100644
|
||||
{
|
||||
type = type_get_real_type(type);
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index ff71a1859ae..6feabafbefd 100644
|
||||
index be82342e31a..d55922b72e9 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -443,6 +443,11 @@ struct parameterized_details
|
||||
@@ -442,6 +442,11 @@ struct parameterized_details
|
||||
type_list_t *params;
|
||||
};
|
||||
|
||||
@ -335,7 +335,7 @@ index ff71a1859ae..6feabafbefd 100644
|
||||
#define HASHMAX 64
|
||||
|
||||
struct namespace {
|
||||
@@ -473,6 +478,7 @@ enum type_type
|
||||
@@ -472,6 +477,7 @@ enum type_type
|
||||
TYPE_RUNTIMECLASS,
|
||||
TYPE_PARAMETERIZED_TYPE,
|
||||
TYPE_PARAMETER,
|
||||
@ -343,7 +343,7 @@ index ff71a1859ae..6feabafbefd 100644
|
||||
};
|
||||
|
||||
struct _type_t {
|
||||
@@ -495,6 +501,7 @@ struct _type_t {
|
||||
@@ -494,6 +500,7 @@ struct _type_t {
|
||||
struct alias_details alias;
|
||||
struct runtimeclass_details runtimeclass;
|
||||
struct parameterized_details parameterized;
|
@ -1,4 +1,4 @@
|
||||
From 9784639ef93dc7e775d4b42d851179eee728f5d9 Mon Sep 17 00:00:00 2001
|
||||
From fb6ba3b61a5b4c1c0fc8ccb061d29680f247d17c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 1 Dec 2020 17:43:01 +0100
|
||||
Subject: [PATCH] widl: Support WinRT parameterized delegate type.
|
||||
@ -28,7 +28,7 @@ index 5f7a49c38e4..9583fa5bcc8 100644
|
||||
{
|
||||
[
|
||||
diff --git a/tools/widl/parser.y b/tools/widl/parser.y
|
||||
index 569669dcfac..6811f80a088 100644
|
||||
index 3670da04715..12be073c01a 100644
|
||||
--- a/tools/widl/parser.y
|
||||
+++ b/tools/widl/parser.y
|
||||
@@ -1084,6 +1084,17 @@ delegatedef:
|
||||
@ -50,7 +50,7 @@ index 569669dcfac..6811f80a088 100644
|
||||
|
||||
required_types:
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index 89ebc0b5999..e9eb2a4e75e 100644
|
||||
index 8c3ed223144..6a30891f656 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -142,16 +142,16 @@ static char const *parameterized_type_shorthands[][2] = {
|
||||
@ -169,7 +169,7 @@ index 89ebc0b5999..e9eb2a4e75e 100644
|
||||
|
||||
void type_dispinterface_define(type_t *iface, var_list_t *props, var_list_t *methods)
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index de3db4e7c7e..939bc5b412e 100644
|
||||
index 3b5db8f50f6..e354259ab18 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -53,6 +53,7 @@ void type_parameterized_interface_declare(type_t *type, type_list_t *params);
|
@ -1,4 +1,4 @@
|
||||
From 76f48d39dd43be3a66117b7cd49e70dea962d52b Mon Sep 17 00:00:00 2001
|
||||
From 466bf2736d778fdc23bdcb338c00fac0aa80c1b3 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Tue, 1 Dec 2020 17:44:43 +0100
|
||||
Subject: [PATCH] widl: Compute signatures for parameterized types.
|
||||
@ -10,7 +10,7 @@ Subject: [PATCH] widl: Compute signatures for parameterized types.
|
||||
3 files changed, 163 insertions(+)
|
||||
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index e9eb2a4e75e..c0a7b584b0c 100644
|
||||
index 6a30891f656..74ee92ed094 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -49,6 +49,7 @@ type_t *make_type(enum type_type type)
|
||||
@ -204,10 +204,10 @@ index e9eb2a4e75e..c0a7b584b0c 100644
|
||||
}
|
||||
compute_method_indexes(iface);
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index 939bc5b412e..b4257fe615f 100644
|
||||
index e354259ab18..4d705a060f3 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -80,6 +80,16 @@ static inline enum type_type type_get_type(const type_t *type)
|
||||
@@ -81,6 +81,16 @@ static inline enum type_type type_get_type(const type_t *type)
|
||||
return type_get_type_detect_alias(type_get_real_type(type));
|
||||
}
|
||||
|
||||
@ -225,10 +225,10 @@ index 939bc5b412e..b4257fe615f 100644
|
||||
{
|
||||
type = type_get_real_type(type);
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index 6feabafbefd..c784ae4ce52 100644
|
||||
index d55922b72e9..a1fce0ef87d 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -504,6 +504,7 @@ struct _type_t {
|
||||
@@ -503,6 +503,7 @@ struct _type_t {
|
||||
struct delegate_details delegate;
|
||||
} details;
|
||||
const char *c_name;
|
||||
@ -236,7 +236,7 @@ index 6feabafbefd..c784ae4ce52 100644
|
||||
unsigned int typestring_offset;
|
||||
unsigned int ptrdesc; /* used for complex structs */
|
||||
int typelib_idx;
|
||||
@@ -659,6 +660,7 @@ void init_loc_info(loc_info_t *);
|
||||
@@ -658,6 +659,7 @@ void init_loc_info(loc_info_t *);
|
||||
char *format_namespace(struct namespace *namespace, const char *prefix, const char *separator, const char *suffix,
|
||||
const char *abi_prefix);
|
||||
char *format_parameterized_type_name(type_t *type, type_list_t *params);
|
@ -1,4 +1,4 @@
|
||||
From df420c2d870d9ec0bccd91cedde12be6506620d7 Mon Sep 17 00:00:00 2001
|
||||
From 9d5f825326a9e00db5eacbc0beeafbcb4bea85ee Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Mon, 28 Sep 2020 17:00:41 +0200
|
||||
Subject: [PATCH] widl: Compute uuids for parameterized types.
|
||||
@ -222,7 +222,7 @@ index 3c2fd2914bf..208b193ac87 100644
|
||||
+
|
||||
#endif
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index c0a7b584b0c..176b34d1846 100644
|
||||
index 74ee92ed094..4002b9d62ae 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -29,6 +29,7 @@
|
||||
@ -300,10 +300,10 @@ index c0a7b584b0c..176b34d1846 100644
|
||||
return iface;
|
||||
}
|
||||
diff --git a/tools/widl/typetree.h b/tools/widl/typetree.h
|
||||
index b4257fe615f..46a223d50e3 100644
|
||||
index 4d705a060f3..eefd79f139d 100644
|
||||
--- a/tools/widl/typetree.h
|
||||
+++ b/tools/widl/typetree.h
|
||||
@@ -84,7 +84,7 @@ static inline const GUID *type_get_uuid(const type_t *type)
|
||||
@@ -85,7 +85,7 @@ static inline const GUID *type_get_uuid(const type_t *type)
|
||||
{
|
||||
static const GUID empty;
|
||||
attr_t *attr;
|
@ -1,4 +1,4 @@
|
||||
From 46d985e5575c2f1868d6c50d2e00400205f11b92 Mon Sep 17 00:00:00 2001
|
||||
From f41e0e81316bade72909f7abd6eb9943c44fff72 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Wed, 26 Aug 2020 22:46:02 +0200
|
||||
Subject: [PATCH] widl: Generate helper macros for WinRT implementation.
|
||||
@ -22,10 +22,10 @@ interface methods with the simple non-prefixed names instead.
|
||||
3 files changed, 90 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/tools/widl/header.c b/tools/widl/header.c
|
||||
index 37e96a8dcbe..3c4a9df9a83 100644
|
||||
index e3a2aec08fe..5130d82a774 100644
|
||||
--- a/tools/widl/header.c
|
||||
+++ b/tools/widl/header.c
|
||||
@@ -50,6 +50,8 @@ static void write_winrt_type_comments(FILE *header, const type_t *type);
|
||||
@@ -48,6 +48,8 @@ static void write_type_v(FILE *f, const decl_spec_t *t, int is_field, int declon
|
||||
static void write_apicontract_guard_start(FILE *header, const expr_t *expr);
|
||||
static void write_apicontract_guard_end(FILE *header, const expr_t *expr);
|
||||
|
||||
@ -34,7 +34,7 @@ index 37e96a8dcbe..3c4a9df9a83 100644
|
||||
static void indent(FILE *h, int delta)
|
||||
{
|
||||
int c;
|
||||
@@ -616,10 +618,11 @@ static void write_type_definition(FILE *f, type_t *t, int declonly)
|
||||
@@ -603,10 +605,11 @@ static void write_type_definition(FILE *f, type_t *t, int declonly)
|
||||
t->written = save_written;
|
||||
write_namespace_end(f, t->namespace);
|
||||
fprintf(f, "extern \"C\" {\n");
|
||||
@ -48,7 +48,7 @@ index 37e96a8dcbe..3c4a9df9a83 100644
|
||||
}
|
||||
if (contract) write_apicontract_guard_end(f, contract);
|
||||
}
|
||||
@@ -1643,6 +1646,70 @@ static void write_com_interface_start(FILE *header, const type_t *iface)
|
||||
@@ -1536,6 +1539,70 @@ static void write_com_interface_start(FILE *header, const type_t *iface)
|
||||
fprintf(header,"#define __%s_%sINTERFACE_DEFINED__\n\n", iface->c_name, dispinterface ? "DISP" : "");
|
||||
}
|
||||
|
||||
@ -119,7 +119,7 @@ index 37e96a8dcbe..3c4a9df9a83 100644
|
||||
static void write_com_interface_end(FILE *header, type_t *iface)
|
||||
{
|
||||
int dispinterface = is_attr(iface->attrs, ATTR_DISPINTERFACE);
|
||||
@@ -1715,6 +1782,7 @@ static void write_com_interface_end(FILE *header, type_t *iface)
|
||||
@@ -1608,6 +1675,7 @@ static void write_com_interface_end(FILE *header, type_t *iface)
|
||||
fprintf(header, "#else\n");
|
||||
write_inline_wrappers(header, type, type, iface->c_name);
|
||||
fprintf(header, "#endif\n");
|
||||
@ -128,7 +128,7 @@ index 37e96a8dcbe..3c4a9df9a83 100644
|
||||
fprintf(header, "\n");
|
||||
fprintf(header, "#endif\n");
|
||||
diff --git a/tools/widl/typetree.c b/tools/widl/typetree.c
|
||||
index 176b34d1846..439b1b54b8a 100644
|
||||
index 4002b9d62ae..cd2ce3c9348 100644
|
||||
--- a/tools/widl/typetree.c
|
||||
+++ b/tools/widl/typetree.c
|
||||
@@ -51,6 +51,7 @@ type_t *make_type(enum type_type type)
|
||||
@ -177,10 +177,10 @@ index 176b34d1846..439b1b54b8a 100644
|
||||
|
||||
return new_type;
|
||||
diff --git a/tools/widl/widltypes.h b/tools/widl/widltypes.h
|
||||
index c784ae4ce52..a5618646366 100644
|
||||
index a1fce0ef87d..21598a9213d 100644
|
||||
--- a/tools/widl/widltypes.h
|
||||
+++ b/tools/widl/widltypes.h
|
||||
@@ -505,6 +505,7 @@ struct _type_t {
|
||||
@@ -504,6 +504,7 @@ struct _type_t {
|
||||
} details;
|
||||
const char *c_name;
|
||||
const char *signature;
|
@ -1,4 +1,4 @@
|
||||
From 0f430cec7cce71db0ac00321de5e4f8f52e7adc5 Mon Sep 17 00:00:00 2001
|
||||
From 61216c5e78aaa94ada1580b5b95a9171b78cbb5f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?R=C3=A9mi=20Bernon?= <rbernon@codeweavers.com>
|
||||
Date: Fri, 25 Sep 2020 17:05:17 +0200
|
||||
Subject: [PATCH] include: Add IVectorView<HSTRING> declaration to
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user