comp.lang.ada
 help / color / mirror / Atom feed
* Re: Typing Ada
@ 1988-05-20 12:51 Karl A. Nyberg
  0 siblings, 0 replies; 12+ messages in thread
From: Karl A. Nyberg @ 1988-05-20 12:51 UTC (permalink / raw)


[Ed - forwarded.  Hopefuly this won't have gone out twice!]

-- Karl --

Date: Thu, 19 May 88 20:56:40 EDT
From: umd5!mitre-bedford.ARPA!sdl (Litvintchouk)
To: munck@mitre-bedford.arpa, INFO-ADA-REQUEST@ajpo.sei.cmu.edu
Subject: Re: Typing Ada


> I'd like to think that most programmers are using some kind of
> Ada-aware editor, but I fear it isn't so.  I'd appreciate an e-mail
> note describing what you do and what other programmers in your
> company/institution do.  (People who read Ada-Info are apt to be an
> unrepresentative sample.)

I wish I had a really "Ada-aware" editor, but I've managed to tailor
GNU Emacs on our Suns into something I (and a few fellow programmers)
can live with.  Currently the libraries I have added include:

1.  VADS modes:  Invoke most of the Verdix Ada tools with a single key each.

2.  Code idioms:  To get a "blocking queue" (in the Hibbard
	sense), type M-x adt-active  (i.e. "active abstract 
	data type"), at the prompt type QUEUE, and a skeleton of
	the package spec and body are inserted.  (It includes the 
	private part refined as a record type with a task component, etc.)
    I currently have a few code idioms for various kinds of abstract data
	types and selective waits (i.e. prioritized with guards),
	and am open to suggestions for more.
	
3.  Suntools menu interface:  Context sensitive Sun popup menus for
	these and other GNUEmacs modes

I would like to add a VADS library browsing mode (which would work
similar to Emacs' Buffer Menu mode), but I haven't had the time (yet).

GNU Emacs already has dynamic abbrevs (i.e. can complete a name based
on others already entered in the buffer), and hiding of indented
structure (replaced by "...") deeper than a user-settable threshold.
Together with the interface to a.tags I added, browsing of Ada code
isn't too hard.

One of my major gripes is that there appear to be no Ada
prettyprinters that can work on code *fragments*.  They all seem to
work only on entire Ada compilation units; I don't even know of any
ones which can recover from syntax errors in the Ada code and continue
prettyprinting.  Such restrictions make prettyprinters largely useless
during the editing process.  If a prettyprinter existed which could
work on a code fragment, then one could easily create an Emacs
"prettyprint-region" command by invoking the prettyprinter as an
inferior process with the region as input.

Bob Munck's suggestion of "outliner" like facilities for Ada is a good
one.  However, I thought that most document outliners assume that the
document is tree-structured.  But Ada's static semantics make Ada code
a network, not a pure tree.  (For instance, if you do something to a
private type declaration, then the refinement in the private part may
change, as well as references in the body, etc.) So an Ada "outliner"
would need to be network structured, and deal with Ada syntax and
static semantics.  The commercial failure of DIANA has made attainment
of this dream unlikely for those of us who cannot afford a Rational as
our personal plaything.

By the way, I believe that COMPASS is working on a smart interface to
editing Ada source code, which eventually will include handling of
network-like dependencies.  If anyone from COMPASS is reading this,
could you please enlighten us?


Steven Litvintchouk
MITRE Corporation
Burlington Road
Bedford, MA  01730
(617)271-7753

ARPA:  sdl@mitre-bedford.arpa
UUCP:  ...{cbosgd,decvax,genrad,ll-xn,mit-eddie,philabs,utzoo}!linus!sdl

	"Those who will be able to conquer software will be able to
	 conquer the world."  -- Tadahiro Sekimoto, president, NEC Corp.

^ permalink raw reply	[flat|nested] 12+ messages in thread
* Re: Typing Ada
@ 1988-05-12 17:28 zellich
  0 siblings, 0 replies; 12+ messages in thread
From: zellich @ 1988-05-12 17:28 UTC (permalink / raw)


In INFO-ADA Digest Vol 88 #115, Bob Munck discusses using language-aware
"outline processors" for writing and modifying Ada code; he also mentions
"Doug Englebart's fantastic system with the mouse and chord keyboard" from
"about twenty years ago".

It is probably little known, but Tymshare (whatever they're called now
that McDonald-Douglas bought them up) markets the current version of
Dr. Engelbart's system (called AUGMENT these days), which has hooks to
let you add language-specific constructs to the BASE editor (so you can do
things like issuing "Insert IF-ELSE" commands).  Unfortunately for most of us,
it only runs under the TENEX or TOPS-20 operating systems.

They also happen to have a MiniBASE product that is a major subset of the
BASE editor, and runs on the IBM PC family.  I don't know whether the mini
version has the hooks to add language-specific constructs or not, but it
does use a mouse - and sells for only $59.50.  They also made chord-keyset/mouse
packages for a while, but nobody outside that community ever took to the keyset
so they stopped making and selling it.

I don't know who the marketers are these days, but Raylene Pak
<RDP.TYM@OFFICE-1.ARPA> might be the right person to start with.  A query to
FEEDBACK@OFFICE-1.ARPA should also get you pointed in the right direction.

Disclaimer: I've corresponded with Raylene Pak about getting MiniBASE and
their AUGTERM (Augment workstation emulation package for the PC family)
product, but I haven't actually used the software yet.  I'm a long-time user of
Tymshare's hardware and software, but haven't had any contractual connection
with them for several years.

^ permalink raw reply	[flat|nested] 12+ messages in thread
* Typing Ada
@ 1988-05-10 16:28 Bob Munck
  1988-05-24  3:51 ` Rick Conn
  0 siblings, 1 reply; 12+ messages in thread
From: Bob Munck @ 1988-05-10 16:28 UTC (permalink / raw)



It has occurred to me recently that one of the most primitive,
labor-intensive operations in our current Ada technology is the
actual entry of code by programmers.  For example, it appears that
most programmers type an IF .. THEN statement by pressing SHIFT and
typing "I" and "F", releasing SHIFT and typing SPACE, the boolean,
and SPACE, pressing SHIFT and typing "T", "H", "E", and "N", etc. 
They type lots of tabs and spaces to indent the code, take at least
three keystrokes for an assignment, have to type closing quotes,
right parenthesis, and right brackets, have to type the package or
procedure name a second time after the END, etc. etc.

I'd like to think that most programmers are using some kind of
Ada-aware editor, but I fear it isn't so.  I'd appreciate an e-mail
note describing what you do and what other programmers in your
company/institution do.  (People who read Ada-Info are apt to be an
unrepresentative sample.)

However, the simple Ada-aware editor is only a beginning.  Editors
could do line-wrapping and spelling checking on comments as they're
typed, they could let you use a mouse to re-arrange code, and they
could display it with keywords in bold and comments in italic fonts. 
They could allow abbreviation of identifiers and expand them as
they're typed, fill in the rest of an identifier when you've typed
enough for a unique selection, or let you pick names from the
declarations with the mouse.

At the next level of sophistication, an editor could contain a lot
of the compiler and use information from the current compilation
unit and the Ada library to help the programmer.  This is a fairly
obvious approach that several systems already incorporate, sometimes
without doing the simpler things mentioned above.

I first saw an outline processor about twenty years ago, Doug
Englebart's fantastic system with the mouse and chord keyboard. 
Currently I use a commercial product named "ThinkTank" and it
frustrates the dickens out of me not to be able to do similar things
when writing code.  "Outliner-like" facilities would be great for
those who must maintain and update the code, also.

My current work is "operating system-type" code which, by its
nature, consists mostly of assignment statements, conditionals, and
complex data and code structures.  I've found it useful to maintain
a drawing of the complete data structure using a CAD tool and to
write a tool that extracts a picture of the code structure to the
procedure level from the listings.  I keep both of these up-to-date
and tacked to the wall in front of me.  The point is, it would be
wonderfully convenient if these two pictures could be in windows on
the screen and allow me to pick names from them with the mouse. 
Given that I can request statement skeletons by hitting function
keys with the left hand, I'd rarely have to move my hands to the
keyboard.  Of course, it would be great to be able to update the two
pictures and have the changes propagate into the code.

Is anyone out there doing research into this kind of thing?  I've
about reached the limit of macros for my emacs-like editor (Final
Word).
                         -- Bob Munck, MITRE

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~1988-05-26 14:14 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1988-05-20 12:51 Typing Ada Karl A. Nyberg
  -- strict thread matches above, loose matches on Subject: below --
1988-05-12 17:28 zellich
1988-05-10 16:28 Bob Munck
1988-05-24  3:51 ` Rick Conn
1988-05-24 15:32   ` Bob Munck
1988-05-24 23:06     ` Rick Conn
1988-05-25 16:49       ` Eugene N. Miya
1988-05-25  5:53     ` Richard A. O'Keefe
1988-05-25 16:57       ` Randy Neff
1988-05-26 14:14         ` Robert Eachus
1988-05-26 12:40       ` David Collier-Brown
1988-05-25 13:30     ` Roger Racine

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox