Comments (1)
Issue in method Class148.DefaultCheckCopyed
occurs because when TDCU executes it expects the first instruction of the init block of the display class to be the first assignment to the display class. This is not the case for this file for an unknown to me reason (i suspect its a result of obfuscation or deobfuscation though).
Displayclass init block:
Block IL_0020 (incoming: 1) {
if (comp.i4(callvirt get_CopyedOption(ldloc option) == ldc.i4 1)) leave IL_0020 (ldc.i8 0)
stloc has(ldc.i4 0)
// Diplay class init start
stobj System.Int64(delayex.ldflda iid(ldloca I_0), ldc.i8 0)
// display class init end
stobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0), nullable.rewrap(call Where(call Select(nullable.unwrap.o(await(call GetByOuterId(ldloc user, ldloc siteId, ldloc oid))), ILFunction <DefaultCheckCopyed>b__29_1[System.Func`2[[Class218],[System.String]]] {
param _class218_0 : Class218(Index=0, LoadCount=1, AddressCount=0, StoreCount=1)
BlockContainer {
Block IL_0000 (incoming: 1) {
leave IL_0000 (callvirt get_rst_link(ldloc _class218_0))
}
}
}
), ILFunction <DefaultCheckCopyed>b__29_2[System.Func`2[[System.String],[System.Boolean]]] {
param _string_1 : System.String(Index=0, LoadCount=1, AddressCount=0, StoreCount=1)
BlockContainer {
Block IL_0000 (incoming: 1) {
leave IL_0000 (comp.i4(call IsNullOrWhiteSpace(ldloc _string_1) == ldc.i4 0))
}
}
}
)))
if (if (comp.o(ldobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0)) == ldnull)) ldc.i4 1 else comp.i4(call Any(ldobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0))) == ldc.i4 0)) Block IL_01ba {
stobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0), await(call GetCopyHistory(ldloc user, ldloc siteId, ldloc oid)))
}
if (if (comp.o(ldobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0)) == ldnull)) ldc.i4 1 else comp.i4(call Any(ldobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0))) == ldc.i4 0)) leave IL_0020 (ldc.i8 0)
if (if (comp.i4(callvirt get_UpdateMode(ldloc option) == ldc.i4 0)) comp.i4(callvirt get_CopyedOption(ldloc option) == ldc.i4 0) else ldc.i4 0) Block IL_01ff {
call smethod_1(ldnull, ldloca I_0)
}
using (I_1 = callvirt GetEnumerator(call Take(ldobj System.Collections.Generic.IEnumerable`1[[System.String]](delayex.ldflda hist(ldloca I_0)), ldc.i4 5))) {
BlockContainer {
Block IL_0000 (incoming: 1) {
BlockContainer (while-true) {
Block IL_0289 (incoming: 2) {
if (comp.i4(callvirt MoveNext(ldloc I_1) == ldc.i4 0)) leave IL_0289 (nop)
if (if (call TryParse(callvirt get_Current(ldloc I_1), ldflda iid(ldloca I_0))) comp.i8.signed(ldobj System.Int64(delayex.ldflda iid(ldloca I_0)) > ldc.i8 0) else ldc.i4 0) Block IL_02be {
stloc has(await(callvirt ExistItem(call get_Class155_0(ldloc this), ldobj System.Int64(delayex.ldflda iid(ldloca I_0)))))
if (ldloc has) leave IL_0289 (nop)
}
br IL_0289
}
}
leave IL_0000 (nop)
}
}
}
if (comp.i4(ldloc has == ldc.i4 0)) Block IL_0332 {
if (comp.i4(callvirt get_CopyedOption(ldloc option) == ldc.i4 2)) Block IL_0334 {
leave IL_0020 (ldc.i8 0)
}
if (callvirt get_UpdateMode(ldloc option)) Block IL_0358 {
call smethod_1(ldstr "您已复制过此商品,但是已删除。若需要重新复制请修改选项", ldloca I_0)
}
}
if (callvirt get_UpdateMode(ldloc option)) leave IL_0020 (ldobj System.Int64(delayex.ldflda iid(ldloca I_0)))
call smethod_1(ldnull, ldloca I_0)
leave IL_0020 (ldobj System.Int64(delayex.ldflda iid(ldloca I_0)))
} at IL_0020
I will try and investigate how to better pattern much the display class initializers in such cases.
The second issue with the async decompiler is once again a fail to pattern match due to a rather strange await code pattern. I'm still looking into that.
from ilspy.
Related Issues (20)
- Choppy scrolling when scrolling fast after smooth scrolling introduction HOT 3
- `InvalidOperationException` thrown when reading debug metadata files HOT 3
- Settings panel shows strange hover/selection behavior
- Decompiler Settings: Checkbox in group header does not reflect state of the group
- Weird cast HOT 4
- Failed to decompile file .NETCoreApp v8 HOT 7
- Quicksearch box font cut below HOT 6
- It is not possible to use NRT attributes in the ILSpy project HOT 4
- FR: IL view on the GUI HOT 2
- FR: Symbols removal & renaming in the ILSpy GUI HOT 1
- Empty dotnet version folders lead to problems with resolving core assemblies in DotNetCorePathFinder HOT 1
- Assert at ICSharpCode.Decompiler.CSharp.Transforms.DeclareVariables.ResolveCollisions() HOT 4
- ILSpy crash
- Can't export project: System.UnauthorizedAccessException: Access to the path 'xxxx' is denied.
- Open class in new tab by default option HOT 2
- Make it target a specific compiler, and add a tool to compare the recompiled IL to the original IL HOT 6
- Export C# code containing IL that can be re-assembled with InlineIL.Fody (https://github.com/ltrzesniewski/InlineIL.Fody) HOT 4
- Missing variable declarations in repeated nested for-loops HOT 3
- Sorry, we crashed: System.ArgumentException: Unsupported table index: FieldPtr HOT 5
- ILSpy crashes when it parses deconstruction constructs
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ilspy.