From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,c462e8ad74872a98 X-Google-Attributes: gid103376,public From: stt@houdini.camb.inmet.com (Tucker Taft) Subject: Re: Question on modular types Date: 1997/01/09 Message-ID: #1/1 X-Deja-AN: 208693735 sender: news@inmet.camb.inmet.com (USENET news) x-nntp-posting-host: houdini.camb.inmet.com references: organization: Intermetrics, Inc. newsgroups: comp.lang.ada Date: 1997-01-09T00:00:00+00:00 List-Id: Robert Dewar (dewar@merv.cs.nyu.edu) wrote: : Robert Duff said : "Convention to those who have read the RM, and understand that arithmetic : on modular types is always wrap-around arithmetic. ;-)" : I cannot find anywhere in the RM where it says that unary minus has : wrap around arithmetic semantics, can you point me to the place where : this is said. Two places: 3.5.4(19) gives the general rule that anytime the result of a predefined operator of a modular type is outside the base range of the type, the result is reduced modulo the modulus of the type. The second is in a note, 4.5.4(3). -Tucker Taft stt@inmet.com http://www.inmet.com/~stt/ Intermetrics, Inc. Cambridge, MA USA