From: Frode Tenneboe <ft@alne.edh.ericsson.se>
Subject: Re: Optimising string handling in application
Date: Fri, 4 Apr 2003 10:13:41 +0000 (UTC)
Date: 2003-04-04T10:13:41+00:00 [thread overview]
Message-ID: <1049451208.932382@edh3> (raw)
In-Reply-To: sUFia.44007$OV.142208@rwcrnsc54
tmoran@acm.org wrote:
> You don't need the temporary (Dummy) string. Just calculate the
> length first,
> Msg_Length := Msg_Length
> - (Start_Next_String-Stop_First_String-1)
> + Callsign_Length;
> then set Msg(1 .. Msg_Length) to the concatenation.
Well, yes. Except that you now have overwritten the length of the orignal
string, but that's easily fixed. Thanks.
However, sometimes I miss the expressionness of perl:
s/([^;]*;ME001=)([^;]*)(;[^;]*)/$1$callsign$3/;
;-)
> Ah, so your abstract type is not "String", but rather a home-grown
> version of Bounded_String that passes the current length as a separate
> variable. Let me guess where this code originated...
:)
-Frode
--
^ Frode Tenneb� | email: Frode.Tennebo@eto.ericsson.se ^
| Ericsson AS., N-1788 Halden | Phone: +47 67 25 09 39 |
| with Standard.Disclaimer; use Standard.Disclaimer; |
next prev parent reply other threads:[~2003-04-04 10:13 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-04-01 11:54 Optimising string handling in application Frode Tenneboe
2003-04-01 18:52 ` Jeffrey Carter
2003-04-02 3:17 ` Steve
2003-04-02 4:10 ` tmoran
2003-04-02 7:15 ` Frode Tenneboe
2003-04-02 18:23 ` tmoran
2003-04-04 10:13 ` Frode Tenneboe [this message]
2003-04-04 13:26 ` Preben Randhol
2003-04-04 14:42 ` Frode Tenneboe
2003-04-04 21:48 ` Warren W. Gay VE3WWG
2003-04-05 7:24 ` Pascal Obry
2003-04-04 14:08 ` Frank J. Lhota
2003-04-04 15:26 ` Robert Spooner
2003-04-04 21:49 ` Warren W. Gay VE3WWG
2003-04-04 17:43 ` tmoran
2003-04-04 21:42 ` Frode Tennebø
2003-04-02 19:03 ` tmoran
2003-04-04 10:44 ` Frode Tenneboe
2003-04-05 3:28 ` tmoran
2003-04-05 0:08 ` Jeffrey Carter
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox