Siegfried Pammer
ac706d3735
dynamic: Add special case for type arguments in code generated by csc
7 years ago
Daniel Grunwald
02dde92bcb
Improve use of dynamic expressions in conditional context:
...
Let "operator true" be invoked implicitly where possible.
7 years ago
Siegfried Pammer
675125d6c6
Add support for DynamicInvokeInstruction and DynamicUnaryOperatorInstruction
7 years ago
Siegfried Pammer
ae018846d6
Implement some dynamic instructions in ExpressionBuilder
7 years ago
Siegfried Pammer
5e4b571a62
Add DynamicCallSiteTransform
7 years ago
Daniel Grunwald
92b72c9570
Type system: add support for tuple conversions.
7 years ago
Daniel Grunwald
469501210c
Add support for C# 7 tuple types:
...
* Use tuple literals instead of calling 'new ValueTuple<..>' constructor
* Where available, use element names for field access
* Make CallBuilder aware of tuple-name/dynamic type erasure, to avoid introducing casts when the types differ only in the tuple element names.
* Make CallBuilder provide a ResolveResult with the correct C# return type for the resulting expression.
Previously we were using the type-erased return type from the IL.
* Fix a bug that caused us to introduce returning casts when accessing an indexer.
7 years ago
Siegfried Pammer
c53b898b55
Fix #1122 : Error decompiling dictionary initializer referencing parameter variable
7 years ago
Daniel Grunwald
0552b335c9
Implement InferType() for ldelema.
...
This improves decompilation of compound assignment on array elements.
7 years ago
Siegfried Pammer
845c620a9f
Implement UserDefinedCompoundAssign
...
rename CompoundAssignmentInstruction -> NumericCompoundAssign
7 years ago
Chicken-Bones
dc58a1b40c
Include "base." qualifier as needed ( fixes #1123 )
...
Adds BaseReferenceExpression to ThisReferenceExpression target required checks
7 years ago
Daniel Grunwald
ec86ba2dad
Fix some bugs introduced by nested type lazy-loading.
7 years ago
Siegfried Pammer
75527071ab
Fix redundant qualifiers in method group expressions.
7 years ago
Siegfried Pammer
5dd7eaf129
Fix #1093 : Remove usage of type or this qualifiers, when possible.
7 years ago
Daniel Grunwald
b9337c6129
Fix #1021 : Compound assignments on pointer types.
7 years ago
Daniel Grunwald
7c91d48d68
#980 : Fix type substitution for lambdas.
7 years ago
Daniel Grunwald
f4b00e310c
Avoid redundant casts around 'as' conversions of type parameters.
7 years ago
Daniel Grunwald
4d00c65608
Use IReadOnlyList<T> instead of IList<T> in the resolved type system.
7 years ago
Siegfried Pammer
eac591a7d7
Fix #1084 : Decompiling constants of the target type
7 years ago
Siegfried Pammer
704eec86ae
Add basic unit tests for ref returns, locals and conditional
7 years ago
Daniel Grunwald
480ddc0c8f
#1055 : Use more type hints in ExpressionBuilder.
7 years ago
Daniel Grunwald
4177e182fe
#1050 : Add support for ?. operator applied to ref-parameters, and other cases where the compiler uses a generated ref local for the ?. operator.
...
Still not supported: ?. operator applied to a ref to unconstrained generic type.
7 years ago
Siegfried Pammer
3892762e70
Fix #1053 : virtual protected base method with 'out', invalid cast-to-base on use.
7 years ago
Daniel Grunwald
36035de5fa
Improve decompilation of ?. in generic code.
7 years ago
Daniel Grunwald
937b86be68
Fix type of ref-locals when there's ref-assignment involved.
7 years ago
Daniel Grunwald
ca0fa55af8
Implement null propagation transform.
8 years ago
Daniel Grunwald
97efc7b7f5
Fix some value type stack slots incorrectly being decompiled to a variable of type "object".
8 years ago
Daniel Grunwald
ae819526eb
Fix assertion when call has unknown target type (due to missing assembly reference).
8 years ago
Daniel Grunwald
87a03bde70
Add test case for #981 , and fix decompilation of ?: operator on StackType.Ref (necessary to make the testcase compile).
8 years ago
Siegfried Pammer
df04b40951
Fix #990 : Invalid object cast for virtual call through pointer
8 years ago
Siegfried Pammer
33c5e2d3ed
Add StackType.F4 and StackType.F8, and instructions LdcF4 and LdcF8.
8 years ago
Siegfried Pammer
25eecb90e1
Rename ExpressionTreeType to DelegateType and use ILFunction.DelegateType instead of the NewObj(LdNull, ILFunction) pattern in DelegateConstruction and ExpressionTrees
8 years ago
Siegfried Pammer
049cff2324
Add unit tests, directly use ILFunction instead of NewObj(ILFunction) for expression trees.
8 years ago
Siegfried Pammer
21dfa43dab
Add ExpressionTreeCast instruction
8 years ago
Siegfried Pammer
29a2d3ec34
Refactoring of ILFunction: allow Method and CecilMethod to be null for expression trees.
8 years ago
Siegfried Pammer
70e56c4b4d
Always use hex in flags enums and in bit-wise operations.
8 years ago
Daniel Grunwald
9a829a2820
ILReader: handle implicit O->Ref conversions
8 years ago
Daniel Grunwald
02db362838
Ensure that StLoc.Value.ResultType == StLoc.Variable.StackType
...
This introduce a new explicit conversion (StartGCTracking) when converting unmanaged pointers to managed references.
8 years ago
Daniel Grunwald
d45d65e1e4
Type analysis for ternary ?: don't use GetBestCommonType if it doesn't match the stack type
...
This was causing an assertion because 'b ? intPtr1 : 0' tried to convert to System.ValueType.
8 years ago
Siegfried Pammer
bacb293db8
Fix #971 : Anonymous method with missing parameter name
8 years ago
Daniel Grunwald
73420102a6
Fix reference comparisons on strings.
8 years ago
Daniel Grunwald
76c68e4ed4
Fix decompilation of "unsafePtr[1].Field = ...;"
8 years ago
Siegfried Pammer
349183544a
Rename BlockType to BlockKind
8 years ago
Daniel Grunwald
7f7e6564b3
Fix #948 : fix assertion when accessing fixed-size fields where StackType.Ref is expected.
8 years ago
Siegfried Pammer
fba6f3bdc4
Fix #932 : Hex numbers in bitwise (non-logical) statements
8 years ago
Daniel Grunwald
4c5f0b7e9c
Convert TransformAssignment into a statement transform and add support for inline property assignments.
8 years ago
Daniel Grunwald
40a4f08a8d
Add support for compound assignment of short integers.
8 years ago
Siegfried Pammer
2ca7ea87f1
Fix #955 : Ambiguous decompilation of anonymous delegates
8 years ago
Siegfried Pammer
23c7a8a46e
Fix #953 : Missing nullable specifier for array initializer
8 years ago
Siegfried Pammer
a7e3aeab47
Improve type inference for conditional operator;
...
closes #326 : Incorrect type inference for ternary operators
8 years ago