search for: factoryu

Displaying 4 results from an estimated 4 matches for "factoryu".

Did you mean: factory
2013 Nov 21
3
[LLVMdev] ErrorOr<> conflicts with unique_ptr<>
...piler errors that require breaking up expressions to work around. Do you have suggestions on how to code the following simple examples to not error? Can some of these be fixed in ErrorOr.h? Or am I totally not getting something? -Nick struct Foo { void doit(); }; std::unique_ptr<Foo> factoryU() { std::unique_ptr<Foo> f(new Foo); return f; // works as expected } ErrorOr<Foo*> factoryE() { ErrorOr<Foo*> f = new Foo; return f; // works as expected } ErrorOr<std::unique_ptr<Foo>> factoryEU() { std::unique_ptr<Foo> f(new Foo); return f; //...
2013 Nov 22
0
[LLVMdev] ErrorOr<> conflicts with unique_ptr<>
...to work > around. Do you have suggestions on how to code the following simple > examples to not error? Can some of these be fixed in ErrorOr.h? Or am I > totally not getting something? > > -Nick > > > struct Foo { void doit(); }; > > > std::unique_ptr<Foo> factoryU() { > std::unique_ptr<Foo> f(new Foo); > return f; // works as expected > } > > ErrorOr<Foo*> factoryE() { > ErrorOr<Foo*> f = new Foo; > return f; // works as expected > } > > ErrorOr<std::unique_ptr<Foo>> factoryEU() { > s...
2013 Nov 22
3
[LLVMdev] ErrorOr<> conflicts with unique_ptr<>
...pressions to work around. Do you have suggestions on how to code the following simple examples to not error? Can some of these be fixed in ErrorOr.h? Or am I totally not getting something? > > -Nick > > > struct Foo { void doit(); }; > > > std::unique_ptr<Foo> factoryU() { > std::unique_ptr<Foo> f(new Foo); > return f; // works as expected > } > > ErrorOr<Foo*> factoryE() { > ErrorOr<Foo*> f = new Foo; > return f; // works as expected > } > > ErrorOr<std::unique_ptr<Foo>> factoryEU() { >...
2013 Nov 22
0
[LLVMdev] ErrorOr<> conflicts with unique_ptr<>
...stions on how to code the following simple >> examples to not error? Can some of these be fixed in ErrorOr.h? Or am I >> totally not getting something? >> >> -Nick >> >> >> struct Foo { void doit(); }; >> >> >> std::unique_ptr<Foo> factoryU() { >> std::unique_ptr<Foo> f(new Foo); >> return f; // works as expected >> } >> >> ErrorOr<Foo*> factoryE() { >> ErrorOr<Foo*> f = new Foo; >> return f; // works as expected >> } >> >> ErrorOr<std::unique_p...