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,e1bb9627c57b7d5b X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-10-03 08:54:22 PST Path: archiver1.google.com!news2.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news-out1.nntp.be!propagator2-sterling!news-in-sterling.nuthinbutnews.com!cyclone1.gnilink.net!wn14feed!wn13feed!worldnet.att.net!204.127.198.203!attbi_feed3!attbi.com!sccrnsc02.POSTED!not-for-mail From: "Mark A. Biggar" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: U : Unbounded_String := "bla bla bla"; (was: Is the Writing...) References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 12.235.88.213 X-Complaints-To: abuse@comcast.net X-Trace: sccrnsc02 1065196458 12.235.88.213 (Fri, 03 Oct 2003 15:54:18 GMT) NNTP-Posting-Date: Fri, 03 Oct 2003 15:54:18 GMT Organization: Comcast Online Date: Fri, 03 Oct 2003 15:54:18 GMT Xref: archiver1.google.com comp.lang.ada:159 Date: 2003-10-03T15:54:18+00:00 List-Id: amado.alves wrote: > "...we already have implicit conversion in Ada for numeric literals." (Jeff) > > I know, and that was the 'precedent' for my proposal. And I'm familiar with the 'nightmare' of generalised implicit conversion (in C). But this could be tamed in Ada by defining the effect scope of pragma Implicit_Conversion to be the immediately enclosing block. > > Or a family of such pragmas for fine control of the effect: > > Implicit_Conversion_Down_From_Here > Implicit_Conversion_Up_To_The_Next_Enclosing_Block > Implicit_Conversion_All_Over > > However I am not totally confortable with *pragmas* for this class of effect. Is their precedence? The ARG would probably reject these pragmas out of hand. There are currently no pragmas that take a syntatically illegal program and make it legal, which is what the above do (actually pragma import is an exception to this rule, but it fills in missing syntax, not changes illegal to legal). It's alright to make legal things illegal (E.g., pragme restrictions) but not the other way. See LRM 2.8(16) -- mark@biggar.org mark.a.biggar@comcast.net