ILSpy
ILSpy copied to clipboard
Unnecessary cast
FrmApendChargeInfo.InitializeComponent:
((System.Windows.Forms.Control)(object)this.panelEx1).SuspendLayout();
((System.ComponentModel.ISupportInitialize)this.tabControl1).BeginInit();
((System.Windows.Forms.Control)(object)this.tabControl1).SuspendLayout();
((System.Windows.Forms.Control)(object)this.superTabControlPanel1).SuspendLayout();
((System.ComponentModel.ISupportInitialize)this.picCardImage).BeginInit();
((System.Windows.Forms.Control)(object)this.superTabControlPanel4).SuspendLayout();
((System.ComponentModel.ISupportInitialize)this.picFaceImage).BeginInit();
((System.Windows.Forms.Control)(object)this.superTabControlPanel3).SuspendLayout();
((System.ComponentModel.ISupportInitialize)this.picBackImage).BeginInit();
((System.Windows.Forms.Control)(object)this.superTabControlPanel2).SuspendLayout();
((System.ComponentModel.ISupportInitialize)this.picFrontImage).BeginInit();
((System.Windows.Forms.Control)(object)this).SuspendLayout();
See FaceCapture.WndProc
also:
-
virtual
=>override
-
System.Runtime.CompilerServices.Unsafe.As
Do you have the necessary reference assemblies loaded? If they are not loaded, then the decompiler does not know that TabControl is derived from Control, so it has to use an explicit cast instead of an implicit conversion.
@dgrunwald @siegfriedpammer Yes, reference assembly is loaded, see test.zip
I think this issue is:
.exe is .NET 4, and DevComponents.DotNetBar2.dll
is .NET 2.0, when we use a control defined in DevComponents.DotNetBar2.dll
, ILSpy make mistakes
If you are decompiling a .NET 2.0 dll, you ideally need .NET 2.0 reference assemblies loaded. The target framework of the overall .exe does not matter in this case.
If you are decompiling a .NET 2.0 dll, you ideally need .NET 2.0 reference assemblies loaded. The target framework of the overall .exe does not matter in this case.
No, I'm not decompiling a .NET 2.0 dll, I'm decompiling a .NET 4.0 exe, and this exe references both 2.0 and 4.0 dlls