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,4f316de357ae35e9 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-07-31 13:57:34 PST Newsgroups: comp.lang.ada Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!nntp.abs.net!uunet!dca.uu.net!ash.uu.net!world!news From: Robert A Duff Subject: Re: FAQ and string functions Sender: news@world.std.com (Mr Usenet Himself) Message-ID: Date: Wed, 31 Jul 2002 20:56:10 GMT References: <20020730093206.A8550@videoproject.kiev.ua> <4519e058.0207300548.15eeb65c@posting.google.com> <20020731104643.C1083@videoproject.kiev.ua> NNTP-Posting-Host: shell01.theworld.com Organization: The World Public Access UNIX, Brookline, MA X-Newsreader: Gnus v5.7/Emacs 20.7 Xref: archiver1.google.com comp.lang.ada:27535 Date: 2002-07-31T20:56:10+00:00 List-Id: Simon Wright writes: > I didn't write Get_Next_Word (nor do I claim responsibility for the > problem that code has with improperly-terminated files :-) > > I would be surprised if the part of the Perl code that *implements* > split was short. > > When I *use* Get_Next_Word it only takes a line ... Yeah, but in Ada you have to implement it (or rummage around on the net to see if somebody already did, or see if your compiler vendor supports it), whereas with Perl, it's already there. Suppose I'm writing a long-lived application that does string fiddling. Should I choose Ada (because it has good type checking and whatnot, which helps make my code maintainable), or should I choose Perl, because it has useful string fiddling ops available (*portably* available)? It's annoying to have to make that choice, because the two issues are orthogonal (there's no reason why a language can't be good in both ways). So I think the original poster's complaint is reasonable. The complaint is, "X is not available"; the response, "well, you can write X yourself" is not impressive. To be honest, I would never choose Perl for *anything*, because I value various "ilities" over having some useful operations available. (I think Perl is an abomination.) But I can understand why some folks make the opposite choice. By the way, a partial answer to the original poster's question is to look at the various GNAT packages, such as SNOBOL. I have no idea whether they do what you want, but they do some kinds of string manipulation. They may be compiler dependent, or they may be useful with other compilers. - Bob