Siegfried Pammer
941906e8db
Fix #1699 : Auto properties without getter are not properly decompiled
...
Also fixes wrong decompilation of auto properties modified by Fody.
6 years ago
Daniel Grunwald
8f90f3834d
Implement support for C# 8 readonly members.
6 years ago
Siegfried Pammer
9190515d8b
#1151 : Support for ref readonly locals.
6 years ago
Daniel Grunwald
4b90e43187
Avoid making explicit ToString() implicit when doing so changes the semantics for mutable value types.
6 years ago
Daniel Grunwald
b5eecb8afc
Don't remove redundant ToString() calls in expression trees.
6 years ago
Daniel Grunwald
7a5d8af57d
#1691 : Further improvements for decompiling the new VS 2019.3 string concatenation IL pattern
6 years ago
Daniel Grunwald
bfa5ae8ac0
Fix #1691 : Remove ToString() calls inserted by C# compiler.
6 years ago
Daniel Grunwald
c32361d464
#1691 : Avoid replacing string.Concat() with operator+ when the evaluation order depends on the compiler version.
6 years ago
Siegfried Pammer
d2f7258347
Fix #1681 : Use discard assignment, if possible.
6 years ago
Siegfried Pammer
b6c7a25edf
Fix #1661 : Ignore casts on this/base ctor calls, if base type cannot be found.
6 years ago
Siegfried Pammer
8d2e8cc267
Fix #1628 : Preserve order of child nodes in PatternStatementTransform.VisitBinaryOperatorExpression.
6 years ago
Siegfried Pammer
13fa499c35
Fix #1630 : Do not convert while to for statement, if any iterator variables are to be declared in the loop body. This causes problems with ref-typed variables.
6 years ago
Siegfried Pammer
6ecd99f893
Fix #1618 : Unwrap in-arguments, when converting method calls to operators.
6 years ago
Siegfried Pammer
fa7c1f574a
Do not convert simple LINQ method calls to LINQ expressions. Closes #1501 .
6 years ago
Siegfried Pammer
3067aa5519
FlattenSwitchBlocks: include local function and out var declarations in the list of exceptions.
6 years ago
Siegfried Pammer
91af32ef94
Do not wrap local functions in checked blocks.
6 years ago
Siegfried Pammer
129fd876d4
Use extension method syntax only if the extension method is eligible.
6 years ago
Siegfried Pammer
9c1bf7fbdf
Introduce ReferenceKind in IParameter and ByReferenceResolveResult.
6 years ago
Daniel Grunwald
b75c252193
Upgrade C# 8.0 nullability support for Roslyn 3.2.0-beta4.
6 years ago
Daniel Grunwald
539e3a906d
Fix #1552 : user-defined and decimal increments
...
For user-defined increments, there were problems with Roslyn was optimizing out one of the stores.
The new transform FixRemainingIncrements now takes increments/decrements that were not detected by TransformAssignment and introduces a temporary variable that can be incremented.
This sometimes requires un-inlining via the new ILInstruction.Extract() operation.
Extract() is not supported in all possible contexts, so it is possible but unlikely that some op_Increment calls remain.
For decimals, the situation is different: legacy csc actually was optimizing "d + 1m" to "op_Increment(d)", so we can get rid of any left-over increments by undoing this optimization. This now happens in ReplaceMethodCallsWithOperators.
6 years ago
Daniel Grunwald
856cedc95e
#1456 : add test case; add additional checks to ensure we only transform normal locals into using/foreach-locals
6 years ago
Siegfried Pammer
537df7bab3
Add option: 'ref' extension methods
6 years ago
Siegfried Pammer
763ea38644
Clean up CallBuilder.HandleDelegateConstruction
6 years ago
Siegfried Pammer
89a50e64fc
Extension method syntax on lambda expressions/delegates is not allowed.
6 years ago
Siegfried Pammer
6338bd1b85
Partially revert CheckNoNamedOrOptionalArguments.
6 years ago
Siegfried Pammer
8d1522f387
Transform display classes used in local functions.
6 years ago
Siegfried Pammer
e99bc2b145
Fix #1567 : Do not transform string.Concat method calls to + operators if named arguments are used.
6 years ago
Siegfried Pammer
bd77b8301f
Basic implementation of local functions.
6 years ago
Siegfried Pammer
d0f42fb178
CombineQueryExpressions: Add missing transparent-identifier pattern.
6 years ago
Siegfried Pammer
c2b55869cd
#1501 : IntroduceQueryExpressions.MatchSimpleLambda: Remove hack from the early days of newdecompiler.
6 years ago
Siegfried Pammer
b0cb976357
Fix #1454 : Name collision after converting for-over-array to foreach.
6 years ago
Siegfried Pammer
d9b7df637b
Apply expression-body transform to indexers as well.
6 years ago
Siegfried Pammer
6f3230af48
Add ununsed CustomAttributes test.
...
Fix CalculatedGetterOnlyPropertyPattern for properties with attributes.
6 years ago
Daniel Grunwald
47ca51a769
Clarify the meaning of ILVariable.Index
6 years ago
Daniel Grunwald
ba8b453b36
Fix #1404 : local variables with init flag are not declared in the correct scope
6 years ago
Siegfried Pammer
ee151eb706
#1407 : Set CSharpInvocationResolveResult.IsExtensionMethodInvocation flag after extension methods transform.
6 years ago
Siegfried Pammer
1d2cd930de
Add LetIdentifierAnnotation to allow linking of let variables.
6 years ago
Siegfried Pammer
17f42066a0
Fix #1378 : Missing unsafe modifier for static fields
6 years ago
Siegfried Pammer
9487d0a714
Make pattern in TryRemoveTransparentIdentifier more flexible. Allow multiple let expressions per anonymous type declaration.
6 years ago
Siegfried Pammer
32cec2a1fb
Fix traversal bug in DecompileQueries: expressions with independent sub-expressions like conditional-expressions, binary operators or parameter lists were not handled correctly.
6 years ago
Siegfried Pammer
224b183e98
Fix IntroduceUnsafeModifier.VisitStackAllocExpression: size expression might contain pointer type or resolve result might be null.
7 years ago
Siegfried Pammer
0dac55d584
Add transformation for stackalloc to Span<T>.
7 years ago
Siegfried Pammer
b18653ba82
Fix #1319 : Property name collides with variable name
7 years ago
Siegfried Pammer
d469edbf2a
Fix initialization order of destructorBodyPattern and destructorPattern.
7 years ago
Siegfried Pammer
2bcafb8c4f
Fix #1247 : Empty destructors are not decompiled correctly
7 years ago
Siegfried Pammer
0fc5c8b988
Add support for FormattableString patterns.
7 years ago
Andrey Shchekin
d15fe0f254
Fixed bug with decimal optional parameters not being resolved correctly.
...
Added option to uglify presentation of decimal constants (show `[DecimalConstant(...)]`).
7 years ago
Siegfried Pammer
1104b29d26
Fix #1228 : SequencePointBuilder: Assertion failed: missing endLocation
7 years ago
Siegfried Pammer
71ffb0183b
Fix #1103 : Deactivating "Insert using declarations" now uses fully qualified types everywhere.
7 years ago
Daniel Grunwald
bafb6d1d49
Fix #1194 : empty if statements are decompiled into goto statements
7 years ago