Is there a need for three? As b4p and CRunner are mutually exclusive you could use one slot named, say Host or B4P and do a GetType() on it to find out which and that also tells you if its optimised compiled or not!Three new values will be added:
In that case how using the same slot for b4p and cRunner. Then it will always be there and we won't get an exception (which is what I think happens) if we try to access the missing slot.However only two of the three will be really added in any case
Point taken!'optimized' flag could be useful even in cases where you don't need or have the knowledge of the more internal B4P or CRunner type.
I thought you were wrong but you're right as usualNo exception will be thrown.
try
{
fixX = (double)(Thread.GetData(Thread.GetNamedDataSlot("fixX")));
fixY = (double)(Thread.GetData(Thread.GetNamedDataSlot("fixY")));
}
catch
{
// allows versions of b4p earlier than 6.80 to use this library
}