diff --git a/sources/SilkTouch/Mods/AddOpaqueCOM.cs b/sources/SilkTouch/Mods/AddOpaqueCOM.cs index d45e93fbd6..0e5e555c7c 100644 --- a/sources/SilkTouch/Mods/AddOpaqueCOM.cs +++ b/sources/SilkTouch/Mods/AddOpaqueCOM.cs @@ -197,7 +197,7 @@ private string GetNewName(string comName) { if (node.Identifier.ToString() == "lpVtbl") { - return PrefixUnaryExpression(SyntaxKind.PointerIndirectionExpression, node); + return ParenthesizedExpression(PrefixUnaryExpression(SyntaxKind.PointerIndirectionExpression, node)); } return base.VisitIdentifierName(node); @@ -226,22 +226,6 @@ private string GetNewName(string comName) return ret; } - - - public override SyntaxNode? VisitClassDeclaration(ClassDeclarationSyntax node) => - VisitType(node, node.Identifier, base.VisitClassDeclaration); - - public override SyntaxNode? VisitRecordDeclaration(RecordDeclarationSyntax node) => - VisitType(node, node.Identifier, base.VisitRecordDeclaration); - - public override SyntaxNode? VisitEnumDeclaration(EnumDeclarationSyntax node) => - VisitType(node, node.Identifier, base.VisitEnumDeclaration); - - public override SyntaxNode? VisitDelegateDeclaration(DelegateDeclarationSyntax node) => - VisitType(node, node.Identifier, base.VisitDelegateDeclaration); - - public override SyntaxNode? VisitInterfaceDeclaration(InterfaceDeclarationSyntax node) => - VisitType(node, node.Identifier, base.VisitInterfaceDeclaration); public override SyntaxNode? VisitVariableDeclaration(VariableDeclarationSyntax node) { diff --git a/sources/Windows/DirectX/headers/d3dcommon/D3DBlob.gen.cs b/sources/Windows/DirectX/headers/d3dcommon/D3DBlob.gen.cs index 801485661c..f655893163 100644 --- a/sources/Windows/DirectX/headers/d3dcommon/D3DBlob.gen.cs +++ b/sources/Windows/DirectX/headers/d3dcommon/D3DBlob.gen.cs @@ -25,7 +25,7 @@ public unsafe partial struct D3DBlob : ID3DBlob.Interface, INativeGuid [VtblIndex(0)] public HRESULT QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject) { - return ((delegate* unmanaged)(*lpVtbl[0]))( + return ((delegate* unmanaged)((*lpVtbl)[0]))( this, riid, ppvObject @@ -39,7 +39,7 @@ public HRESULT QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** [return: NativeTypeName("ULONG")] public uint AddRef() { - return ((delegate* unmanaged)(*lpVtbl[1]))(this); + return ((delegate* unmanaged)((*lpVtbl)[1]))(this); } /// @@ -49,7 +49,7 @@ public uint AddRef() [return: NativeTypeName("ULONG")] public uint Release() { - return ((delegate* unmanaged)(*lpVtbl[2]))(this); + return ((delegate* unmanaged)((*lpVtbl)[2]))(this); } /// @@ -59,7 +59,7 @@ public uint Release() [return: NativeTypeName("LPVOID")] public void* GetBufferPointer() { - return ((delegate* unmanaged)(*lpVtbl[3]))(this); + return ((delegate* unmanaged)((*lpVtbl)[3]))(this); } /// @@ -69,7 +69,7 @@ public uint Release() [return: NativeTypeName("SIZE_T")] public nuint GetBufferSize() { - return ((delegate* unmanaged)(*lpVtbl[4]))(this); + return ((delegate* unmanaged)((*lpVtbl)[4]))(this); } public interface Interface : IUnknown.Interface diff --git a/sources/Windows/DirectX/headers/d3dcommon/D3DDestructionNotifier.gen.cs b/sources/Windows/DirectX/headers/d3dcommon/D3DDestructionNotifier.gen.cs index 41bc5bfe93..2eef485230 100644 --- a/sources/Windows/DirectX/headers/d3dcommon/D3DDestructionNotifier.gen.cs +++ b/sources/Windows/DirectX/headers/d3dcommon/D3DDestructionNotifier.gen.cs @@ -25,7 +25,7 @@ public unsafe partial struct D3DDestructionNotifier : ID3DDestructionNotifier.In [VtblIndex(0)] public HRESULT QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject) { - return ((delegate* unmanaged)(*lpVtbl[0]))( + return ((delegate* unmanaged)((*lpVtbl)[0]))( this, riid, ppvObject @@ -39,7 +39,7 @@ public HRESULT QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** [return: NativeTypeName("ULONG")] public uint AddRef() { - return ((delegate* unmanaged)(*lpVtbl[1]))(this); + return ((delegate* unmanaged)((*lpVtbl)[1]))(this); } /// @@ -49,7 +49,7 @@ public uint AddRef() [return: NativeTypeName("ULONG")] public uint Release() { - return ((delegate* unmanaged)(*lpVtbl[2]))(this); + return ((delegate* unmanaged)((*lpVtbl)[2]))(this); } /// @@ -68,7 +68,7 @@ public HRESULT RegisterDestructionCallback( delegate* unmanaged, void*, uint*, - int>)(*lpVtbl[3]) + int>)((*lpVtbl)[3]) )(this, callbackFn, pData, pCallbackID); } @@ -78,7 +78,7 @@ public HRESULT RegisterDestructionCallback( [VtblIndex(4)] public HRESULT UnregisterDestructionCallback(uint callbackID) { - return ((delegate* unmanaged)(*lpVtbl[4]))( + return ((delegate* unmanaged)((*lpVtbl)[4]))( this, callbackID ); diff --git a/sources/Windows/DirectX/headers/d3dcommon/ID3DInclude.gen.cs b/sources/Windows/DirectX/headers/d3dcommon/ID3DInclude.gen.cs index 11173a8bed..ddfc32a6c1 100644 --- a/sources/Windows/DirectX/headers/d3dcommon/ID3DInclude.gen.cs +++ b/sources/Windows/DirectX/headers/d3dcommon/ID3DInclude.gen.cs @@ -31,7 +31,7 @@ public HRESULT Open( void*, void**, uint*, - int>)(*lpVtbl[0]) + int>)((*lpVtbl)[0]) )( (ID3DInclude*)Unsafe.AsPointer(ref this), IncludeType, @@ -48,7 +48,7 @@ public HRESULT Open( [VtblIndex(1)] public HRESULT Close([NativeTypeName("LPCVOID")] void* pData) { - return ((delegate* unmanaged)(*lpVtbl[1]))( + return ((delegate* unmanaged)((*lpVtbl)[1]))( (ID3DInclude*)Unsafe.AsPointer(ref this), pData );