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_50,INVALID_DATE, MSGID_SHORT autolearn=no autolearn_force=no version=3.4.4 Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!rutgers!mtune!codas!novavax!hcx1!hcx2!joes From: joes@hcx2.SSD.HARRIS.COM Newsgroups: comp.lang.ada Subject: RENAMES? Message-ID: <94700001@hcx2> Date: Mon, 17-Aug-87 11:26:00 EDT Article-I.D.: hcx2.94700001 Posted: Mon Aug 17 11:26:00 1987 Date-Received: Thu, 20-Aug-87 06:10:53 EDT Nf-ID: #N:hcx2:94700001:000:779 Nf-From: hcx2.SSD.HARRIS.COM!joes Aug 17 11:26:00 1987 List-Id: Are renames tied to the value of the renamed variable at the time that they are elaborated, or do they always maintain the value of the renamed variable? I have an example program and I can't decide what it is supposed to do. Can anyone help? Thanks. Joe Schwartz Harris Corp. joes@HARRIS.COM ------------------------------------ cut here ---------------------------------- procedure rename is type ptr_type is access integer; acc : ptr_type := new integer'(1); ren_var : integer renames acc.all; -- ren_var now equals 1 begin acc := new integer'(10); -- change its value behind it's back -- WHAT IS ren_var's VALUE AT THIS POINT? 1 or 10? end rename; ------------------------------------------------------------------------------