Siegfried Pammer
0879e35c08
Show the hexadecimal form of negative ldc.i4/ldc.i8 operands
...
A negative constant operand is usually the two's-complement rendering
of a bit mask or a high unsigned value (an enum member, a sentinel);
the IL view now appends the hexadecimal form as a comment, e.g.
'ldc.i4 -501 // 0xfffffe0b' (#1142 ). The short forms stay bare: their
operand range is readable as-is. The disassembler round-trip comparer
strips comments, so the new NegativeConstants case pins the rendering
with explicit content asserts.
Assisted-by: Claude:claude-fable-5:Claude Code
1 month ago
Christoph Wille
fed643eba0
Render shortcut-form IL opcodes from fixed lookup tables
...
WriteOpCode allocated two strings per rendered ldarg.N/ldloc.N/stloc.N
instruction (the digit cut off the mnemonic plus the concatenated
local-reference key), even though the shortcut forms only ever produce
the indices 0-3. The digit text and the param_/loc_ reference keys now
come from static tables indexed by opcode arithmetic.
Assisted-by: Claude:claude-fable-5:Claude Code
1 month ago
Peter Crabtree
e1e16b64f5
dev: Strip BOM mark from text files
1 year ago
Daniel Grunwald
fa19470435
Fix #3218 : Avoid exceptions when IL is invalid due to unexpected end-of-method-body.
2 years ago
Siegfried Pammer
ca78d4a14d
Use MetadataFile instead of PEFile in TypeSystem.
3 years ago
Siegfried Pammer
7414aaeeeb
Fix #3061 : Handler blocks of exception filter blocks do not have a header.
3 years ago
Siegfried Pammer
af56bb10d0
Determine isBranchTarget in a separate pass. We will need it for an optimization to ILReader in a future commit.
4 years ago
Siegfried Pammer
93dcba3426
* Rename Metadata.GenericContext to MetadataGenericContext to avoid conflicts with TypeSystem.GenericContext
...
* Change MetadataGenericContext to readonly struct
* Rearrange types in Dom.cs
4 years ago
Siegfried Pammer
900d0a4b93
Fix #1966 : Add option to show raw offsets and instruction bytes in IL view.
5 years ago
Siegfried Pammer
48adb52489
Show header size in IL output.
5 years ago
dotnet format
0d9f871a4f
#2128 : Reformat the whole code base.
6 years ago
Siegfried Pammer
853cad5fd0
Disassembler: Implement cancellation token.
7 years ago
Siegfried Pammer
deaedd0914
Link metadata tokens in decompilation output to metadata tables.
7 years ago
Siegfried Pammer
270547cb46
Fix release build.
7 years ago
Siegfried Pammer
2a5ba0f665
Fix linking of local variables and parameters to their usages in the IL view.
8 years ago
Siegfried Pammer
fbfcd6f72a
Fix #628 : Add option to display metadata token in 10-based or hex format.
8 years ago
Daniel Grunwald
61698b615d
Fix #1232 : BadImageFormatException: Invalid SEH header
...
This makes the decompiler and a bunch of analyzers more robust against invalid assemblies.
8 years ago
Siegfried Pammer
697074f88b
MethodBodyDisassembler: print variable names found in PDB.
8 years ago
Daniel Grunwald
08e8091336
Fix #1211 : Handle BadImageFormatException on invalid local signatures.
8 years ago
Siegfried Pammer
716eade5a6
Add missing "method" keyword to method definition tokens in ldtoken instruction.
8 years ago
Siegfried Pammer
68123fc6b3
Fix build.
8 years ago
Siegfried Pammer
4540b93e19
Use ArgumentOutOfRangeException or BadImageFormatException in switch-default sections.
8 years ago
Siegfried Pammer
4f8441e142
Introduce several new WriteReference overloads
8 years ago
Siegfried Pammer
bcfb3742eb
Clean up PEFile, move Pdb related types to DebugInfo namespace
8 years ago
Siegfried Pammer
d8c1796c4a
Add MetadataTokenHelpers to avoid crashing when dealing with MetadataTokens
8 years ago
Daniel Grunwald
6360b70ee6
#1189 : Fix exception trying to disassemble a bunch of random bytes.
8 years ago
Siegfried Pammer
bd2a0ec8d7
Fix output of .emitbyte directive on multi-byte opcode values.
8 years ago
Daniel Grunwald
4e449de58d
Show metadata tokens in disassembly.
8 years ago
Siegfried Pammer
458f448fae
Avoid unnecessary allocations of MetadataReader and clean up Dom structs a bit.
8 years ago
Siegfried Pammer
ce894c4ad4
Add IDebugInfoProvider implementations to ILSpy
9 years ago
Siegfried Pammer
b500b24548
SRM WIP basic implementation of DecompilerTypeSystem
9 years ago
Siegfried Pammer
37ae59c70d
Add guard code in case standalone signature is invalid.
9 years ago
Siegfried Pammer
82d80a80e9
Fix formatting bug in MethodBodyDisassembler
9 years ago
Siegfried Pammer
87ced033ba
Rename Dom -> Metadata; Remove bogus abstraction
9 years ago
Siegfried Pammer
cb9787098f
Finished port of UI (Analyzers still excluded) and Disassembler
9 years ago
Siegfried Pammer
02b7dc98be
Commit of non-compiling WIP
9 years ago
Daniel Grunwald
462d0da7b6
Add feature to the MethodBodyDisassembler that shows sequence points from PDB in disassembled IL.
9 years ago
Daniel Grunwald
3aca47d1f5
Allow decompiling whole assembly in IL + C# mode.
9 years ago
Siegfried Pammer
d871960bec
Add WriteInstruction to MethodBodyDisassembler
9 years ago
Daniel Grunwald
b3590ec292
Update cecil.
10 years ago
Siegfried Pammer
840ec04fde
Namespace adjustments for Syntax classes
10 years ago
Daniel Grunwald
7273fe58fd
Add BlockTransform concept and apply a bunch of refactoring essentials suggestions.
10 years ago
Daniel Grunwald
fe3bee36ad
Use tabs, not spaces.
11 years ago
Daniel Grunwald
02a500e762
ICSharpCode.Decompiler: Merge changes from SharpDevelop to ILSpy.
12 years ago
Daniel Grunwald
817b0baded
expr inlining
12 years ago
Daniel Grunwald
167e140c75
'Typed IL' view shows stack
12 years ago
Daniel Grunwald
27252656cf
Upgrade to new ICSharpCode.Decompiler (work in progress)
...
- Switch AvalonEdit to NuGet package.
- Upgrade Mono.Cecil to new version
12 years ago
Lukas Rieger
2d2a0aaea1
Modules may exist without an Assembly,in this case the line
...
"method.DeclaringType.Module.Assembly.EntryPoint"
causes a NullReferenceException as Assembly == null.
This change first checks if Module.Assembly != null.
13 years ago
Daniel Grunwald
56c75e09b2
Refactored handling of debug mapping in the decompiler: we now avoid using a side-channel for the debug info and instead return it via the ITextOutput.
15 years ago
Eusebiu Marcu
b394749f47
create a new TextOutputLocation class for storing the location in the output text instead of Tuple<int, int>
15 years ago