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,e6c9800e35ccfeee X-Google-Attributes: gid103376,public From: bobduff@world.std.com (Robert A Duff) Subject: Re: GNAT: Performance of String functions Date: 1997/07/24 Message-ID: #1/1 X-Deja-AN: 258490614 References: <5r5cfh$irn$1@ratatosk.uio.no> <33D66563.3F86@link.com> Organization: The World Public Access UNIX, Brookline, MA Newsgroups: comp.lang.ada Date: 1997-07-24T00:00:00+00:00 List-Id: In article <33D66563.3F86@link.com>, Samuel Mize wrote: >You can get all but 4 (normal assignment) with a limited variant >record with a discriminant (max length). To assign the value, >you provide a "copy" routine. Don't provide a default value >for the discriminant, so the user will have to explicitly give >a max size for each variable of this type. (If you provide a >default value, the implementation may allocate the subtype's >max size for each record.) No, the compiler should not allocate the max. The thing is limited, therefore its size can't change, therefore whatever size corresponds to the default should be allocated (when the default is used). - Bob