[comp.lang.ada] Pascal Subset of Ada?

larry@VLSI.JPL.NASA.GOV (03/04/89)

--
For would-be Ada programmers who have a strong background in an
Algol-based language, I say that Ada contains a "Pascal subset"
which makes up about 1/2 the language.  I suggest chapters in their
chosen text that are in this subset.  Pascal programmers benefit
most from this approach, though I warn them that there are subtle
differences between Ada and Pascal which are likely to cause them
more trouble than the obvious ones.  (Subtle ones require them to 
first notice then unlearn something.)  With this approach a Pascal
expert can be productive in Ada within a couple of weeks,
though they may be writing "Pascalized" code.

Anyone who feels forced to learn Ada, of course, will balk at it. 
Perhaps they should be allowed to continue writing Pascalized or
even "ForTranized" code.  A year later they will likely have cooled
down.  Peer pressure, common sense, or curiosity may then lead them
to study the "Advanced 1/2" of Ada.  Even those willing to learn
more probably need a few weeks or months of continued use to master
the basics.

Meanwhile, they will have developed not only reflexive but also
conceptual skills that will make that easier.  When they read Ada
code with advanced features, the only parts of it they will have
to consciously think about will be those features.  Also, the fact
that Ada was designed as an integrated rather than kitchen-sink 
language often leads to a response such as: "Of course that's 
the way generics/tasking/rep specs work.  Why are you spending 
so much time on the obvious?"

When students are not only willing but eager to learn Ada, I'd give
them fairly early a copy of a template program that shows how to
use packages, subunits, and private types to implement libraries
of ADTs.  They could use it in cook-book fashion until they
mastered the Pascal subset.  When they get to the "Advanced" 1/2
of the text, the reasons for the template will become clear & they
can more intelligently use it, or change it or pick an alternative. 
Until then, they can at least use Ada somewhat in the manner it
should be.
                            Larry @ vlsi.jpl.nasa.gov