On Monday 06 April 2015, Ron K. Jeffries wrote:
Hi Ron!
> Hans, Can you expand on this statement:
> External editors are supported by 4tH executable.
Yes. The new 4tH executable allows you to set something like:
EDIT4TH=notepad
And notepad will be used when you press "e" (for edit). I haven't tested it
yet on all OS-es, but I see no reason why it wouldn't work (system() call).
Quit the editor when you're done and you go back to the menu.
> Semi-unrelated: A fresh paragraph or three that gives a crisp view of what
> makes 4th uniquely valuable might be A Good Idea. Don't take something
> you've already written, rather take a deep breath and tell a friend why 4th
> is special.
I never liked several things about classical Forth:
- I had to drag the whole shebang along when using a program (no or overly
complex turnkey I never got to work properly);
- It didn't interface well with C or Make;
- Lots of different kinds of numbers (mixed, double, floating) that drove me
nuts at times (funny though, I added all that afterwards);
- Crash, your PC is locked (in the XT/AT days).
> What are a few of the most spot on use cases?
- You want to build your own development system in an easy way;
- You need a scripting language (and adapt it);
- You want to learn Forth, but a classic Forth is too alien, undocumented or
unfriendly;
- You want to know how things work, but a ton of sourcecode doesn't help you
to grasp the concept;
- You want to make a conversion utility FAST (wonderful template - I call it
my "ETC");
- You need a program to run on several OS-es with least trouble.
4tH allowed me to learn (and implement) lots of new concepts. I learned about
local variables, floating point, spreadsheets, editors, preprocessors,
multitasking, interpreters, webservers, etc. I always try to keep the size of
the source low. First, because I don't like bloat, second, because it is
excellent educational material that way. Where do you find a functioning
spreadsheet in just a few K?
> How would you characterize you target 4th user?
Like me. I never had an audience in mind. On the other hand, 4tH evolved into
something else than I originally had in mind - and the users did that.
> Don't forget your embedded BASIC.
> Other included applications? Some people might use it just for the data
> mangling code you developed for your day job. I have not tried it, but back
> in teh mists of time I struggled with dirty CSV files. They are a bitch, I
> think (??) you have a solid tool for working with malformed CSV files, you
> know, wher a comas is missing, or the quoites are screwed up, and the
> parser needs to recover when it sees the line end. In my cases those are
> fatal problems that are ugly to find.
Oh, there are lots of useful things. Like an entire CSV manipulation and
conversion suite. Or a subtitle shifter. Or yes, the BASIC interpreter. Many
conversion utilities..
Malformed CSV's are notoriously hard to fix. I once got one that did this:
"First field,""Second field","Third "Field"
Try parsing that. Newlines are very hard as well when misplaced. I think RFC
4180 tried very hard to standardize the current situation. I think they
should have tried to make a better one, because the current standard is hard
to parse at times - even when it is properly formatted. IMHO, the solution
that was chosen for HTML (e.g. &) was much better. Escaped or doubled
characters don't make life easier, unless they are encoded (e.g. \q vs. \").
> Does anyone not in the FORTH universe care? I don't know the answer.
When 4tH started there was massive aversion against it, because it didn't play
by the rules (no classic Forth engine). Some even claimed it wasn't Forth at
all. The standard (ANS) is worded in such a way that 4tH can never be
a "standard compiler".
That has subsided a bit now and I have no trouble working with the Forth
community. However, there isn't much love either. I have noted though, that
there is a bit more attention to documentation nowadays - and the pioneering
of 4tH is acknowledged in that regard.
Hans Bezemer
--
I have no Facebook account. Consequently, I have no friends and I don't like
anything. Deal with it.
Visit our website!
http://thebeez.home.xs4all.nl/4tH/
*** Home of the 4tH compiler! ***