On Friday, 17 November 2017 at 00:36:21 UTC, codephantom wrote:
On Thursday, 16 November 2017 at 11:52:45 UTC, Ola Fosheim
Grostad wrote:
Uhm, no? What do you mean by 'primary focus of program design'
and in which context?
I the context that, this is specifically what Stroustrup says
in his book (The Design and Evolution of C++ 1994)
"Simula's class concept was seen as the key difference, and
ever since I have seen classes as the proper primary focus of
program design." (chp1, page 20)
Yes, that is reasonable, it is very useful when made available in
a generic form. I believe Simula was used in teaching at his
university.
A class in Simula is essentially a record, library scope,
block-scope, coroutines, with inheritance and virtual functions,
implemented as a closure where the body acts as an extensible
constructor. So it is a foundational primitive. Nygaard and Dahl
got the Turing award for their work. Ole-Johan Dahl was also a
coauthor of an influental book on structured programming which
had a chapter on it IIRC. Nygaard and others in Denmark later in
the 70s and 80s refined the class concept into a unifying concept
that was essentially the only primary building block in Beta
(called pattern, which allows functions to be extended using
inheritance, instantiation of objects from virtual patterns, type
variables as members etc).
So Beta establish that you don't need other structural mechanisms
than a powerful class concept + tuples for parameters.
Self establish the same with objects.
Freud would tell us, that Stroustups obssesion with Simula, is
where it all began.
Anyone that cares already know that Simula was an ancestor for
C++, Smalltalk, Java and many other OO languages... But
Stroustrup wasn't obsessed by Simula, if he was he would have
added things like coroutines, local functions, used the class as
a module scope etc. He also would have avoided multiple
inheritance.