Siegfried Pammer
b6259b7dca
Fix #1981 : Ensure correctness of TDCU
5 years ago
Siegfried Pammer
0d1b6203df
#1981 : Refactor LocalFunctionDecompiler: Propagate closure parameter arguments, so that all arguments can be stripped from use-sites.
5 years ago
Siegfried Pammer
6382f8c41d
Fix #1990 : Empty default ctor with XML comment discarded from decompilation
5 years ago
Daniel Grunwald
b7754cdf5c
Workaround dotnet/roslyn#43659 in decompiled code.
5 years ago
Daniel Grunwald
cd04e80f5e
Use IsKnownType() when checking for System.Object
5 years ago
Siegfried Pammer
40687ea8ad
#1498 : Remove Fusion API usage: Use standard file enumeration instead. This should enable us to use the GAC even with restricted access, as only the LIST permission is required.
5 years ago
Siegfried Pammer
7571b59abf
Improve DotNetCorePathFinderExtensions.DetectTargetFrameworkId to properly detect framework version of GAC assemblies.
5 years ago
Daniel Grunwald
9659be0d55
#1946 : Fix IsBranchToReturnBlock() [was broken in c1265ad830
]
5 years ago
Siegfried Pammer
0dfcafdfe8
Add preconfigured assembly list selection and rename command to ManageAssemblyListsDialog
5 years ago
Siegfried Pammer
60e9c204cc
Fix #1940 : Make sure that we use the correct .NET Core version, when there are multiple frameworks loaded in the current assembly list.
5 years ago
Siegfried Pammer
b92a4b956c
#1940 : Ignore nullability in ETs
5 years ago
Siegfried Pammer
c676665a61
#1940 : Refactor TransformExpressionTrees to support rolling back all changes if the transform fails.
5 years ago
Daniel Grunwald
c1265ad830
Fix #1946 : Don't move `return` into `try` block when doing so changes the semantics of a `finally` block.
5 years ago
Daniel Grunwald
2da513eb24
Fix #1988 : handle Roslyn 3.6 task creation pattern in async/await decompiler.
...
Roslyn 3.6 no longer makes a redundant copy of the `AsyncTaskMethodBuilder`, but directly calls `stateMachine.<>t__builder.Start(ref stateMachine);`
5 years ago
Daniel Grunwald
5ad7ee0cea
Fix #1629 : Add support for `[module: NullablePublicOnly]`
...
If this attribute is in use, private/internal members lack nullability annotations.
Previously in such cases, we ended up inheriting the nullability from the `[NullableContext]`, which could cause us to display a misleading nullability for primary methods.
In debug builds, it could also trigger an assertion when trying to apply the "nullable reference type" marking to to value types.
Of note is that properties and events are a special case: they do not explicitly store Accessibility in metadata. For properties computing the accessibility requires decoding the signature (to find overridden base properties). So these two only check the declaring type's accessibility instead; private properties may still carry nullability despite `[NullablePublicOnly]`. However, the property accessors won't store nullability, so we need to read the `returnTypeAttributes` from the property itself.
5 years ago
Siegfried Pammer
8925b4ff7b
Inline variable declarations/modernize parts of our code base.
5 years ago
Siegfried Pammer
e2df79ef70
Fix #1975 : readonly modifier is added to structs even if language version is lower than C# 7.0
5 years ago
Siegfried Pammer
91e9573449
Fix #1976 : ProxyCallReplacer should honor selected language version/selected options
5 years ago
Siegfried Pammer
d09190533a
Fix #1980 : IndexOutOfRangeException when choose `IL with C#` with System.Runtime.CompilerServices.Unsafe.Copy/InitBlock
5 years ago
Siegfried Pammer
10e3da3d16
Add missing license headers to MIT licensed files in ICSharpCode.Decompiler
5 years ago
Siegfried Pammer
853cad5fd0
Disassembler: Implement cancellation token.
5 years ago
Jackson Davis
6ab1f98fa3
Expand the range of sequence points out the closest empty ilstack
...
or implicit sequence point without creating overlapping sequence points.
If such a location cannot be found do, nothing. Fill in the
gaps with hidden sequence points.
Also emit a sequence point for
the prolog to account for seqeunce point there emitted by the C#
compiler. Without this, the debugger can stop there on a step in
using the original pdb, then decompile resulting in a no-code at this
location failure.
5 years ago
Daniel Grunwald
65fe59e393
#1918 : Fix a bunch of issues with pinned region detection.
...
Not every pinned region has a clean `P = null` assignment to mark its end.
If a second pinned region starts with the same variable `P`, consider that to mark the end of the previous pinned region for that variable.
Also, fix a bunch of special cases with empty pinned regions.
5 years ago
Siegfried Pammer
69ac54fbb6
Fix #1879 : Do not remove variables that look like display class variables, but are used in other patterns as well.
5 years ago
Daniel Grunwald
ff40fbd984
Fix #1958 : Emit ProjectTypeGuids when generating .csproj
...
For portable class libraries, the type GUID is required so that Visual Studio for Mac can open the project.
5 years ago
Daniel Grunwald
fb5ab19bfd
SolutionCreator: Store project type GUID in .sln
5 years ago
Daniel Grunwald
0cf50aa827
Fix #1959 : Resolve the "F(G<A,B>(7));" grammar ambiguity by inserting parentheses when necessary.
5 years ago
Siegfried Pammer
5ee172d4c4
Fix #1900 : RemoveDeadVariableInit.ResetHasInitialValueFlag should handle local functions
5 years ago
Siegfried Pammer
371d732c0a
Fix #1881 : Not properly reusing names from PDB#2
5 years ago
Siegfried Pammer
e748e71b56
Implement workaround for #1961
5 years ago
Siegfried Pammer
7c7328df32
Fix #1955 : struct 'base' access to ValueType mis-decompiles
5 years ago
Siegfried Pammer
7d1d7b2563
Fix EndLocation of double-typed PrimitiveExpression
5 years ago
Siegfried Pammer
c2a2cf43f2
Fix #1482 : SequencePointBuilder fails with an assertion when trying to create sequence points for LINQ expressions
5 years ago
Christoph Wille
ed7af2addb
Windows: keep using Windows PowerShell, other OSs fall back on pwsh (to reduce deps to get up and running on Windows)
5 years ago
Siegfried Pammer
95beaddc80
IntroduceQueryExpressions: Inline variable declarations and use pattern matching syntax where possible.
5 years ago
Siegfried Pammer
69cad7527e
Fix #1945 , fix #1851 : NRE when generating sequence points for a method containing a stackalloc expression.
5 years ago
Siegfried Pammer
413c5b3baf
PortablePdbWriter: Add primitive support for state-machine hoisted local scopes. All variables are visible in the whole MoveNext method.
5 years ago
Siegfried Pammer
54a742f3f5
Metadata Explorer: Display blob contents of custom debug information in tooltip.
5 years ago
Siegfried Pammer
3f108cea37
#1482 : Fix sequence points of LINQ select and where.
5 years ago
Daniel Grunwald
3bf9f7c301
Fix #1943 : "ref readonly" returns from properties/indexers
5 years ago
Siegfried Pammer
22799ca6b1
#1942 : Make sure to group all types by filename in the generated PDB.
5 years ago
Siegfried Pammer
70b087bf8d
#1942 : WholeProjectDecompiler: Do not use filenames that collide with names of special devices. Note: this changes the PDB structure from multi-level folders per namespace to "dotted name" folders.
5 years ago
Christoph Wille
55a6f9184f
Use PowerShell Core for running update-assemblyinfo.ps1
5 years ago
Siegfried Pammer
bef75321fb
#1913 : Do not destroy control-flow by removing return statements
5 years ago
Siegfried Pammer
df84ab8f6b
Fix #1882 : Provide a setting to desugar X? into Nullable<X> for value types
5 years ago
Siegfried Pammer
73e0f7c3ac
Fix #1936 : TransformDisplayClassUsage should remove copies of display-class references.
5 years ago
Siegfried Pammer
67b7ad362a
Started documenting SequencePointBuilder
5 years ago
Siegfried Pammer
e4fda5c2e4
Rename HasILRange to ILRangeIsEmpty to properly reflect its implementation.
5 years ago
Siegfried Pammer
5d622056a1
Add TranslatedStatement: require that C# statements must be annotated with their corresponding ILInstructions.
5 years ago
Siegfried Pammer
e2b10adc72
Fix #1927 : NRE in ExpressionBuilder when trying to decompile catch-when blocks consisting of multiple statements.
5 years ago