Chuck, You're right. I should have checked the LRM for the type of the result of "**". Please record an approve vote from me for IR2073. Cheers, PA -- Dr. Peter J. Ashenden peter@ashenden.com.au Ashenden Designs Pty. Ltd. www.ashenden.com.au PO Box 640 VoIP: 0871270078@sip.internode.on.net Stirling, SA 5152 Phone (mobile): +61 414 709 106 Australia > -----Original Message----- > From: Chuck Swart [mailto:cswart@model.com] > Sent: Monday, 5 December 2005 17:57 > To: Peter Ashenden > Subject: Re: Comments on IR2073 > > > Peter, > I think that you have misinterpreted the LRM > For exponentiation, the second (right) argument must be of > type INTEGER, so in this case N is of type INTEGER. However, > the result type of the exponentiation is the type of the left > argument, > which is 2. So the type of the right bound (if there is no implicit > conversion) > is universal_integer. > > Do you agree? > > Chuck Swart > > Peter Ashenden wrote: > > >Folks, > > > >In the range in the example (0 to 2**N-1), presumably N is a > constant, > >so it's type will be the base type of some explicitly > declared integer > >type, not universal_integer. > > > >3.2.1.1 says that both bounds must be of the same type, other than > >universal_integer, and that this type must be determined > independently > >of the context, but using the fact that ... both bounds must > have the > >same type. This seems to combine with the rule in the last para of > >7.3.5 to warrant an implicit conversion of the left bound from > >universal_integer to the same type as the right bound. In that case, > >the example would be legal. Am I misinterpreting? > > > >Apart from that, the recommendation appears ok. It deals > with the case > >Chuck mentioned, of the range -1 to 100. > > > >Cheers, > > > >PA > > > >-- > >Dr. Peter J. Ashenden peter@ashenden.com.au > >Ashenden Designs Pty. Ltd. www.ashenden.com.au > >PO Box 640 VoIP: > 0871270078@sip.internode.on.net > >Stirling, SA 5152 Phone (mobile): +61 414 709 106 > >Australia > > > > > > > > > >Received on Tue Dec 6 17:48:54 2005
This archive was generated by hypermail 2.1.8 : Tue Dec 06 2005 - 17:48:57 PST