What if I do something like
Foo foo;
gc_ptr<Foo> bar = &foo;
?
I'd expect it to be the same as
Foo* foo() {
Foo foo;
return &foo;
}
Don't expect a GC to save you from that one; you asked for stack duration
when you declared the Foo object.
--Jeffrey Bosboom