After some attempts I've found the solution. I've replaced 'const' by 'static' and it finally works:
Class constants definition:
public class A {
public static short A_CONST = 1;
public class B {
public static short AB_CONST = 1;
}
}
Register types explicitly:
TypeRegistry.RegisterType(typeof(A));
TypeRegistry.RegisterType(typeof(A.B));
Access to constants dynamically through ExpressionEvaluator:
object result = ExpressionEvaluator.GetValue(null, "A.A_CONST");
Assert.AreEqual(A.A_CONST, result);
result = ExpressionEvaluator.GetValue(null, "A.B.AB_CONST");
Assert.AreEqual(A.B.AB_CONST, result);