On Thu, Aug 16, 2012 at 5:09 PM, Jordan Rose <[email protected]> wrote: > I'm trying to wrap my head around what this means and failing. 'int *a = *a'?
That isn't as sneaky as the reference case, because "*a" on the right-hand side has type int, so you'd get a warning about trying to initialize a pointer with an int. The self-initialized reference case is also extra bad because we know it's going to be invalid forever since it cannot be changed. A badly initialized pointer can at least be made valid later. > I wouldn't worry about the 'a(b), b(a)' case. Or rather, the issue is that > 'b' is uninitialized in 'a(b)', and it doesn't really matter if it's given a > valid initialization later. Yeah, you're right. The reason I've got both a(b) and b(a) in there is because otherwise there'd be an error about one of them not getting initialized in the constructor. > I'm not so familiar with this part of Sema, but the diff looks reasonable. Thanks! Anyone else who'd like to take a look? - Hans _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
