Skip to content

Commit 26fd45b

Browse files
authored
Merge pull request #48 from jonwis/main
Add support for uuid and interfaces deriving from each other
2 parents b1d16d4 + 0dd681a commit 26fd45b

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

server/src/midl.pegjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ attributeKW = "attributeKW" { return emit('keyword'); }
116116
attributeName "attribute name" = identifier { return emit('attribute')}
117117

118118
/* INTERFACE DECL */
119-
ifaceDecl = _ "interface" _ interfaceName _ ((requires? _ openBrace _ ifaceMember* _ closeBrace) / ";")
119+
ifaceDecl = _ "interface" _ interfaceName _ ((extends? _ requires? _ openBrace _ ifaceMember* _ closeBrace) / ";")
120120
interfaceName = identifier { return emit('interface'); }
121121

122122
/* METHOD DECL */

server/src/server.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,8 @@ connection.onCompletion(
518518
'contract',
519519
'static_name',
520520
'attributeusage',
521+
'contractversion',
522+
'uuid',
521523
//
522524
'target_runtimeclass',
523525
'target_interface',

server/src/test/assets/interfaces.idl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@ namespace DemoNamespace
1010
{
1111
void DoSomething();
1212
}
13+
14+
[
15+
uuid("12345678-1234-1234-1234-123456789012"),
16+
contract(MyContract, 1.0)
17+
]
18+
interface IMyInterface : Windows.Foundation.IInspectable
19+
{
20+
void Foo();
21+
};
1322

1423
runtimeclass DemoClass : [PREVIEW_API] /* comment */ IDemoInterface
1524
{

0 commit comments

Comments
 (0)