1 import rx.subject : SubjectObject; 2 3 auto sub = new SubjectObject!int; 4 5 bool result = false; 6 sub.any().doSubscribe((bool) { result = true; }); 7 8 assert(result == false); 9 sub.put(1); 10 assert(result == true);