Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #132464

Re: Reverse SCAN SPLIT

From mhx@iae.nl (mhx)
Newsgroups comp.lang.forth
Subject Re: Reverse SCAN SPLIT
Date 2024-10-17 10:29 +0000
Organization novaBBS
Message-ID <73ec4c8359439c78d77d4fce31fc50b2@www.novabbs.com> (permalink)
References <5c65a8f1fdfc3e9937a825842fe23dc2758f48ef@i2pn2.org> <nnd$231a8f43$45dbf325@e6f1a2d146514222> <84a43479460314388420efa02405b006aea1677b@i2pn2.org> <nnd$231969a2$24a04042@87f25e33f755b9dd> <nnd$5d969265$1c9f3c75@2ccb8d0b9bcc719d>

Show all headers | View raw


On Thu, 17 Oct 2024 8:28:26 +0000, albert@spenarnc.xs4all.nl wrote:

> In article <nnd$231969a2$24a04042@87f25e33f755b9dd>,
[..]
> Compare to what I'm doing. Promoting the actual API specification
> so that you can decide whether you want to actually use it.
>
>    $/
>
>
>   STACKEFFECT: sc c --- sc1 sc2
>
>   DESCRIPTION: []
>
>   Find the first c in the string constant sc and split it at that
>   address. Return the strings after and before c into sc1 and sc2
>   respectively. If the character is not present sc1 is a null string
>   (its address is zero) and sc2 is the original string. Both sc1 and
>   sc2 may be empty strings (i.e. their count is zero), if c is the
>   last or first character in sc .

Wil Baden chose to keep c in sc2. Do you have a reason to
remove it?

It seems logical to remove it. I normally use lots of
`1 /STRING' and `-LEADING' or `-TRAILING' sequences in further
processing of Split-At-Char results, but not always.
Maybe because an empty sc2 is less informative than an sc2 of
size 1?

-marcel

Back to comp.lang.forth | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 19:52 +1100
  Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 09:55 +0000
    Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 10:03 +0000
      Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 23:07 +1100
        Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-07 19:25 +0000
          Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-08 13:58 +1100
            Re: Reverse SCAN SPLIT melahi_ahmed@yahoo.fr (Ahmed) - 2024-10-08 06:02 +0000
  Re: Reverse SCAN SPLIT Ruvim <ruvim.pinka@gmail.com> - 2024-10-07 14:02 +0400
    Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 22:22 +1100
  Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-07 23:13 +1100
  Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-10 17:00 +1100
  Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-10 10:00 +0200
    Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-10 20:57 +1100
      Re: Reverse SCAN SPLIT Hans Bezemer <the.beez.speaks@gmail.com> - 2024-10-16 18:13 +0200
        Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-17 10:28 +0200
          Re: Reverse SCAN SPLIT minforth@gmx.net (minforth) - 2024-10-17 09:16 +0000
          Re: Reverse SCAN SPLIT mhx@iae.nl (mhx) - 2024-10-17 10:29 +0000
            Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-17 12:48 +0200
              Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-19 01:41 +1100
                Re: Reverse SCAN SPLIT albert@spenarnc.xs4all.nl - 2024-10-19 13:36 +0200
            Re: Reverse SCAN SPLIT dxf <dxforth@gmail.com> - 2024-10-18 12:10 +1100

csiph-web