示例#1
0
        public Disassembler()
        {
            OpCodes = typeof(Cpu)
                      .GetMethods()
                      .SelectMany(m => m.GetCustomAttributes(typeof(OpCodeDefinitionAttribute), true)
                                  .Select(a => a as OpCodeDefinitionAttribute))
                      .ToList();

            OpCodeCache = OpCodes.ToDictionary(x => x.Code, x => x);
        }