Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/ikdasm.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZoltan Varga <vargaz@gmail.com>2018-11-27 12:34:01 +0300
committerMarek Safar <marek.safar@gmail.com>2018-11-27 12:50:55 +0300
commitd470f640e61b6e91eab4c3acdaf587c29280bffe (patch)
treeab5117ff70a600919de4cd2d2a43cc785c933ec4
parentb49272a4dc948be19df28afb2d4e3b9b9d708f30 (diff)
[ikdasm] Implementing dumping the Module table.
-rw-r--r--TableDumper.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/TableDumper.cs b/TableDumper.cs
index ba1ecc4..20ab90d 100644
--- a/TableDumper.cs
+++ b/TableDumper.cs
@@ -80,6 +80,9 @@ namespace Ildasm
case MetadataTableIndex.AssemblyRef:
DumpAssemblyRefTable (w);
break;
+ case MetadataTableIndex.Module:
+ DumpModuleTable (w);
+ break;
case MetadataTableIndex.ModuleRef:
DumpModuleRefTable (w);
break;
@@ -163,6 +166,16 @@ namespace Ildasm
}
}
+ void DumpModuleTable (TextWriter w) {
+ var t = module.ModuleTable;
+ w.WriteLine ("Module Table (1.." + t.RowCount + ")");
+ int rowIndex = 1;
+ foreach (var r in t.records) {
+ w.WriteLine (String.Format ("{0}: {1} {2} {{{3}}}", rowIndex, module.GetString (r.Name), r.Generation, module.GetGuid (r.Mvid).ToString ().ToUpper ()));
+ rowIndex ++;
+ }
+ }
+
void DumpModuleRefTable (TextWriter w) {
var t = module.ModuleRef;
w.WriteLine ("ModuleRef Table (1.." + t.RowCount + ")");