From 2ad3e6f7fc6d1d646d077f15487f04814b070d56 Mon Sep 17 00:00:00 2001 From: Andrey Shchekin Date: Sun, 24 Sep 2017 22:57:52 +1300 Subject: [PATCH] [gh-196] Improved JIT ASM static constructor error message. --- source/Server/Decompilation/JitAsmDecompiler.cs | 2 +- .../Tests/TestCode/JitAsm/StaticConstructor.Explicit.cs2asm | 4 ++-- .../Tests/TestCode/JitAsm/StaticConstructor.Implicit.cs2asm | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source/Server/Decompilation/JitAsmDecompiler.cs b/source/Server/Decompilation/JitAsmDecompiler.cs index f2977a4..f54e2d1 100644 --- a/source/Server/Decompilation/JitAsmDecompiler.cs +++ b/source/Server/Decompilation/JitAsmDecompiler.cs @@ -88,7 +88,7 @@ namespace SharpLab.Server.Decompilation { return; case Remote.MethodJitStatus.FailedTypeWithStaticConstructor: - writer.WriteLine(" ; Types with static constructors are not supported by SharpLab JIT ASM decompiler."); + writer.WriteLine(" ; Type {0} has a static constructor, which is not supported by SharpLab JIT decompiler.", method.Type.Name); return; } diff --git a/source/Tests/TestCode/JitAsm/StaticConstructor.Explicit.cs2asm b/source/Tests/TestCode/JitAsm/StaticConstructor.Explicit.cs2asm index feb7623..0ec0ee1 100644 --- a/source/Tests/TestCode/JitAsm/StaticConstructor.Explicit.cs2asm +++ b/source/Tests/TestCode/JitAsm/StaticConstructor.Explicit.cs2asm @@ -12,7 +12,7 @@ static class C { ; Desktop CLR v (clr.dll) on x86. C..cctor() - ; Types with static constructors are not supported by SharpLab JIT ASM decompiler. + ; Type C has a static constructor, which is not supported by SharpLab JIT decompiler. C.M() - ; Types with static constructors are not supported by SharpLab JIT ASM decompiler. \ No newline at end of file + ; Type C has a static constructor, which is not supported by SharpLab JIT decompiler. \ No newline at end of file diff --git a/source/Tests/TestCode/JitAsm/StaticConstructor.Implicit.cs2asm b/source/Tests/TestCode/JitAsm/StaticConstructor.Implicit.cs2asm index e46557c..d698d20 100644 --- a/source/Tests/TestCode/JitAsm/StaticConstructor.Implicit.cs2asm +++ b/source/Tests/TestCode/JitAsm/StaticConstructor.Implicit.cs2asm @@ -9,7 +9,7 @@ static class C { ; Desktop CLR v (clr.dll) on x86. C..cctor() - ; Types with static constructors are not supported by SharpLab JIT ASM decompiler. + ; Type C has a static constructor, which is not supported by SharpLab JIT decompiler. C.M() - ; Types with static constructors are not supported by SharpLab JIT ASM decompiler. \ No newline at end of file + ; Type C has a static constructor, which is not supported by SharpLab JIT decompiler. \ No newline at end of file