Re: :decay related question
Travis Vitek wrote: Martin Sebor wrote: Travis Vitek wrote: Eric Lemings wrote: Page 490, section 20.3.1.2, paragraph 1 in the latest draft says this: "Let Ui be decay::type for each Ti in Types. Then each Vi in Vtypes is X& if Ui equals reference_wrapper, otherwise Vi is Ui." What do you suppose the relationship is between type `X' and types `Ti' and `Ui'? I see how the latter two types are deduced from the type list `Types' but not so sure about how type `X' is deduced from `Types'. I'm looking at this and I have no idea where VTypes and X are coming from. Is that an issue, or am I missing something? Have you found an issue for any of this? (If not, we/I will need to open one.) I don't see one. Unless Brad knows something that we don't, I think it should be brought up. Okay. Can one of you guys please summarize the problem along with a proposed resolution and send it to the c++std-lib list for review? I'll be happy to help you incorporate any feedback we get and, if necessary, put together an issue. Thanks Martin
RE: :decay related question
Martin Sebor wrote: > >Travis Vitek wrote: >> >>> Eric Lemings wrote: >>> >>> Page 490, section 20.3.1.2, paragraph 1 in the latest draft >>> says this: >>> >>> "Let Ui be decay::type for each Ti in Types. Then each >>> Vi in Vtypes is X& if Ui equals reference_wrapper, >>> otherwise Vi is Ui." >>> >>> What do you suppose the relationship is between type `X' >>> and types `Ti' and `Ui'? I see how the latter two types >>> are deduced from the type list `Types' but not so sure >>> about how type `X' is deduced from `Types'. >> >> I'm looking at this and I have no idea where VTypes and X are coming >> from. Is that an issue, or am I missing something? > >Have you found an issue for any of this? (If not, we/I will >need to open one.) > I don't see one. Unless Brad knows something that we don't, I think it should be brought up. >Martin > >> >> That said, I think X is supposed to be Ti. If that were the case then >> the definition would make some sense [at least to me]. >> >> Let Ui be decay::type for each Ti in Types. Then each >> Vi in VTypes is Ti& if Ui equals reference_wrapper, >> otherwise Vi is Ui. >> >> If that is right, then it essentially says that the 'make_tuple' >> function transforms reference_wrapper back to T& and for >other types >> does the normal decay transformation [function to funciton pointer, >> array to array pointer, and cv-stripping of all other types]. >> >> Travis >> >>> Brad. >>> > >
Re: :decay related question
Travis Vitek wrote: Eric Lemings wrote: Page 490, section 20.3.1.2, paragraph 1 in the latest draft says this: "Let Ui be decay::type for each Ti in Types. Then each Vi in VTypes is X& if Ui equals reference_wrapper, otherwise Vi is Ui." What do you suppose the relationship is between type `X' and types `Ti' and `Ui'? I see how the latter two types are deduced from the type list `Types' but not so sure about how type `X' is deduced from `Types'. I'm looking at this and I have no idea where VTypes and X are coming from. Is that an issue, or am I missing something? Have you found an issue for any of this? (If not, we/I will need to open one.) Martin That said, I think X is supposed to be Ti. If that were the case then the definition would make some sense [at least to me]. Let Ui be decay::type for each Ti in Types. Then each Vi in VTypes is Ti& if Ui equals reference_wrapper, otherwise Vi is Ui. If that is right, then it essentially says that the 'make_tuple' function transforms reference_wrapper back to T& and for other types does the normal decay transformation [function to funciton pointer, array to array pointer, and cv-stripping of all other types]. Travis Brad.
RE: :decay related question
>Eric Lemings wrote: > >> >> If that is right, then it essentially says that the 'make_tuple' >> function transforms reference_wrapper back to T& and for >> other types does the normal decay transformation [function to >> funciton pointer, array to array pointer, and cv-stripping of >> all other types]. > >That's what I thought. That's also what other implementations are >showing. > >Also, doesn't an array decay to a pointer to the element type? Yes. Just a typo. > >Brad. >
RE: :decay related question
> -Original Message- > From: Travis Vitek [mailto:[EMAIL PROTECTED] > Sent: Wednesday, June 18, 2008 5:29 PM > To: dev@stdcxx.apache.org > Subject: RE: :decay related question > > > > >Eric Lemings wrote: > > > >Page 490, section 20.3.1.2, paragraph 1 in the latest draft > says this: > > > >"Let Ui be decay::type for each Ti in Types. Then each > Vi in VTypes > >is X& if Ui equals reference_wrapper, > >otherwise Vi is Ui." > > > >What do you suppose the relationship is between type `X' and > types `Ti' > >and `Ui'? I see how the latter two types are deduced from the > >type list > >`Types' but not so sure about how type `X' is deduced from `Types'. > > I'm looking at this and I have no idea where VTypes and X are coming > from. Is that an issue, or am I missing something? Well I see where Vtypes is coming from: it's the type list composed of Vi where each Vi is... well that's the part I'm not sure about because of X. > > That said, I think X is supposed to be Ti. If that were the case then > the definition would make some sense [at least to me]. > > Let Ui be decay::type for each Ti in Types. Then each > Vi in VTypes is Ti& if Ui equals reference_wrapper, > otherwise Vi is Ui. > > If that is right, then it essentially says that the 'make_tuple' > function transforms reference_wrapper back to T& and for > other types > does the normal decay transformation [function to funciton pointer, > array to array pointer, and cv-stripping of all other types]. That's what I thought. That's also what other implementations are showing. Also, doesn't an array decay to a pointer to the element type? Brad.
RE: :decay related question
>Eric Lemings wrote: > >Page 490, section 20.3.1.2, paragraph 1 in the latest draft says this: > >"Let Ui be decay::type for each Ti in Types. Then each Vi in VTypes >is X& if Ui equals reference_wrapper, >otherwise Vi is Ui." > >What do you suppose the relationship is between type `X' and types `Ti' >and `Ui'? I see how the latter two types are deduced from the >type list >`Types' but not so sure about how type `X' is deduced from `Types'. I'm looking at this and I have no idea where VTypes and X are coming from. Is that an issue, or am I missing something? That said, I think X is supposed to be Ti. If that were the case then the definition would make some sense [at least to me]. Let Ui be decay::type for each Ti in Types. Then each Vi in VTypes is Ti& if Ui equals reference_wrapper, otherwise Vi is Ui. If that is right, then it essentially says that the 'make_tuple' function transforms reference_wrapper back to T& and for other types does the normal decay transformation [function to funciton pointer, array to array pointer, and cv-stripping of all other types]. Travis > >Brad. >