struct P { child: Option> } trait PTrait { fn getChildOption(&self) -> Option>; } impl PTrait for P { fn getChildOption(&self) -> Option> { static childVal: Box

= self.child.get(); //~^ ERROR attempt to use a non-constant value in a constant panic!(); } } fn main() {}