We'd prefer to keep the checked-guard, since its purpose is to ensure that all errors are consistently thrown throughout the process.
We tend to avoid out-parameters so far in the C++ stack due to the inherent concerns with it, but if it is the only way to do it, I'd wish to see as soon as possible to make sure it is necessary. As far as std::forward, my understanding is that it should maintain the reference-ness of the parameters, so we could potentially have an issue. Got a sample that you could share? If I get time I could take a look. -Erich On Mon, 2015-08-03 at 21:58 +0530, ak.ashwini1981 wrote: > > > Hi Erich, List, > > > > I am working on the Provisioning Manager apis from C++ space. > > > > Intention is to have an out parameter in the function. The parameter > is a vector. I am passing this by reference. Pushing objects to vector > are not reflecting at the calling point. > > > > On debugging found that the reference pointers are different at two > sides of the checked_guard() function. > > Guess the std::forward is doing the trick here. > > > > Can I do without the checked_guard() and do the required param > validation and call the InProcClientWrapper function. > > > > Share your inputs. > > > > Thanks, > > Ashwini
