From: wolff@inf.fu-berlin.de (Thomas Wolff)
Subject: Re: Editor mined (Unix, VMS, MSDOS) - easy, solid, non-8-bit-obstructing (1/4)
Organization: Free University of Berlin, Germany
Date: Thu, 30 Jul 1992 12:42:12 GMT

peter@ferranti.com (Peter da Silva) writes:

>I really hope one of these "simple" editors will help me break the user inter-
>face logjam, but so far they've all been hacks. This one is, alas, no
>exception.

I do not object. However, the original version of mined is much more of a hack than my 
modifications are. Anyway, I would never have started to write a program using C.
(But at least this was a chance to learn C as much to be able to remove bugs...)

>In article <42I54HD@math.fu-berlin.de> wolff@inf.fu-berlin.de (Thomas Wolff) writes:
>> ,In response to recent requests for a free, simple, and solid editor 
>> ,(where the problem is: emacs is not simple, most public domain 
>> ,contributions are not solid, and vi is not an editor), 
>> ,I wish to contribute my adaptation of mined.

>I hope that Thomas Wolff is the person responsible for the more bizzarre
>code in this program.
That depends on what you think is bizarre. Please get an original version to compare.

> I'd hate to think that Andy Tannenbaum put comments
>like "C is such a stupid language" when trying to assign a (char **) to a
>(char **[]). Vi might not be an editor, but at least it runs.
Mined runs fine on SunOS, Micro-Vax Ultrix, Iris IRIX, VMS, and MSDOS including the 
following assignment you feel disturbed by and its later uses:
char * (* fnamv) [];
  ...
  char * argv [];
  fnamv = argv;	/* Why does this produce a warning? C is such a stupid language! */
I really don't think it's my fault that compilers produce warnings like 
"illegal pointer combination" on this. 
On the one hand, type inconsistencies are quite common in C, aren't they?, and the 
assigment does work as it is, on the other hand, I tried lots of variations of 
the declarations most of which did not work. If you could advise me how to change 
the declarations such that the compiler does not complain AND it works, I would be 
thankful.

>> ,- fully functioning in windows which may be resized at any time and the 
>> ,  editor will react immediately and install a correct screen image; the 
>> ,  cursor stays at the point of text where it was

>There are systems that define TIOCGWINSZ that don't provide BSD semantics. You
>need to make this an explicit option in the Makefile. For that matter, where
>is the Makefile?
A Makefile is in the posting part (1/4). (mkmined is just my shell script I used 
before I cared about learning make. You can safely delete it.)

>Clean it up a bit, 
I've already cleaned it a lot. If there are further wishes, I'd be glad to hear of them.

> I'll be happy to help, 
Thanks a lot. If you tell me how systems different from the ones mentioned above handle 
window size changes, I'd be happy to include the code for that.

> but right now it's about as solid as a snowman in June.
As said before, it runs faultlessly on various systems and serves my needs well.
Thank you very much for caring about the editor and its source.

Thomas Wolff
Freie Universit:at Berlin
wolff@inf.fu-berlin.de