Skip to content

Commit 1429ea2

Browse files
committed
fix compiler error
1 parent a8420b8 commit 1429ea2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/emitter.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -689,7 +689,7 @@ export function emitWebIdl(webidl: Browser.WebIdl, flavor: Flavor) {
689689

690690
/// Emit the properties and methods of a given interface
691691
function emitMembers(prefix: string, emitScope: EmitScope, i: Browser.Interface) {
692-
const conflictedMembers = extendConflictsBaseTypes[i.name] ? extendConflictsBaseTypes[i.name].memberNames : new Set();
692+
const conflictedMembers = extendConflictsBaseTypes[i.name] ? extendConflictsBaseTypes[i.name].memberNames : new Set<string>();
693693
emitProperties(prefix, emitScope, i);
694694
const methodPrefix = prefix.startsWith("declare var") ? "declare function " : "";
695695
emitMethods(methodPrefix, emitScope, i, conflictedMembers);

src/widlprocess.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ function convertOperation(operation: webidl2.OperationMemberType, inheritedExpos
197197
throw new Error("Unexpected anonymous operation");
198198
}
199199
return {
200-
name: operation.name,
200+
name: operation.name || undefined,
201201
signature: [{
202202
...convertIdlType(operation.idlType),
203203
param: operation.arguments.map(convertArgument)

0 commit comments

Comments
 (0)