class Foo
{
     int x;
     int y;
     int z;

     mixin NonSerialized!(z);
}

Had a quick look at http://dsource.org/projects/orange/browser/orange/serialization/Serializable.d 1. How come it works without 'mixin' in the template declaration (mixin template NonSerialized)?
2. What if several fields need to be tagged?
3. Is there a reason to use a struct instead of e.g. __nonSerialized = ["field1", "field2", ...]?
4. Couldn't that field be static to save space or maybe even enum?

Reply via email to