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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,5894fe67040038b X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-11-09 16:07:02 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!newsfeed.berkeley.edu!news-hog.berkeley.edu!ucberkeley!newshub.sdsu.edu!newspeer.cts.com!galanthis.cts.com!127.0.0.1.MISMATCH!not-for-mail Sender: kst@king.cts.com Newsgroups: comp.lang.ada Subject: Re: Attributes 'Version and 'Body_Version References: <9s9iti$g$1@nh.pace.co.uk> <5ee5b646.0111081953.31e2633c@posting.google.com> From: Keith Thompson Date: 09 Nov 2001 16:07:00 -0800 Message-ID: X-Newsreader: Gnus v5.7/Emacs 20.7 NNTP-Posting-Host: 209.68.192.180 X-Trace: 1005350820 nntp.cts.com 54581 209.68.192.180 Xref: archiver1.google.com comp.lang.ada:16181 Date: 2001-11-09T16:07:00-08:00 List-Id: dewar@gnat.com (Robert Dewar) writes: > Keith Thompson wrote in message > news:... > > The version strings used by GNAT look like they might be > > 32-bit checksums of the source > ^ > sources!!!!! > > It's really important to realize that 'Version is nothing > like the version number of the source file, it is the > version of the OBJECT, not the source, and hence depends > on a whole set of sources. Here's the RM definition of the 'Version attribute, from E.3(3): P'Version Yields a value of the predefined type String that identifies the version of the compilation unit that contains the declaration of the program unit. And here's what 10.1(2) has to say about compilation units: The text of a program can be submitted to the compiler in one or more compilations. Each compilation is a succession of compilation_units. A compilation_unit contains either the declaration, the body, or a renaming of a program unit. The representation for a compilation is implementation-defined. It certainly looks to me as if 'Version applies to a compilation unit, and a compilation unit is a part of the text of a program. The version of a compilation unit changes whenever the compilation unit changes in a "semantically significant" way; the phrase "semantically significant" is explicitly left undefined. If unit A depends on unit B, a change in B can affect the object generated for A even if the source of A is unchanged. I don't see a requirement for A'Version or A'Body_Version to change when this happens, though I can see that such a requirement would be useful. It's likely that I'm missing something obvious, but I don't know what it is. -- Keith Thompson (The_Other_Keith) kst@cts.com San Diego Supercomputer Center <*> Cxiuj via bazo apartenas ni.