public BinaryModule(BinaryModuleLayout moduleLayout) { codeSection = new Section(Array.Find(moduleLayout.sections, sec => sec.kind == SectionKind.Custom), moduleLayout); int bankIndex = Array.IndexOf(moduleLayout.strings, new StringLayout() { str = "__entry" }); var symbolLayout = Array.Find(moduleLayout.symbols, sym => sym.nameIndex == bankIndex); entryPoint = symbolLayout.blobEntryIndex; }
public BinaryModule(BinaryModuleLayout moduleLayout) { CodeSection = new Section(Array.Find(moduleLayout.sections, sec => sec.kind == SectionKind.Code), moduleLayout); DataSection = new Section(Array.Find(moduleLayout.sections, sec => sec.kind == SectionKind.Data), moduleLayout); }