Hey Stanislav,

That's just an optimization. It makes OpCode a 8 bytes long struct.

We used to store it as string[] array but having a byte[] cuts the
cost in half as a char is 2 bytes and all opcodes names are
representable with ascii.

Jb


On Tue, Sep 3, 2013 at 4:06 PM, Stanislav <[email protected]> wrote:
> looking forward your answer I can try to explain myself. May be this done to
> avoid strings loading from metadata? Just to skip one step on OpCodes type
> initialisation.
>
> вторник, 3 сентября 2013 г., 17:43:36 UTC+4 пользователь Stanislav написал:
>>
>> Hello JB!
>>
>> I have found interesting solution in sources. Instead of JetBrains dotPeek
>> core, where IL names just stored in Opcode class field and initialised at
>> startup from constructor you did strange things: you stored all names as
>> chars codes values array and decode them into strings into static array
>> without storing them in each Opcode as field. So, could you explain me, why?
>>
>>  - Stanislav
>
> --
> --
> --
> mono-cecil
> ---
> You received this message because you are subscribed to the Google Groups
> "mono-cecil" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/groups/opt_out.

-- 
-- 
--
mono-cecil
--- 
You received this message because you are subscribed to the Google Groups 
"mono-cecil" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to