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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: is it possible to add multi-line raw strings (HERE-DOCUMENT) support to Ada? Date: Fri, 10 Jul 2015 23:04:33 +0200 Organization: cbb software GmbH Message-ID: <1d75x6ii1vkr7.d1tg9hhyzvwl.dlg@40tude.net> References: Reply-To: mailbox@dmitry-kazakov.de NNTP-Posting-Host: evoS9sCOdnHjo0GRLLMU1Q.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org User-Agent: 40tude_Dialog/2.0.15.1 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:26752 Date: 2015-07-10T23:04:33+02:00 List-Id: On Fri, 10 Jul 2015 12:00:52 -0500, Nasser M. Abbasi wrote: > It is very useful to be able to have multi-line raw > strings in the code, written as is, over many lines, > as one raw string. There is no such thing. String is a string an array of characters. > Ada currently does not support this feature. This is called > multi-line raw strings, and also called HERE-DOCUEMNT > > https://en.wikipedia.org/wiki/Here_document Useless and misleading. Ada as an OO language supports implementation of text buffers of any sort. WiKi authors contaminated by Unix and untyped languages seem unaware that text buffer is neither file nor string. > How hard would it be to add support for this in Ada? No problem at all. > Either at language level, or as a package? It does not make sense to provide this feature at the language level because different applications of text buffer require different implementations and interfaces. E.g. GTK text buffer supports mark-up and tagging pieces of text. The buffers I use for parser don't need that, nor they need editing support GTK text buffer has etc. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de