On 03/28/2012 03:20 PM, Marc Glisse wrote:
I agree that it works like initialization, and like lambdas, so that ship has sailed. I assume there were good reasons for that, even if they are not obvious, I know things can be trickier than they appear. However, I can't help thinking that there is something wrong with having to write:auto g(int i) -> decltype(f(i)) { return f(i); }
I agree that this is a serious problem; decltype has the semantics we want, and so new functionality that does something different may not actually be very useful. Unfortunately, making auto functions different from auto variables and lambdas isn't very appealing, either.
Jason
