Teach task_owned and dom_owned to find their dom via consistent interface.

This commit is contained in:
Michael Bebenita 2010-07-28 00:40:45 -07:00 committed by Graydon Hoare
parent 9fe4b0d404
commit e327aa5093

@ -95,6 +95,9 @@ template <typename T>
struct
dom_owned
{
rust_dom *get_dom() const {
return ((T*)this)->dom;
}
void operator delete(void *ptr) {
((T *)ptr)->dom->free(ptr);
}
@ -104,6 +107,9 @@ template <typename T>
struct
task_owned
{
rust_dom *get_dom() const {
return ((T *)this)->task->dom;
}
void operator delete(void *ptr) {
((T *)ptr)->task->dom->free(ptr);
}