comparison orange/serialization/Events.d @ 44:1fef41162966

Fixed deserialization of whcar for D2. Fixed events for D2.
author Jacob Carlborg <doob@me.com>
date Tue, 09 Aug 2011 10:11:14 +0200
parents 8b9409423740
children
comparison
equal deleted inserted replaced
43:6f35fb47ca24 44:1fef41162966
28 orange.serialization.Events.Event!(method) __onSerializing; 28 orange.serialization.Events.Event!(method) __onSerializing;
29 } 29 }
30 30
31 struct Event (alias m) 31 struct Event (alias m)
32 { 32 {
33 private const method = &m; 33 version (Tango)
34 private const method = &m;
35
36 else
37 mixin("private enum method = &m;");
34 38
35 void opCall (T) (T value) 39 void opCall (T) (T value)
36 { 40 {
37 void delegate () dg; 41 void delegate () dg;
38 dg.ptr = cast(void*) value; 42 dg.ptr = cast(void*) value;