THE BACKGROUND
I have read the TeXbook and the LaTeX book through with
medium concentration. I have used TeX a little. I
tried to read "TeX - The Program" but it was too much
for me.
I have a copy of the original Knuth WEB report and have
glanced through it.
But I never had any real use for these methods before.
Now we are considering CWEB for a middle sized four
people programming project at The Helsinki University,
Department of Computer Science. Our department uses
LaTeX a lot but has very little experience with WEB.
I have spent two days reading the LitProg stuff in WWW
- an excellent proof of the tremendous effectiveness of
Internet technologies of today as learning tools.
THE PROBLEM
However, I maybe stupid but I don't quite understand
how to write a makefile and WEB source files to produce
- a single document with single contents and index page
- lots of C++ header and implementation files
Maybe this is trivial and is done with CWEB
@(object.H@> and @(object.C@> commands? How about
multiple WEB source files?
We are using all kinds of weird C++ features
extensively, I don't think that could be a problem?
And I am not sure if I am in the right track at all.
And what do you think, should I complicate this even
further by introducing SCCS to the project?
Good grief, tell me what is the fastest way for humble
humans to write best possible code! With "best" I mean
a) understandable
b) re-usable
c) with fool proof easy to use user interface
d) reliable
I don't give a damn about memory requirements or speed!
I believe in systems simple enough to be obviously
right, not in systems complex enough not to be
obviously wrong.
Why am I posting this anyway? I should be reading the
docs and examples instead... And the whole project
(program visualization, concentrating on string
algorithms) should maybe be done in Visual Basic if we
wanted to get it done fast...
Anssi.Po...@Helsinki.Fi
My experiences with C++ on a project of medium size have been very
encouraging. I am using only a small subset of the language, and I am
using it conservatively, orientating myself with Stroustrup's "The C++
Programming Language".
The two features that are most important to me are
* the possibility of bundling functions and data together and
* operator overloading.
In fact, the latter point alone would justify my using C++. Being in
the business of computer assisted mathematical proof, I want my code
to be as close to mathematical notation as possible.
But I agree that the language is huge; it must be a nightmare to
write a C++ compiler.
Back to Anssi's question: I have been using C++ together with FWEB for
about one year, and I am pleased with the results. Recently I
switched to NOWEB, which I prefer to FWEB, mainly because of the ease
with which it fits into the UNIX toolbox. I also find its syntax
more flexible.
My advice would be: Keep using C++, and use it together with NOWEB.
Andreas Stirnemann.
ASti...@maths.ex.ac.uk
> Ada9X (free compiler from GNU)
Ok, where can I find this? I just checked prep.ai.mit.edu. If it is
there it is not named in a manner such that I can figure out what it
is (gnada, gnu-ada, ada9X...) I have seen no anouncement of its
availability. Does it in fact exist? Has 9X with OOP extensions
actually been formally accepted yet? Commercial Ada compilers are
*way* too expensive for this Navy employee.
--
eric
og...@tethys.nswc.navy.mil
Anyway, if we wait until the perfect programming language is developed and
it is a final product, we will find that we are too old (or possibly even
dead). Isn't it better to make a reasonable compromise?
,~~~/ /` / /| /~~~
/ / |_/ /__/ ' | /
/ /~~/ /~~/ /~~/ /~~/ /\ | /| / /~~/ /~~/ /~~/ /~~/ /~~~
/ , / / /~~~ / / /~~~ / \ |/ |/ / /_/ / / / /~~~ /
~~~~ ~~~ ~~~ ' ' ~~~ ' ` ' ' ~~~ ~~/ ' ' ~~~ '
Zdenek Wagner______/
Some gateway between me and you may garble backslash. It will appear
on your screen as ã due to problems with EBCDIC <--> ASCII conversion.
It has already been corrected on SOME gateways.
The domain `.cs' does no longer exist and was replaced by `.cz'.
Valid addresses are: <wag...@csearn.bitnet>
<wag...@earn.cvut.cz>
^^
Try `gnats' -- Gnu Ada Translation System
Thomas
------------------------------------
Thomas Herter, SNI Muenchen (thomas...@mch.sni.de) tel +89 636 49973
Just FYI ... after giving Knuth credit for this for years, I recently
saw a place where Knuth attributes it to C.A.R. Hoare. From ``The
Errors of TeX,'' on page 276 of _Literate_Programming_:
"But I also knew, and forgot, Hoare's dictum that premature
optimization is the root of all evil in programming."
Does anybody know where this statement first appeared?
---Glenn
(crossposted to alt.quotations)
>In article <CARROLL.94...@stimpy.eecis.udel.edu>
>car...@stimpy.eecis.udel.edu (Mark C. Carroll) writes:
>> Ada9X (free compiler from GNU)
> Ok, where can I find this? I just checked prep.ai.mit.edu. If it is
>there it is not named in a manner such that I can figure out what it
>is (gnada, gnu-ada, ada9X...)
gnada is close. The thing is called gnat, but don't ask me why. Don't
ask me how good it is currently, or at all, as I never looked into it.
--
David Kastrup d...@pool.informatik.rwth-aachen.de
Tel: +49-241-72419 Fax: +49-241-79502
Goethestr. 20, D-52064 Aachen
Eric> In article <CARROLL.94...@stimpy.eecis.udel.edu>
Eric> car...@stimpy.eecis.udel.edu (Mark C. Carroll) writes:
>> Ada9X (free compiler from GNU)
Eric> Ok, where can I find this? I just checked prep.ai.mit.edu. If
Eric> it is there it is not named in a manner such that I can figure
Eric> out what it is (gnada, gnu-ada, ada9X...) I have seen no
Eric> anouncement of its availability. Does it in fact exist? Has 9X
Eric> with OOP extensions actually been formally accepted yet?
Eric> Commercial Ada compilers are *way* too expensive for this Navy
Eric> employee. -- eric og...@tethys.nswc.navy.mil
The GNU Ada compiler is called GNAT. The current version is available
from cs.nyu.edu. I haven't had the opportunity to do much with it
recently, but the authors claim to have implemented most of the 9x
spec. Tagged types are definitely working.
(BTW, sorry about the misleading title change. I was originally taking
a detour in my earlier message, which I decided to defer to another
message, and I forgot the change the title back.)
<MC>
--
The GNU Ada compiler is called GNAT. The current version is available
from cs.nyu.edu. I haven't had the opportunity to do much with it
recently, but the authors claim to have implemented most of the 9x
spec. Tagged types are definitely working.
Thanks to all those who pointed me at this. I am taking a look at it.
Hoping to find a *good* OOP environment. Ada is not one of the first
places I would have looked but perhaps 9x has fixed that? c++ is
definitely getting on my nerves lately. Operator overloading in c++
particularly seems *extremely* inflexible and baroque. If this is
supposed to be one of c++' *good* features, I am a little worried.
Too bad our management is too narrow minded to consider real options
such as CLOS or Smalltalk... Oh yeah, this is the literate programming
group... seems to be flooded with inappropriate post lately, such as
mine... sorry, won't happen again:)
--
eric
og...@tethys.nswc.navy.mil
David> og...@tethys.nswc.navy.mil (Eric Ogata) writes:
>> In article <CARROLL.94...@stimpy.eecis.udel.edu>
>> car...@stimpy.eecis.udel.edu (Mark C. Carroll) writes:
>>> Ada9X (free compiler from GNU)
David> gnada is close. The thing is called gnat, but don't ask me
David> why. Don't ask me how good it is currently, or at all, as I
David> never looked into it. -- David Kastrup
GNAT = GNU/NYU Ada Translator.
<MC>
--
> >``Premature optimization is the root of all evil.''
> > -- Knuth
>
> Just FYI ... after giving Knuth credit for this for years, I recently
> saw a place where Knuth attributes it to C.A.R. Hoare. From ``The
> Errors of TeX,'' on page 276 of _Literate_Programming_:
>
> "But I also knew, and forgot, Hoare's dictum that premature
> optimization is the root of all evil in programming."
>
> Does anybody know where this statement first appeared?
I first saw this statement in Knuth's article on using goto's (somwhat
of a response to Dijkstra's famous ``Goto statement considered
harmful''). I forget the exact title, the the article is reprinted in
his recent _Literate_Programming_ book, and he states it without
attribution. On the other hand, ``The Errors of TeX'' is also in
_Literate_Programming_, so who knows? We could ask William Safire
(explanation for our non-American cousins: Safire is a ``language
maven'' in the US), but I don't think he's really interested in CS.
-- Lee
------------------------------------------------------------------------
Lee Wittenberg |
Computer Science Department | But the age of chivalry is gone; that of
Kean College of New Jersey | sophisters, economists, and calculators
Union, NJ 07083 | has succeeded ...
USA |
| -- Edmund Burke (1793)
le...@pilot.njin.net |
------------------------------------------------------------------------
This discussion wouldn't be complete without mentioning Modula-3.
I had worked in Ada for 2 years before seeing Modula-3, and one of the
things that struck me is that they did everything that Ada set out to
do, only more cleanly. Modula-3 has an easily understandable object
model based on single inheritance.
To learn more, see Greg Nelson's book, `Systems Programming with Modula-3'
I have directed followups to comp.lang.modula3
Norman Ramsey
It was not my intention to argue that C++ was the BEST choice for my
project, only that it is not in all circumstances a bad language.
Supposing, however, that I want to use the very best language for my
next project, what should I choose, given the following list of
requirements:
* Efficiency is important. So it should be a compiled language.
* The compiler must be free.
* It must be easy to install (in, say, one day).
* The compiler (and, of course, the compiled programs) must run under
UNIX (SunOS and SiliconGraphics IRIX)
* I want to be able to package code and data together and use
more than one instance of the resulting class. (The latter point
probably rules out languages such as Modula 2.)
* Operator overloading. I want use the standard arithmetic operators
(+,-,*,/) for my objects (e.g. vectors, matrices).
Moreover, I like to overload the function call operator "()" for
expressing either evaluation of (mathematical) analytic functions
or composition of analytic functions. Example:
function f, g;
complex z;
function h = f(g); // h is going to be the composition of f and g
complex w = f(z); // w will be the value of f at the point z
* I need to interact with the floating point hardware (in order to set
the rounding mode).
* I need dynamical storage allocation.
* I occasionally need standard mathematical functions like log, sin, sqrt.
* I need good input/output facilities.
* I want to be able to pass command line arguments to my programs.
Virtual functions (object oriented programming in the strict sense), are
not indispensable for me, but nice to have.
I'll be grateful for any advice.
Andreas Stirnemann.
ASti...@maths.ex.ac.uk