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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.182.231.138 with SMTP id tg10mr48499811obc.2.1435097870952; Tue, 23 Jun 2015 15:17:50 -0700 (PDT) X-Received: by 10.182.125.73 with SMTP id mo9mr77016obb.29.1435097870903; Tue, 23 Jun 2015 15:17:50 -0700 (PDT) Path: buffer2.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!h15no7648312igd.0!news-out.google.com!kd3ni15490igb.0!nntp.google.com!j8no603943igd.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 23 Jun 2015 15:17:50 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=67.0.25.121; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC NNTP-Posting-Host: 67.0.25.121 References: <9894cde7-2cf8-4060-be65-857812ad7b09@googlegroups.com> <17436268-aceb-461f-bdcf-eee8436cd0e6@googlegroups.com> <86y4jaqzdx.fsf@stephe-leake.org> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <01ac6d30-fa93-4868-aa31-3dbec93e9a21@googlegroups.com> Subject: Re: What do you think about this? From: Shark8 Injection-Date: Tue, 23 Jun 2015 22:17:50 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: number.nntp.giganews.com comp.lang.ada:193754 Date: 2015-06-23T15:17:50-07:00 List-Id: On Tuesday, June 23, 2015 at 3:03:21 PM UTC-6, Laurent wrote: > You mean like this? Sry no idea on how to use pre/post conditions. > > function "+" (Right : String) return V_String.Bounded_String > is (V_String.To_Bounded_String (Right)) > with pre => Right <= V_String_Length; You want Right'Length, not Right. (The error message is the compiler saying it wants a Universal_Integer, but instead got a string.)