Daniel Grunwald
c4e181505c
Prepare for a split of StackType.O into StackType.Obj and StackType.VT: the easy cases
2 weeks ago
Daniel Grunwald
5670bfc132
Stack slots holding value types previously nevertheless often had type `object`
...
This was due to StackType.O doing double-duty as `object` and `other`.
While ExpressionBuilder would often improve the type of such locals, the `object` nevertheless ended up used in a couple of places, e.g. via the `typeHint`. This could result in value types being boxed even though the original IL didn't contain any `box` instruction.
This is an attempt to use better types for stack slot variables created by ILReader. The idea is: there aren't many IL instructions that produce "other" value types, and `InferType()` already handles pretty much all of them, so we can use that to assign types to our stack slots.
It's a bit more tricky if the stack is pushed to on multiple branches that join together before the value is used: here the variable type must be suitable for both assignments. In this case, we go back to the previously-used stacktype.
3 weeks ago
Peter Crabtree
e1e16b64f5
dev: Strip BOM mark from text files
1 year ago
Daniel Grunwald
ccb8887657
Move AllowByRefLike to SRMExtensions.
1 year ago
Jan Jones
2357d00939
Support `allows ref struct` constraint
1 year ago
Daniel Grunwald
3831b42197
Properly support `calli` instruction and its interaction with function pointer types.
6 years ago
dotnet format
0d9f871a4f
#2128 : Reformat the whole code base.
6 years ago
Daniel Grunwald
3a4db502bc
Add support for arithmetic using C# 9 native integer types.
6 years ago
Daniel Grunwald
c9e41d0582
Add support for decoding `NativeIntegerAttribute`.
6 years ago
Daniel Grunwald
a1c211f326
Fix #1794 : Avoid extra cast to double for ulong -> float conversion
7 years ago
Daniel Grunwald
b33d338558
Fix #1308 : Consider type hint in ldc.i8 translation.
8 years ago
Daniel Grunwald
ba0a3af3c4
#1195 : Fix several issues decompiling SharpSvn.dll (C++/CLI)
8 years ago
Daniel Grunwald
99f0841dd6
Fix TypeUtils for modopt types.
8 years ago
Daniel Grunwald
a2e9f7b3fe
#1174 : Fix IsCompatibleTypeForMemoryAccess() for tuple types.
8 years ago
Daniel Grunwald
85314b494a
#1085 : Keep track of whether an unresolved type is a class type or a value type.
...
Also, fix a bug that caused specialization of a method on an unresolved type to be a no-op.
9 years ago
Siegfried Pammer
7521cea4b9
Add unknown type handling to `ToPrimitiveType(this IType type)` and `IsCompatibleTypeForMemoryAccess(IType pointerType, IType accessStackType)`
9 years ago
Daniel Grunwald
9b15b97f89
Fix some more cases where missing references were causing assertions.
9 years ago
Siegfried Pammer
33c5e2d3ed
Add StackType.F4 and StackType.F8, and instructions LdcF4 and LdcF8.
9 years ago
Daniel Grunwald
c7e60a9b3c
Avoid using inline assignments if they truncate the input value.
9 years ago
Daniel Grunwald
f2b47b4bc1
Allow direct int->char casts without casting int->ushort->char.
9 years ago
Daniel Grunwald
19a7d8f7ff
Add support for pointer arithmetic (ptr + offset, offset + ptr, ptr - offset).
9 years ago
Daniel Grunwald
133ddac256
[nullables] Add support for lifted conversions.
9 years ago
Daniel Grunwald
21717f0fa4
Fixup array indices
9 years ago
Christoph Wille
1ce8349dd9
Adjust namespaces
10 years ago
Daniel Grunwald
935f0118d1
First attempt at better cast handling
10 years ago
Daniel Grunwald
8b6b6c10d0
Fix VisitNewArr with IntPtr arguments.
...
Various improvements to TypeUtils.
10 years ago
Siegfried Pammer
9aea030746
merge NRTypeExtensions and DecompilerTypeSystemUtils into TypeUtils
10 years ago
Siegfried Pammer
849f899926
transform stobj(ldloca(v), value) to stloc(v, value)
10 years ago
Siegfried Pammer
0969abd8c9
properly handle char[] access and bool ref/out access
10 years ago
Daniel Grunwald
d3de90389e
Fix comparisons between signed and unsigned integers.
...
Added Conv.Kind to clarify the semantics of an integer conversion.
10 years ago
Siegfried Pammer
c8f8d9ef4e
improve conversion of Ceq-ILAst instruction
11 years ago
Daniel Grunwald
5ead8e9230
Add SpecializingDecompilerTypeSystem
12 years ago
Daniel Grunwald
2c75fada90
Update to NRefactory 5.4
12 years ago