Archive-Date: Sat, 01 May 1993 09:57:22 CDT
Sender: LP-Mgr@SHSU.edu
Date: Sat, 1 May 93 16:55:16 +0200
From: dak@POOL.Informatik.RWTH-Aachen.DE
Reply-To: LitProg@SHSU.edu
Message-ID: <9305011455.AA12739@messua>
To: LitProg@SHSU.edu
Subject: Duplicate modules/sections and good webbing style


I find that I use duplicate sections for code as well: mostly for
cases in switches. There I have no bad feelings about them.
================================================================================
Archive-Date: Sun, 02 May 1993 14:41:27 CDT
Sender: LP-Mgr@SHSU.edu
Date: Sun, 2 May 93 12:40:10 PDT
From: bgod@mailhost.cs.pdx.edu (fahad o arshad)
Reply-To: LitProg@SHSU.edu
Message-ID: <9305021940.AA07667@rigel.cs.pdx.edu>
To: LitProg@shsu.edu
Subject: Re: your mail


================================================================================
Archive-Date: Tue, 04 May 1993 02:52:27 CDT
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nqFOk-0005M9C@satyr.sylvan.com>
Date: Mon, 3 May 93 22:18 PDT
To: LitProg@SHSU.edu
Subject: Re: Experiences with litprog so far
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu

>>>>> "Marcus" == Marcus Speh <apple!x4u.desy.de!marcus> writes:

Kayvan> My second literate program was written in C++ using FWEB,
Kayvan> producing a few files and being split across several sources
Kayvan> with an attendant generic Makefile that I developed.

Marcus> Did you solve the problem (outlined in the FWEB-FAQ in Question [29])
Marcus> of presenting a _nice_ table of contents and a combined index which
Marcus> distinguishes between entries from different source files?

No. I started to look into it, but real work priorities intruded. I'm
now looking for my next consulting gig, so I'm either going to be real
buisy or NOT. 1/2 :-)

Marcus> The example I have in mind is Cameron Smith's hack of cwebmac.sty
Marcus> for the CWEB-KR-sample files. I know that John Krommes has put it in
Marcus> his long list of future enhancements (but it isnt contained in v1.30
Marcus> as far as I can see).

No, it's not in FWEB yet. I have converted the CWEB-KR-sample to FWEB
and doing the combined table of contents and index is on my list of
things to do (though I don't want to duplicate any work that John
Krommes has already put into this).

Marcus> I have CWEB,FWEB,NOWEB documents on the LitProg page for the World
Marcus> Wide Web. Somebody volunteers to write a few lines (HyperText ?) for
Marcus> C-No-Web along what I put up for the other LitProg tools? This mainly
Marcus> means one or more links to first-hand information and possibly some
Marcus> preprocessed examples.

Along these lines, and mostly for fun (though I use it all the time
now), I developed a generalized Makefile for FWEB/CWEB using NOWEB!!!
It allows me to write Makefile fragments (reminiscent of imake and its
"Imakefile") that produce the real Makefile for a WEB-based
application. I call it MetaMake.

If people are interested, I can send it to them (or to the list).

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Tue, 04 May 1993 03:11:19 CDT
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nqHxs-0005MpC@satyr.sylvan.com>
Date: Tue, 4 May 93 01:03 PDT
To: LitProg@SHSU.edu
Subject: beginner seeks module decomposition advice
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu

>>>>> "John" == John K Nicoll <apple!ohm.york.ac.uk!jkn> writes:

John> What has so far taken me the longest time to sort out
John> is the `art' of decomposing into modules. The FWEB (and other, as
John> far as I can see) manuals are silent on this issue - perhaps due
John> to its FORTRAN background. [...]

Marcus> [...] The choice of C, C++ or Fortran should not be an issue,
Marcus> IMO. The layout of your literate programs should rather follow
Marcus> general guidelines as sufficiently described in various
Marcus> articles and manuals. These imaginary 'guidelines' aren't just
Marcus> words: look into the source code of the CWEB and FWEB
Marcus> releases. Probably Levy/DEK have put parts of common.w into
Marcus> the User's Manual for this reason.

I completely agree with Marcus here. Literate Programs should still
follow good programming style. You can do good programming in
assembler and bad programming in C++, it's not linked to language.

The layout of my literate programs follow a mixture of intuition and
computer science. I have a sense of what I want to accomplish and I
start by writing the documentation chunk that introduces the program
and the motivation for the program.

After the introduction of the program, I use outlining and
old-fashioned structured programming techniques (with a smattering of
object oriented design) to decompose the problem. I write an overview
of the program using named modules (to be defined further inside the
WEB). As I get to each module, I write the documentation chunk and
write the code, and often find that there is an obvious next step that
makes the writing and the programming flow.

Just as in my plain C or C++ programs, I define functions when the set
of operations is generic enough to be used by other parts of the
program. I use named modules when I am trying to decompose a piece of
code that is best understood in overview (rather than overwhelm my
reader with details). This makes for an easy to write and easy to
understand program.

I also find that object oriented design mixes in very well with
literate programming (and takes care of the classic OO problem of
how you document your classes in a meaningful way).

Literate programmers would do well to keep Miller's 7 +/- 2 law in
mind as they weave and tangle their webs.

As an aside: a side effect of literate programming for me has been
that my programs take less time to write because I'm having so much
fun writing them!

Marcus> Altogether, in _my_ programs, the decomposition does not
Marcus> change essentially from one language to another. But again, I
Marcus> _do_ have a Fortran background, so maybe I'm missing the point
Marcus> here. And I wouldnt claim to do an 'art', either.

Marcus> Some comments on this last point by people with another background ?

Well, I come from a mostly C/Unix background and I found your comments
to be emminently reasonable. I don't think you're missing the point.

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Tue, 04 May 1993 03:26:17 CDT
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nqIIL-0005NGC@satyr.sylvan.com>
Date: Tue, 4 May 93 01:24 PDT
To: LitProg@SHSU.edu
Subject: Comments on ? starting, simplicity, ..?
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu

>>>>> "Bart" == Bart Childs <apple!cs.tamu.edu!bart> writes:

[... about web-mode ...]
Bart> In much the spirit of Norman's comment, I would really like to
Bart> get a lot of data back on how people use it before we add a lot
Bart> more functions.  Unless it is defeated, a journal file is
Bart> written that we get lots of data from.  However, most have come
Bart> from within our local community.  Indeed, many users don't use a
Bart> lot of the functions that I believe would be of great benefit.
Bart> However, isn't that the usual story?  I have seen a large number
Bart> of people who will move down 100 lines by 100 `down arrow's
Bart> rather than 5 `page down's!

I use web-mode to do outlining, jumping back and forth between
sections, reading WEB code as well as writing it, view section names
and jump to it, look at a variable in the index and go back and forth
between code and index, etc. The most common operation I use is the
automatic module name generation and selection mechanism.

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Tue, 04 May 1993 04:46:16 CDT
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nqJTe-0005MpC@satyr.sylvan.com>
Date: Tue, 4 May 93 02:39 PDT
To: LitProg@SHSU.edu
Subject: Duplicate modules/sections and good webbing style
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu

Lee Wittenberg makes some interesting points about duplicate code
sections.

Looking in my code, there are a few places where I use duplicate
(appended to) sections:

(*1*) Accumulating declarations. This is especially true in C (since I
can put declarations most anywhere in C++ and the need is lessened).

A typical example is:

    @ In |Print_Postscript_For_Board()|, we look at the Chess position and
    print the board using the Foresythe notation as implemented in
    Walker's chess font.

    @<Printing Routines@>=
    void Print_Postscript_For_Board( BOARD *my_board )
    {
	    @<Variables local to |Print_Postscript_For_Board()|@>@;

	    @<Prepare the postscript code@>@;
	    @<Output code to user-specified place, default |stdin|@>@;
    }

And then I can do something like this:

    @ To prepare the postscript code, we need to look at the structure
    elements in each cell of |my_board|. We use the |score| and
    |whose_move| variables in the code that follows.

    @<Variables local to |Print_Postscript_For_Board()|@>=
    int score;	/* this is part of the chess game listing */
    enum sides { WHITE, BLACK } whose_move;

    @ @<Prepare the postscript code@>=
    score = my_board[0].score;	/* the score for this snapshot */
    if (my_board[0].is_white)
	    whose_move = WHITE;
    else
	    whose_move = BLACK;

(*2*) Accumulating related functions. This mechanism makes it easy for
me to have *one* well-structured un-named section, rather than lots of
unnamed sections sprinkled throughout my code.

Example:

@ The {\tt foobarbletch} program needs to do many somewhat unrelated
things. Here is the overview of this program.

    @A @% FWEB un-named section (equivalent to @c in CWEB)
    @<Header Files@>@/
    @<Global Variables@>@/
    @<Chess Game Parsing Routines@>@/
    @<Postscript Output Routines@>@/
    @<The main program@>@/
    @<Utility Routines@>@/

And then @<Utility Routines@> becomes the catch-all bucket for any
useful function that I need to use elsewhere in the program.

(*3*) Un-tangling large switch statements. Various parsers and simple
state machines are best explained on a "case" by "case" basis.

    @ So now, we are ready to read and decompose our input file, producing
    the intermediate format that is easy for us to generate queries from.

    @<Parse input, producing balanced AVL tree@>=
    @<Read |token|, using lex@>@;
    switch(token)
    {
	    @<Appropriate actions based on value of |token|@>
    default:
	    /* We shouldn't get here!!! Ever!!! */
	    fprintf(stderr, "I'm DYING! I don't know about token: <%s>\n",
		    token.string);
	    abort();	/* maybe a core dump will do some good */
    }

    @ If we are handed a |QUERY| type, we need to perform the action that is
    specified by the |type| flag of |token|.

    @<Appropriate actions based on value of |token|@>=
    case QUERY:
	    run_actions(token, token.type);
	    break;

    @ If instead, we have an integer, push it onto our value stack so it
    can be used as an operand for later actions.

    @<Appropriate actions based on value of |token|@>=
    case INTEGER:
	    i = atoi(token.string); /* better add integer type to the lexer */
	    push_to_value_stack(i);
	    break;

That's pretty much it, I think. In general, I find that the pieces of
the named (multiply defined) section should be as modular and as
self-contained as possible. In the the switch statement, each case
block can be an independant, self-contained unit, and rearranging the
web should not cause it to break.

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Thu, 13 May 1993 12:57:09 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nthQA-0005QOC@satyr.sylvan.com>
Date: Thu, 13 May 93 10:50 PDT
To: LitProg@SHSU.edu
Subject: Anybody there?
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM

Is litprog just being quiet?

What are other litproggers doing out there?

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| !!!! NOTE: Looking for contracts. Hire me now and avoid the rush! :-) !!!! |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Thu, 13 May 1993 15:07:42 CST
Sender: LP-Mgr@SHSU.edu
From: sboyle@wv.MENTORG.COM (Sean Boyle x1542)
Reply-To: LitProg@SHSU.edu, sboyle@WV.MENTORG.COM
Date: Thu, 13 May 93 13:05:52 -0700
Message-ID: <9305132005.AA26564@porkface.mentorg.com>
To: LitProg@SHSU.edu
Subject: re: Anybody there?

Being a plebe to literate programming, I am still fiddling around.  I think
I've figured out that I like funnelWeb as I can use it for any arbitrary
language and it doesn't muck with it too bad.  I'm not fond of losing my tab
key, sigh...

Is there a review of the various systems out there somewhere?

I'd certainly like to see some good examples of literate programming so that
I can establish a discipline.  I've seen the bibliography listing and it
looks rather extensive.  It would be nice if some of the stuff was online
where I could get at it.

I suppose it is all new enough that there aren't a lot of hard and fast rules,
but there must be some scars that others *could* show me to save me from
some grief.  I appreciate the comments on style which the funnelWeb user's
guide points out, but I'd like more.

I suppose that the next battle I'm up against is a manager who believes that
all staff members should use Frame (I think it's supposed to be another
productivity tool...) so that we can share documents.  Unfortunately, this
system doesn't fit very well into that paradigm.  What is worse, my position
of having a tool which produces a document which in turn makes a code review
a breeze is somehow untenable.

            +------------------------+------------------------------+
            | sean_boyle@mentorg.com |  Mentor Graphics Corporation |
            | uunet!mntgfx!sboyle    |  8005 S.W. Boeckman Road     |
            |                        |  Wilsonville, OR 97070-7777  |
            |       "Intrinsically lazy, therefore creative"        |
            +------------------------+------------------------------+
================================================================================
Archive-Date: Thu, 13 May 1993 16:13:46 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 13 May 93 14:12:03 PDT
From: bos@mdd.comm.mot.com (Mary Bos)
Reply-To: LitProg@SHSU.edu, bos@MDD.COMM.MOT.COM
Message-ID: <9305132112.AA10527@foghorn.mdd.comm.mot.com>
To: LitProg@SHSU.edu, sboyle@wv.mentorg.com
Subject: re: Anybody there?

From Sean Boyle

> I suppose that the next battle I'm up against is a manager who believes that
> all staff members should use Frame (I think it's supposed to be another
> productivity tool...) so that we can share documents.  Unfortunately, this
> system doesn't fit very well into that paradigm.  What is worse, my position
> of having a tool which produces a document which in turn makes a code review
> a breeze is somehow untenable.
> 
 
I, too, work in the land of FrameMaker (and associated products) users.  I've heard
rumour Frame technologies is working on a conversion package to take TeX files,
but no dates or anything definite.  
I


================================================================================
Archive-Date: Thu, 13 May 1993 17:57:02 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0ntm74-0005M9C@satyr.sylvan.com>
Date: Thu, 13 May 93 15:50 PDT
To: sboyle@WV.MENTORG.COM
CC: LitProg@SHSU.edu
Subject: re: Anybody there?
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM

>>>>> "Sean" == Sean Boyle x1542 <apple!wv.MENTORG.COM!sboyle> writes:

Sean> Being a plebe to literate programming, I am still fiddling
Sean> around.  I think I've figured out that I like funnelWeb as I can
Sean> use it for any arbitrary language and it doesn't muck with it
Sean> too bad.  I'm not fond of losing my tab key, sigh...

What does funnelweb do to the sources? Is it like noweb (leaving it
all verbatim the way you typed it)? What about indexes or a table of
contents?

Sean> Is there a review of the various systems out there somewhere?

There have been several informal reviews by Marcus Seph, myself and
others. Look in the litprog archives. My present favorites are FWEB
for C/C++/TeX, and noweb for everything else (Perl scripts, Makefiles,
etc.)

With the final of FWEB 1.30 about to be released, I expect an even
better FWEB (in terms of robustness and support for multiple files,
etc.)

Sean> I'd certainly like to see some good examples of literate
Sean> programming so that I can establish a discipline.  I've seen the
Sean> bibliography listing and it looks rather extensive.  It would be
Sean> nice if some of the stuff was online where I could get at it.

There's Cameron Smith's multi-file CWEB example (KR-CWEB-SAMPLE or
something like that) that implements the calculator program from K&R
second edition. This is available from shsu.edu by anonymous ftp.

I'm working on an FWEB sample program in my copious spare time, see my
signature line ;-). My sample program will be made available when I
finish it. :-)

Sean> I suppose it is all new enough that there aren't a lot of hard
Sean> and fast rules, but there must be some scars that others *could*
Sean> show me to save me from some grief.  I appreciate the comments
Sean> on style which the funnelWeb user's guide points out, but I'd
Sean> like more.

Once again, check the archives. There was a discussion about this
recently with the subject: "beginner seeks module decomposition..."
If you don't have access to the archives, I can probably dig up the
relevant articles and send them to you.

Sean> I suppose that the next battle I'm up against is a manager who
Sean> believes that all staff members should use Frame (I think it's
Sean> supposed to be another productivity tool...) so that we can
Sean> share documents.

You may want to look into noweb and see how you can integrate it with
Frame. A lot of people would be interested in this (even though Frame
is far inferior to TeX in its abilities).

Sean> Unfortunately, this system doesn't fit very well into that
Sean> paradigm.  What is worse, my position of having a tool which
Sean> produces a document which in turn makes a code review a breeze
Sean> is somehow untenable.

How is it untenable? I've found that code reviews are a pleasure with
weaved output, versus being a boring and tedious exercise in
self-restraint ;-)

			---Kayvan
================================================================================
Archive-Date: Fri, 14 May 1993 02:06:23 CST
Sender: LP-Mgr@SHSU.edu
Date: 14 May 1993 02:54:15 -0400 (EDT)
From: j_mcarthur@BIX.com
Reply-To: LitProg@SHSU.edu, j_mcarthur@BIX.COM
Subject: What are other litproggers doing out there?
To: LitProg@SHSU.edu
Message-ID: <9305140254.memo.25954@BIX.com> Fri, 14 May 1993 02:54:15 -0400 (EDT)
Content-Transfer-Encoding: 7BIT

You asked, so I will tell you.

I work for a Typesetting company.  I do a lot of TeX.  So I have
been working on my personal port of TeX.  This now works and
passes the Trip test.  This is done using TopSpeed Pascal and
WEB.

To do this job I had to convert Tangle 4.1 and Weave 4.4 to the
TopSpeed Pascal.  One of the other WEB programs I work with is
DVIAPS.  This is a propritary program that we bought from ArborText.
It takes .dvi files and converts them to .icl files for our
Aps typesetters.  I have extensively re-written DVIAPS.  It now works
with Borland Pascal 7.0 using the Dos Extender provided by Borland.

I have also started work on re-writing MANGLE and MEAVE, the Modula 2
versions of Tangle and Weave.  Personally, I think Mangle and Meave
are totally useless as they currently stand.

One of the things I want to do is write a version of Tange/Weave to
work with PAL.  I do a LOT of database programming in Paradox.

/--------------------------------------------------------------\
|  Jeffrey McArthur             ATLIS Publishing               |
|  phone: (301) 210-6655        12001 Indian Creek Court       |
|  fax:   (301) 210-4999        Beltsville, MD  20705          |
|  EMAIL: j_mcarthur@bix.com                                   |
|                                                              |
| "The man who fights for his ideals is the man who is alive." |
|      Cervantes, author of Don Quixote                        |
\--------------------------------------------------------------/
================================================================================
Archive-Date: Fri, 14 May 1993 03:05:01 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305140803.AA15888@desire.grenoble.hp.com>
To: LitProg@SHSU.edu, sboyle@wv.MENTORG.COM
Subject: Re: Anybody there?
Date: Fri, 14 May 93 10:03:39 +0200
From: Dominique Dumont / GND <domi@desire.grenoble.hp.com>
Reply-To: LitProg@SHSU.edu, domi@DESIRE.GRENOBLE.HP.COM



In message <9305132005.AA26564@porkface.mentorg.com> you write:
> I suppose that the next battle I'm up against is a manager who believes that
> all staff members should use Frame (I think it's supposed to be another
> productivity tool...) so that we can share documents.  Unfortunately, this
> system doesn't fit very well into that paradigm.  What is worse, my position
> of having a tool which produces a document which in turn makes a code review
> a breeze is somehow untenable.
> 
Yep, I think I'm going to have the same problem. Most people think that if it's 
wysiwig it's better. But that heavily depends on the way you think and on the 
way you work. But now I'm preaching people who are already converted ...

BTW, if you want to know what I'm currently doing , I've quit hardware
devellopment and now I'm learning all I need to know about software 
(C++, smart methodologies [zut, how can I fit web in these ?], AIN,TMN ...)
Wish me luck I'm gonne be quite busy the next few months.


-----------------------------------------------------------------------------
                Name:          Dominique Dumont 
    ^^^^^^      Email:         Dominique_Dumont@grenoble.hp.com
   / O  O \     HP Desk:       Dominique DUMONT / HP6300/UM
  ( \____/ )    Address :      HEWLETT PACKARD, 38053 Grenoble Cedex 09 FRANCE
   \______/     Tel,Telnet:    (33) 76 62 57 24 - 7 779 5724
                Telex,Fax:     980 124 - (33) 76 62 53 20
-----------------------------------------------------------------------------
================================================================================
Archive-Date: Fri, 14 May 1993 05:03:43 CST
Sender: LP-Mgr@SHSU.edu
From: degas@ssiaq1.ing.univaq.it. (Giovanni De Gasperis)
Reply-To: LitProg@SHSU.edu, degas@SSIAQ1.ING.UNIVAQ.IT.
Message-ID: <9305140803.AA02032@ssiaq1.ing.univaq.it>
Subject: please unsubscribe
To: LitProg@shsu.edu, kayvan@satyr.sylvan.com
Date: Fri, 14 May 93 10:03:09 MET DST

Please unsubscribe me from the mailing list.

Thank you very much.

================================================================================
Archive-Date: Fri, 14 May 1993 06:24:03 CST
Sender: LP-Mgr@SHSU.edu
Date: Fri, 14 May 93 13:20:05 +0200
From: coates@spectro.jussieu.fr
Reply-To: LitProg@SHSU.edu, coates@SPECTRO.JUSSIEU.FR
Message-ID: <9305141120.AA16194@lutidine.spectro.jussieu.fr>
To: LitProg@shsu.edu
Subject: What am I doing?

Dear Litproggers,
	I don't know if I have mentioned what I use FunnelWeb for, but I might
anyway, since it seems a little different from what most do.  My aim is to
create 'all-in-1' papers, where imbedded in the text for the paper is the code
which generates the results.  So far, this is little different to what anyone
else does.  The main difference is that I then want the results of the programs
inserted into the paper.  To achieve this, a common route is
(i) FunnelWeb generates a Maple file for the calculations and a '.ptx' file
    for LaTeX without results (.ptx is my own choice, signifying pre-TeX).
(ii) The Maple file is run and generate a small Maple-loadable library of
     results
(iii) The .ptx file is then processed by Dougal Scott's texproc program, which
      he kindly sent to me.  This program searches a TeX file for a set of
      commands bracketted by special comment lines, runs the text through the
      selected program, and then replaces the text with the result of the
      program.  For me, for each set of results, Maple is run and the library
      of results loaded.  At the appropriate point in the file, the appropriate
      results are automatically converted by Maple into LaTeX by some routines I
      wrote (I didn't like the LaTeX code generated by the 'latex' function
      supplied with LaTeX).
(iv) Finally, I end up with a LaTeX file with all the source code and results
     together.

	Perhaps the main area in which the current languages don't support such
a process is it is assumed that the TeX code with the documentation is to remain
immutable, and so, in FunnelWeb at least, one can't use macros within the TeX
code itself, only within the code sections.  For my application, this is
sometimes a nuisance, because I want macros, but the TeX ones won't work until
too late in the process, and the FunnelWeb ones won't allow me to affect the
text.  So any change in macros to change the document involves *2* sets of
macros, one for FunnelWeb, and one for LaTeX.  That said, I am very happy with
FunnelWeb, and I can hardly complain at my using it for something that it wasn't
really designed for.
						Cheers,
								Tony.
________________________________________________________________________________
A.B.Coates (Tony)
Laboratoire de Spectroscopie Hertzienne de l'ENS
Universite Pierre et Marie Curie
Case 74, 4 place Jussieu		Email:	   coates@spectro.jussieu.fr
F-75252 Paris CEDEX 05			Telephone: +33 1 44 27 44 09
France					Fax:	   +33 1 44 27 38 45

"J'ai mes opinions.  L'universite a ses opinions.  L'intersection de ces deux ensembles est probablement vide."
"I have my opinions.  The university has its opinions.  The intersection of these two sets is probably empty."
________________________________________________________________________________
================================================================================
Archive-Date: Fri, 14 May 1993 14:29:34 CST
Sender: LP-Mgr@SHSU.edu
Date: Fri, 14 May 93 12:26:42 PDT
From: bos@mdd.comm.mot.com (Mary Bos)
Reply-To: LitProg@SHSU.edu, bos@MDD.COMM.MOT.COM
Message-ID: <9305141926.AA17337@foghorn.mdd.comm.mot.com>
To: LitProg@SHSU.edu, sboyle@wv.mentorg.com
Subject: re: Anybody there?

In a message dated 14 May 93 from Dominque Dumont

> 
> 
> In message <9305132005.AA26564@porkface.mentorg.com> you write:
> > I suppose that the next battle I'm up against is a manager who believes that
> > all staff members should use Frame (I think it's supposed to be another
> > productivity tool...) so that we can share documents.  Unfortunately, this
> > system doesn't fit very well into that paradigm.  What is worse, my position
> > of having a tool which produces a document which in turn makes a code review
> > a breeze is somehow untenable.
> > 
> Yep, I think I'm going to have the same problem. Most people think that if it's 
> wysiwig it's better. But that heavily depends on the way you think and on the 
> way you work. But now I'm preaching people who are already converted ...
> 


I just present a seminar on using LP to other fellow software engineering
students.  Most of my peers were hostile to LP and didn't like the idea
of code reviews using weave output.  Most of the reasons revolved around
not seeing the code directly, WYSIWIG, and the idea of writing english
and not compiler constructs. Now, if we are the current crop of SE's and
the future (?) crop of managers - LP still has a lot of persuading to do.
My peers might listen if the cost/benefits for LP (and WEB) were documented
versus the cost/benefits for the standard code construction (and documentation).

The positive side was WEB fits in well with the Object Oriented Programming
packaging on non-objected oriented compilers.  

Mary Bos
bos@mdd.comm.mot.com
bos@calvin.seattleu.edu

================================================================================
Archive-Date: Fri, 14 May 1993 15:37:43 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305142035.AA17173@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Fri, 14 May 1993 15:35:01 -0500
To: LitProg@shsu.edu, sboyle@wv.mentorg.com
Subject: re: Anybody there?

Sean Boyle writes:

  > Being a plebe to literate programming, I am still fiddling around.  I think
  > I've figured out that I like funnelWeb as I can use it for any arbitrary
  > language and it doesn't muck with it too bad.  I'm not fond of losing my tab
  > key, sigh...

You might want to try Noweb.  It's also language-independent, and in
addition, it allows you to specify tab stops (somewhat) with the -t
option.

  > Is there a review of the various systems out there somewhere?

Dunno. 

  > I'd certainly like to see some good examples of literate programming so that
  > I can establish a discipline.  I've seen the bibliography listing and it
  > looks rather extensive.  It would be nice if some of the stuff was online
  > where I could get at it.
  > 
  > I suppose it is all new enough that there aren't a lot of hard and fast rules,
  > but there must be some scars that others *could* show me to save me from
  > some grief.  I appreciate the comments on style which the funnelWeb user's
  > guide points out, but I'd like more.

Actually, one of the things I like about literate programming is
finding my own style guidelines.  I've found that I usually write a
first draft pretty much as ``stream of consciousness.''  Once I get it
working, I look at how lousy the structure is, and redo it (which
isn't as hard as it sounds, since most of the code chunks remain the
same; I only reorganize the explanations).

I think that recognizing good programming (or webbing) style requires
more reading than writing of programs.  In particular, I think this
comes from reading other peoples' programs (to which one has no
emotional attachment), and critiquing (sp?) them.  Some people can do
this for their own programs, but it's always easier to criticize someone
else's work.

I would be willing to compile an "Elements of Good Webbing Style"
list, and ``publish'' it via this discussion group, if people are
willing to send me (direct) lists of rules they've found useful.
Anyone who has such rules, please condense them to a short, simple
statement, and send them to me, along with a brief explanation of
how the rule is useful.  I'll compile them and post them to the list
in a week or two.  Also, let me know if you wish your contribution to
be anonymous, as I intend on crediting each contribution to its
original author (if you wish to be known as a contributor to the list,
but don't wish your name to be directly linked to your rules, we can
do that as well).

  > I suppose that the next battle I'm up against is a manager who believes that
  > all staff members should use Frame (I think it's supposed to be another
  > productivity tool...) so that we can share documents.  Unfortunately, this
  > system doesn't fit very well into that paradigm.  What is worse, my position
  > of having a tool which produces a document which in turn makes a code review
  > a breeze is somehow untenable.

I've got the same problem here (at Tipton Cole + Co., not UT Austin).
Two of us are producing lovely code using Noweb, but our boss and
another of our programmers are confirmed WYSIWYGers and can't be
bothered learning TeX.  The other programmers are interested in LP,
but are willing to go either way.  The boss is willing to do LP if he
can use Word for Windows, but is unwilling to see the advantages of
Noweb over WinWordWEB (automatic cross-referencing, RCS/PVCS version
control, freedom from Microsoft's whims, etc.).

I seem to recall someone mentioning that they were working on a WEB
system for Framemaker (or is that different than Frame -- it's hard to
keep things straight these days).  You may have to end up doing what I
did with Word for Windows -- developing your own Frame-based WEB
system.  WinWordWEB is primitive (Word's macro language doesn't permit
more), but it does the job, and it's better than no webbing at all.
A show of hands please:  How many of you out there have gotten so spoiled
by literate programming that you'll fight to the death rather than
program without your LP tools?  [Notice that my hand is raised.]

		-- Lee
================================================================================
Archive-Date: Fri, 14 May 1993 16:01:23 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305142058.AA18718@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Fri, 14 May 1993 15:58:37 -0500
To: LitProg@shsu.edu, j_mcarthur@bix.com
Subject: Re: What are other litproggers doing out there?

Jeffrey McArthur writes:

  > One of the things I want to do is write a version of Tange/Weave to
  > work with PAL.  I do a LOT of database programming in Paradox.

I spent a couple of months last year trying to use Spidery WEB to
generate a WEB system for PAL.  I gave it up when I discovered how
incredibly convoluted PAL syntax is.  Some keywords are reserved, some
aren't, and *so much* depends on context.  Spaces are significant in
some places but not in others, and it usually takes a bit of semantic
(in addition to syntactic) analysis to determine the appropriate
situation.  However, we do a lot of PAL programming here, and I am
loath to give up literate programming merely because of an intractable
language (see my previous reply to Sean Boyle's note).  I use Noweb
for all my PAL (and ObjectPAL) programming.  It works beautifully
(although the code is typeset as prettily as CWEB, FWEB, Spidery WEB,
etc.).  In fact, my boss is taking a notebook entitled "Literate
Programming in PAL and ObjectPAL" (containing about half a dozen 
Noweb PAL programs) to the Borland Conference in San Diego next week
in order to show around (and incite as much interest as possible in LP
techniques).  I am also trying to get the Paradox Informant to publish
one of my programs as an article.  Anyway, I know of 3 people
(including myself) who are doing literate programming in PAL.  Two of
us are using Noweb, and the third is using WinWordWEB (and has yet to
complete his first literate program, although I will admit what he has
so far looks pretty impressive).

I should also mention that, as far as I can tell, FunnelWEB is also a
worthwhile choice for PAL programming, although I've never actually
used it.  Noweb works perfectly for PAL, plus it allows me to use
LaTeX (I think FunnelWEB is restricted plain TeX, but I could be
wrong).  Noweb is available via anonymous ftp from bellcore.com (I
forget the directory).  I don't know where FunnelWEB is accessible
from, but I'm sure someone else on the net will know.

Hope this helps.

		-- Lee
================================================================================
Archive-Date: Fri, 14 May 1993 16:16:23 CST
Sender: LP-Mgr@SHSU.edu
Date: Fri, 14 May 93 21:03:14 GMT
Message-ID: <5884@apusapus.demon.co.uk>
From: tfj@apusapus.demon.co.uk (Trevor Jenkins)
Reply-To: LitProg@SHSU.edu, tfj@APUSAPUS.DEMON.CO.UK
To: LitProg@shsu.edu
CC: tfj@apusapus.demon.co.uk
Subject: Re: Anybody there?

In message <m0nthQA-0005QOC@satyr.sylvan.com> you write:
> Is litprog just being quiet?

Yes, sadly. :-(
 
> What are other litproggers doing out there? 

Trying to drum up more support by exchanging long mail messages with at
least one other UK netter interested in literate programming.

I'm also trying to screw up the courage and ask "Has anyone got a version
of WEB that accepts VAX BASIC?" I'd rather use C/Cweb but the customer (and
the recalcitrant boss) have mandated VAX BASIC. :-| Oh well I've asked it
anyway. :-)

Regards, Trevor.

---------------------------------------------------------------------------
Trevor Jenkins                                                Re: "deemed!"
134 Frankland Rd, Croxley Green, RICKMANSWORTH, WD3 3AU, England
email: tfj@apusapus.demon.co.uk   phone: +44 (0)923 776436     radio: G6AJG 

   "We need bigger and better books", Jimmy Tingle (Damned in the USA)
================================================================================
Archive-Date: Fri, 14 May 1993 23:46:21 CST
Sender: LP-Mgr@SHSU.edu
Date: Fri, 14 May 93 21:44:24 -0700
From: kevin@simd.stanford.edu (Kevin W. Rudd)
Reply-To: LitProg@SHSU.edu, kevin@SIMD.STANFORD.EDU
Message-ID: <9305150444.AA07300@simd.Stanford.EDU>

set litprog nomail
set litprog conceal
query litprog
================================================================================
Archive-Date: Sat, 15 May 1993 08:23:02 CST
Sender: LP-Mgr@SHSU.edu
Date: Sat, 15 May 1993 09:14:56 -0400 (EDT)
From: humberto@annexstein.csm.uc.EDU (Humberto Ortiz Zuazaga)
Reply-To: LitProg@SHSU.edu, humberto@ANNEXSTEIN.CSM.UC.EDU
Subject: Code reviews.
To: LitProg@SHSU.EDU, bos@MDD.COMM.MOT.COM
Message-ID: <9305151314.AA00341@annexstein.csm.uc.edu>
Content-Transfer-Encoding: 7BIT

   Date: Fri, 14 May 93 12:26:42 PDT
   From: bos@mdd.comm.mot.com (Mary Bos)

   In a message dated 14 May 93 from Dominque Dumont
   well into that paradigm.  What is worse, my position > > of having
   a tool which produces a document which in turn makes a code review
   > > a breeze is somehow untenable.  > > > Yep, I think I'm going to

   I just present a seminar on using LP to other fellow software
   engineering students.  Most of my peers were hostile to LP and
   didn't like the idea of code reviews using weave output.  Most of
   the reasons revolved around not seeing the code directly, WYSIWIG,
   and the idea of writing english and not compiler constructs. Now,
   if we are the current crop of SE's and the future (?) crop of
   managers - LP still has a lot of persuading to do.  My peers might
   listen if the cost/benefits for LP (and WEB) were documented versus
   the cost/benefits for the standard code construction (and
   documentation).

I think thay might have a point.  Woven code that uses \lnot and \neq
in the code takes some getting used to.  I think language constructs
should not be translated (or optionally translated).  In addition, it
takes a little time to get used to the out of order presentation of
the code, but with a little work on document structure, and by
presenting related sections close together the ordering can be a boon.

A poorly woven web is worse than a mediocre non-literate program, and
I was very poor at weaveing for a long time (and I already was good at
programming).  The added complexity does make for less understandable
programs until the idiom is mastered. (I still think I need some work
at web structure.)
--
Humberto Ortiz Zuazaga                                zuazaga@ucunix.san.uc.edu
================================================================================
Archive-Date: Sat, 15 May 1993 11:39:07 CST
Sender: LP-Mgr@SHSU.edu
Date: Sat, 15 May 93 18:35:21 +0200
From: coates@spectro.jussieu.fr
Reply-To: LitProg@SHSU.edu, coates@SPECTRO.JUSSIEU.FR
Message-ID: <9305151635.AA16391@lutidine.spectro.jussieu.fr>
To: LitProg@shsu.edu
Subject: FunnelWeb and LaTeX

Dear Litproggers,
	Lee Wittenberg writes
> ... stuff deleted ...
> I should also mention that, as far as I can tell, FunnelWEB is also a
> worthwhile choice for PAL programming, although I've never actually
> used it.  Noweb works perfectly for PAL, plus it allows me to use
> LaTeX (I think FunnelWEB is restricted plain TeX, but I could be
> wrong).  Noweb is available via anonymous ftp from bellcore.com (I
> forget the directory).  I don't know where FunnelWEB is accessible
> from, but I'm sure someone else on the net will know.
> 
> Hope this helps.
> 
> 		-- Lee
> 
	A few folks have commented about FunnelWeb and LaTeX.  As a FunnelWeb
user, let me point out that FunnelWeb was constructed with the idea of being
independent of the choice of formatting language, and so has it's own concept
of sections, subsections, etc.  Despite that, to date the only formatter it
supports is TeX.  However, it is possible to tell FunnelWeb (as I do) to forget
about it's own formatting conventions and just treat the text as a TeX file.
This is my preference; I find LaTeX's own sectioning comments fine for what I
want.  Yes, LaTeX, because once you tell FunnelWeb that you are writing in TeX,
you can write in LaTeX and just process the resulting text file in LaTeX.  Other
that a slight sensitivity about needing to place FunnelWeb macros after the 
\begin{document} line (I use the LaTeX 'article' style, but this is not at all
obligatory), there are no problems at all.
	For those who would rather use FunnelWeb's own sectioning commands with
LaTeX, I remember that in fact someone did write the appropriate code to
support this, but I can't remember who now (I don't use these sectioning
commands, so I don't use this code); can someone remind us who did the 
conversion, and where it is?
	In any case, I don't myself think that there is any bar to stop LaTeX
users working with FunnelWeb, though I would be interested in any opinions to
the contrary.
						Cheers,
								Tony.
________________________________________________________________________________
A.B.Coates (Tony)
Laboratoire de Spectroscopie Hertzienne de l'ENS
Universite Pierre et Marie Curie
Case 74, 4 place Jussieu		Email:	   coates@spectro.jussieu.fr
F-75252 Paris CEDEX 05			Telephone: +33 1 44 27 44 09
France					Fax:	   +33 1 44 27 38 45

"J'ai mes opinions.  L'universite a ses opinions.  L'intersection de ces deux ensembles est probablement vide."
"I have my opinions.  The university has its opinions.  The intersection of these two sets is probably empty."
________________________________________________________________________________
================================================================================
Archive-Date: Sat, 15 May 1993 13:10:55 CST
Sender: LP-Mgr@SHSU.edu
Date: Sat, 15 May 93 13:09:39 CDT
From: preston@cs.rice.edu (Preston Briggs)
Reply-To: LitProg@SHSU.edu, preston@CS.RICE.EDU
Message-ID: <9305151809.AA23107@dawn.cs.rice.edu>
To: LitProg@shsu.edu
Subject: code reviews


   I just present a seminar on using LP to other fellow software
   engineering students.  Most of my peers were hostile to LP and
   didn't like the idea of code reviews using weave output.

This is all wrong.
We've been doing walkthroughs with poorly-documented C, heavily
documented C, and woven cweb.  The cweb was far and away the best.
The indices and crossreferences are worth my weight in gold.  
Get 'em to actually try it try a walkthrough.

   if we are the current crop of SE's and the future (?) crop of
   managers - LP still has a lot of persuading to do.

This is fairly depressing.  If they worked for me, they'd be last
week's crop of SE's.  Not so much because they don't obey my every
whim, but because they don't recognize good ideas when they see them.

Preston Briggs

================================================================================
Archive-Date: Sat, 15 May 1993 14:08:22 CST
Sender: LP-Mgr@SHSU.edu
Subject: Modula-3
From: Paul Prescod <papresco@undergrad.math.uwaterloo.ca>
Reply-To: LitProg@SHSU.edu, papresco@UNDERGRAD.MATH.UWATERLOO.CA
To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Sat, 15 May 1993 15:06:42 -0400
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Message-ID: <93May15.150650edt.43222-3@undergrad.math.uwaterloo.ca>

Is there anyone out there doing literate programming for Modula-3?

What tools exist, and how well do they work?

================================================================================
Archive-Date: Sat, 15 May 1993 15:55:43 CST
Sender: LP-Mgr@SHSU.edu
Date: Sat, 15 May 93 16:54:27 -0400
From: kzhao@valhalla.cs.wright.edu (Kan Zhao)
Reply-To: LitProg@SHSU.edu, kzhao@VALHALLA.CS.WRIGHT.EDU
Message-ID: <9305152054.AA00289@valhalla.cs.wright.edu>
To: LitProg@shsu.edu, kayvan@satyr.sylvan.com
Subject: Please unsubscribe


Please unsubscribe me from the mailing list.

Thank you very much.

================================================================================
Archive-Date: Sun, 16 May 1993 08:37:48 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <199305161336.AA01945@yggdrasil>
To: LitProg@SHSU.edu
Subject: Re: Modula-3
Date: Sun, 16 May 1993 15:36:27 +0200
From: Matthias Ulrich Neeracher <neeri@iis.ee.ethz.ch>
Reply-To: LitProg@SHSU.edu, neeri@IIS.EE.ETHZ.CH

In message <93May15.150650edt.43222-3@undergrad.math.uwaterloo.ca>
Paul Prescod <papresco@undergrad.math.uwaterloo.ca> writes:
>Is there anyone out there doing literate programming for Modula-3?
>
>What tools exist, and how well do they work?

I have no actual experience with Modula-3, but if I were looking for tools, I
would consider either doing a Spidery Web grammar or a modification of MWEB.

Matthias

-----
Matthias Neeracher                                neeri@iis.ee.ethz.ch
   "One fine day in my odd past..." -- Pixies, _Planet of Sound_
================================================================================
Archive-Date: Sun, 16 May 1993 12:22:28 CST
Sender: LP-Mgr@SHSU.edu
From: Timothy Murphy <tim@maths.tcd.ie>
Reply-To: LitProg@SHSU.edu, tim@MATHS.TCD.IE
Subject: Re: Modula-3
To: LitProg@shsu.edu, neeri@iis.ee.ethz.ch
Date: Sun, 16 May 93 18:21:08 BST
Message-ID: <9305161821.aa17815@salmon.maths.tcd.ie>

> >Is there anyone out there doing literate programming for Modula-3?
> >What tools exist, and how well do they work?
> 
> I have no actual experience with Modula-3, but if I were looking for tools, I
> would consider either doing a Spidery Web grammar or a modification of MWEB.

It may be worth noting that OzTeX is written in Modula-2,
using a Modula-2 modification of tangle, I think.
(The sources are all available.)

Timothy Murphy  

e-mail: tim@maths.tcd.ie
tel: +353-1-2842366 (home/office)
     +353-1-7021507 (university)
fax: +353-1-2842295
s-mail: School of Mathematics, Trinity College, Dublin 2, Ireland

================================================================================
Archive-Date: Sun, 16 May 1993 17:20:47 CST
Sender: LP-Mgr@SHSU.edu
Date: Sun, 16 May 1993 18:17:40 -0400
From: ae1181t@stnfor.ae.ge.com (Osman F Buyukisik)
Reply-To: LitProg@SHSU.edu, ae1181t@STNFOR.AE.GE.COM
Message-ID: <9305162217.AA11151@stnfor.ae.ge.com>
To: LitProg@SHSU.edu, tfj@APUSAPUS.DEMON.CO.UK
Subject: Re: Anybody there?

Hi, use language independent tools :  funnelweb,noweb,nuweb,clip(msdos only).
If you like indices and automatic code prettyprinting and have time try spider
web but you may have to build one for basic (200-300 lines of specs). 
Osman
================================================================================
Archive-Date: Mon, 17 May 1993 10:58:19 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305171556.AA05726@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Mon, 17 May 1993 10:56:29 -0500
To: LitProg@shsu.edu, tfj@apusapus.demon.co.uk
Subject: Re: Anybody there?

Trevor Jenkins asks:

  > I'm also trying to screw up the courage and ask "Has anyone got a version
  > of WEB that accepts VAX BASIC?" I'd rather use C/Cweb but the customer (and
  > the recalcitrant boss) have mandated VAX BASIC. :-| Oh well I've asked it
  > anyway. :-)

You might want to try Noweb, or FunnelWEB, or one of the other language-
independent LP systems.  If you want beautifully typeset code, you
might want to build your own BasicWEAVE/TANGLE with Spidery WEB.  A
language like Basic, with a fairly simple syntax, should be relatively
easy to generate a Spidery grammar for. 

Noweb is available via anonymous ftp from bellcore.com (I forget the
directory), Spidery WEB from pip.shsu.edu (tex-archive/web/spiderweb).
I'm afraid I don't know where FunnelWEB is available.

		-- Lee

P.S. Noweb has a feature that is nice if your boss (and customer)
decide that you have to ``give up this literate programming
nonsense.''  It comes with a tool called ``nountangle'' that tangles
your code into a program (as the regular notangle does), but includes
your internal documentation as program comments in the appropriate
places.  This allows you to experiment with LP, and in Norman Ramsey's
words, ``If the experiment is unsatisfying, it is easy to abandon,
because {\tt notangle}'s output, unlike {\tt TANGLE}'s is readable.''

Personally, I'd try building a Spidery WEB first.  I'm partial to
the better typesetting of code in the language-dependent WEB
systems, but that's a matter of personal taste.
================================================================================
Archive-Date: Mon, 17 May 1993 11:13:08 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305171611.AA07274@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Mon, 17 May 1993 11:11:27 -0500
To: LitProg@shsu.edu, humberto@annexstein.csm.uc.edu
Subject: Re: Code reviews.

Humberto Ortiz Zuazaga writes:

  >    In a message dated 14 May 93 from Dominque Dumont
  >    well into that paradigm.  What is worse, my position > > of having
  >    a tool which produces a document which in turn makes a code review
  >    > > a breeze is somehow untenable.  > > > Yep, I think I'm going to
  > 
  >    I just present a seminar on using LP to other fellow software
  >    engineering students.  Most of my peers were hostile to LP and
  >    didn't like the idea of code reviews using weave output.  Most of
  >    the reasons revolved around not seeing the code directly, WYSIWIG,
  >    and the idea of writing english and not compiler constructs. Now,
  >    if we are the current crop of SE's and the future (?) crop of
  >    managers - LP still has a lot of persuading to do.  My peers might
  >    listen if the cost/benefits for LP (and WEB) were documented versus
  >    the cost/benefits for the standard code construction (and
  >    documentation).
  > 
  > I think thay might have a point.  Woven code that uses \lnot and \neq
  > in the code takes some getting used to.

I agree with Humberto's observation, but think it's interesting that \lnot and
\neq (and \land, and \lor, etc.) should ``take some getting used
to.''  After all, the corresponding symbols NOT/!, <>/!=,
AND/&&/.AND., etc. were chosen simply because early card and tape
punches did not provide the necessary standard mathematical symbols!
Take a look at the Algol-60 Revised Report, with its hardware,
reference, and publication languages, and notice that the publication
language allows things like Greek letters as identifiers and raised
exponents.  Note also that the REFERENCE language used the standard
mathematical symbols for \neq, \lor, \times (!), etc.  It was only in
the hardware language that concessions were made to the machine.

We've gotten into the habit of designing our languages around machine
needs rather than human needs.  I see literate programming as a way of
going back to the latter (I say ``going back'' primarily because of
Algol-60).  Let's start designing new programming languages with an
eye for human readability, using standard symbols that have been
around for hundreds (sometimes thousands) of years (e.g. \times and
\neq) rather than those that have been around for less than 50 (e.g. *
and <>).
[End of Tirade]

		-- Lee
================================================================================
Archive-Date: Mon, 17 May 1993 11:22:42 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305171620.AA08002@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Mon, 17 May 1993 11:20:24 -0500
To: LitProg@shsu.edu, preston@cs.rice.edu
Subject: Re: code reviews

Preston Briggs writes:

  >    if we are the current crop of SE's and the future (?) crop of
  >    managers - LP still has a lot of persuading to do.
  > 
  > This is fairly depressing.  If they worked for me, they'd be last
  > week's crop of SE's.  Not so much because they don't obey my every
  > whim, but because they don't recognize good ideas when they see them.

Unfortunately, most bosses are not as open as Preston (and the guy I'm
working for this year while on sabbatical).  It seems to come down to
my father's theory of middle management:  ``It's easier for a middle
manager to say `no,' because that way he (or she) can't get into
trouble with the higher-ups.  Saying `yes' involves sticking one's
neck out.''

		-- Lee
================================================================================
Archive-Date: Tue, 18 May 1993 00:06:41 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nvJpG-0005McC@satyr.sylvan.com>
Date: Mon, 17 May 93 22:02 PDT
To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Subject: re: Anybody there?
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM

>>>>> "Lee" == Lee Wittenberg <apple!cs.utexas.edu!leew> writes:

Lee> A show of hands please:  How many of you out there have gotten so spoiled
Lee> by literate programming that you'll fight to the death rather than
Lee> program without your LP tools?  [Notice that my hand is raised.]

My hand is raised too.

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Tue, 18 May 1993 10:33:17 CST
Sender: LP-Mgr@SHSU.edu
From: Joachim Schrod <schrod@iti.informatik.th-darmstadt.de>
Reply-To: LitProg@SHSU.edu, schrod@ITI.INFORMATIK.TH-DARMSTADT.DE
Message-ID: <9305181509.AA11078@spice.iti.informatik.th-darmstadt.de>
Subject: Re: What are other litproggers doing out there?
To: LitProg@SHSU.edu
Date: Tue, 18 May 1993 17:09:42 +0100 (MESZ)
Content-Type: text

Lee wrote:
> 
> Noweb is available via anonymous ftp from bellcore.com (I
> forget the directory).  I don't know where FunnelWEB is accessible
> from, but I'm sure someone else on the net will know.

Many of the literate programming systems are available from the
LitProg archive at Darmstadt:

	ftp.th-darmstadt.de [130.83.55.75]
	directory pub/programming/literate-programming

The usual TeX archives (eg, SHSU and Aston) carries also a lot.

-- 
Joachim

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Joachim Schrod			Email: schrod@iti.informatik.th-darmstadt.de
Computer Science Department
Technical University of Darmstadt, Germany
================================================================================
Archive-Date: Tue, 18 May 1993 12:21:59 CST
Sender: LP-Mgr@SHSU.edu
From: ericla@microsoft.com
Reply-To: LitProg@SHSU.edu, ericla@MICROSOFT.COM
Message-ID: <9305181718.AA15656@netmail.microsoft.com>
To: "netmail!LitProg@SHSU.edu, netmail!schrod@ITI.INFORMATIK.TH-DARMSTADT.DE~?"@microsoft.com
Subject: Re: What are other litproggers doing out there?
Date: Tue May 18 10:17:31 1993

================================================================================
Archive-Date: Tue, 18 May 1993 14:07:47 CST
Sender: LP-Mgr@SHSU.edu
Date: Tue, 18 May 93 11:45:17 CDT
From: infmx!grodecki@uunet.UU.NET (Don Grodecki)
Reply-To: LitProg@SHSU.edu, infmx!grodecki@UUNET.UU.NET
Message-ID: <9305181645.AA28203@lenexa.pd>
To: uunet!SHSU.edu!LitProg@uunet.UU.NET, uunet!CS.UTEXAS.EDU!leew@uunet.UU.NET
Subject: Re: code reviews


> From uunet!SHSU.edu!LP-Mgr Mon May 17 20:44:08 1993
> X-Listname: Literate Programming Discussion List <LitProg@SHSU.edu>
> Warnings-To: <>
> Sender: uunet!SHSU.edu!LP-Mgr
> From: uunet!cs.utexas.edu!leew (Lee Wittenberg)
> Reply-To: uunet!SHSU.edu!LitProg, uunet!CS.UTEXAS.EDU!leew
> Date: Mon, 17 May 1993 11:20:24 -0500
> To: LitProg@shsu.edu, preston@cs.rice.edu
> Subject: Re: code reviews
> 
> Preston Briggs writes:
> 
>   >    if we are the current crop of SE's and the future (?) crop of
>   >    managers - LP still has a lot of persuading to do.
>   > 
>   > This is fairly depressing.  If they worked for me, they'd be last
>   > week's crop of SE's.  Not so much because they don't obey my every
>   > whim, but because they don't recognize good ideas when they see them.
> 
> Unfortunately, most bosses are not as open as Preston (and the guy I'm
> working for this year while on sabbatical).  It seems to come down to
> my father's theory of middle management:  ``It's easier for a middle
> manager to say `no,' because that way he (or she) can't get into
> trouble with the higher-ups.  Saying `yes' involves sticking one's
> neck out.''
This is probably why the current theories are to "flatten" middle 
management out of the structure.  (PS: I am a middle manager who loves LitProg)
> 
> 		-- Lee
> 
================================================================================
Archive-Date: Wed, 19 May 1993 16:56:58 CST
Sender: LP-Mgr@SHSU.edu
Date: Wed, 19 May 93 16:49:02 CDT
From: preston@cs.rice.edu (Preston Briggs)
Reply-To: LitProg@SHSU.edu, preston@CS.RICE.EDU
Message-ID: <9305192149.AA04702@dawn.cs.rice.edu>
To: LitProg@shsu.edu
Subject: language-independent indices

One of the winning features of web and cweb (and perhaps other
systems) is their automatically-constructed indices of source code
identifiers.  It's a great convenience, during code maintanence and
code walkthroughs, to be able to find where a procedure is defined and
used.

Unfortunately, language-independent web systems (Funnelweb, noweb,
nuweb, others?) don't build these indices automatically because they
can't know what an identifier looks like in each particular language.
For example, x_1 is a 3-letter id in C, but an expression in TeX.
+ is a valid id in some scheme systems.

As an experiment, I've modified nuweb to support semi-automatic index
construction. Basically, the programmer specifies each entry as it's
defined and nuweb finds all the other occurences (the references).

For example, if I've got a very short nuweb file
---------------------
Here's scrap 1
@o test
@{We are going to look for occurences of "he", "she", "his", and
"hers".  I'll mark them as defined in this scrap and let nuweb find
references to them in any other scraps. They're listed at the end of
the scrap, separated by whitespace.
@| he she his hers @}

And scrap 2
@o test
@{This is a test.
For the next sixty seconds...
@}

And scrap 3
@o test
@{She sells seashells by the seashore.
@}
---------------------
We'll get index entries

	he	1, 2, 3.
	hers	1.
	his	1, 2.
	she	1, 3.

(where the 1's are underlined).

I collect all the index entries during the first pass, while
accumulating all the scraps, and record their definition points.  Then
I build a finite automata that can search for all of the entries
simultaneously.  Finally, I use it to search through each scrap in
sequence, recording all occurences of each entry as a use (but
avoiding duplicates).  The string searcher is described in

	Efficient String Matching: An Aid to Bibliographic Search
	Aho and Corasick
	CACM, June 1975

There are advantages over the approach used by web and cweb, primarily
in that the index is much more controlled.  I find it useful to
include procedures, typedefs, and global variables.  I don't care so
much about the hordes of local variables I use everywhere.

Of course, simply using string equality isn't perfect.
If we're looking for the entry "arena", any occurence of
"arena_getmem" will also be flagged.  So far, I'm not too concerned
about these cases; perhaps further experience will suggest
alternatives.

Preston Briggs
================================================================================
Archive-Date: Thu, 20 May 1993 05:30:38 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 93 12:26:48 +0200
From: coates@spectro.jussieu.fr
Reply-To: LitProg@SHSU.edu, coates@SPECTRO.JUSSIEU.FR
Message-ID: <9305201026.AA19629@lutidine.spectro.jussieu.fr>
To: LitProg@shsu.edu, preston@cs.rice.edu
Subject: Re: language-independent indices

Preston Briggs writes:

> One of the winning features of web and cweb (and perhaps other
> systems) is their automatically-constructed indices of source code
> identifiers.  It's a great convenience, during code maintanence and
> code walkthroughs, to be able to find where a procedure is defined and
> used.
> 
> Unfortunately, language-independent web systems (Funnelweb, noweb,
> nuweb, others?) don't build these indices automatically because they
> can't know what an identifier looks like in each particular language.
> For example, x_1 is a 3-letter id in C, but an expression in TeX.
> + is a valid id in some scheme systems.

I can't comment about other WEB systems, but for FunnelWeb users, global
variables and the like can by marked by enclosing each of them in it's own 
macro, which FunnelWeb then indexes.  This may not be the most elegant solution,
but if the number of global variables, procedures, or whatever is not too large,
it should be perfectly sufficient.  Anyway, just a quick thought.
	
						Cheers,
								Tony.
________________________________________________________________________________
A.B.Coates (Tony)
Laboratoire de Spectroscopie Hertzienne de l'ENS
Universite Pierre et Marie Curie
Case 74, 4 place Jussieu		Email:	   coates@spectro.jussieu.fr
F-75252 Paris CEDEX 05			Telephone: +33 1 44 27 44 09
France					Fax:	   +33 1 44 27 38 45

"J'ai mes opinions.  L'universite a ses opinions.  L'intersection de ces deux ensembles est probablement vide."
"I have my opinions.  The university has its opinions.  The intersection of these two sets is probably empty."
________________________________________________________________________________
================================================================================
Archive-Date: Thu, 20 May 1993 07:16:05 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 1993 22:14:46 +1000
From: Richard Walker <Richard.Walker@cs.anu.edu.au>
Reply-To: LitProg@SHSU.edu, Richard.Walker@CS.ANU.EDU.AU
Message-ID: <199305201214.AA14331@barnard.anu.edu.au>
To: LitProg@SHSU.edu
Subject: Re: language-independent indices

Tony writes:

>I can't comment about other WEB systems, but for FunnelWeb users,
>global variables and the like can by marked by enclosing each of
>them in it's own macro, which FunnelWeb then indexes.  This may
>not be the most elegant solution, but if the number of global
>variables, procedures, or whatever is not too large, it should be
>perfectly sufficient.  Anyway, just a quick thought. 
	
Yep, that's right.  I have made a quick modification to FunnelWeb
and some changes to my LaTeX macros to do indexing of sections
and files - it works quite well.  I'm a bit reluctant to release
it as yet as I'm still working out if it's a good idea (plus
I'm not sure of copyright, etc.).

Richard.
================================================================================
Archive-Date: Thu, 20 May 1993 08:23:02 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 1993 09:19:51 -0400
From: ae1181t@stnfor.ae.ge.com (Osman F Buyukisik)
Reply-To: LitProg@SHSU.edu, ae1181t@STNFOR.AE.GE.COM
Message-ID: <9305201319.AA10749@stnfor.ae.ge.com>
To: litprog@shsu.edu
Subject: language-independent indices

I think to cover all the bases will be difficult at best. The example
Preson gave "arena_getmem" being flagged by an index entry for ``arena''
is a good one : in C arena_getmem is an identifier while in gnu smalltalk
it is an assignment statement like arena := getmem! It looks like using
LaTeX and  user interaction is necessary for the language-independent 
``WEB''s. However, I think nuweb's method of index collecting is better
than the one suggested for the funnelweb users (namely use macros for
each index entry); you are not cluttered with a macro for every global
variable! Even with the new additions, the nuweb users' manual is still
3-4 pages with only a 6 or so commands to learn, and one program that
both tangles and weaves, and uses LaTeX. Looks like a winner to me!
Osman
================================================================================
Archive-Date: Thu, 20 May 1993 09:51:08 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 93 09:49:57 CDT
From: preston@cs.rice.edu (Preston Briggs)
Reply-To: LitProg@SHSU.edu, preston@CS.RICE.EDU
Message-ID: <9305201449.AA07297@dawn.cs.rice.edu>
To: LitProg@shsu.edu
Subject: identifiers indices

Tony Coates suggested wrapping each global variable declaration
(function declaration, type decalration, ...) in it's own private
macro as a way to achieve an index of identifiers.
(in the context of FunnelWeb).

I don't much like this because I'll need to use the macro name
everywhere instead of the variable/procedure/type name.
That is, I don't have to use the macro name; but if I use the variable
name, it won't appear in the index.

@<Seems@> @<like@> @<a@> @<lot@> @<of@> @<overhead@> @<to@> @<me@>

Preston Briggs
================================================================================
Archive-Date: Thu, 20 May 1993 10:11:53 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 93 16:10:53 +0200
From: coates@spectro.jussieu.fr
Reply-To: LitProg@SHSU.edu, coates@SPECTRO.JUSSIEU.FR
Message-ID: <9305201410.AA21056@lutidine.spectro.jussieu.fr>
To: LitProg@shsu.edu, ae1181t@stnfor.ae.ge.com
Subject: Re: language-independent indices

Osman F Buyukisik writes

> I think to cover all the bases will be difficult at best. The example
> Preson gave "arena_getmem" being flagged by an index entry for ``arena''
> is a good one : in C arena_getmem is an identifier while in gnu smalltalk
> it is an assignment statement like arena := getmem! It looks like using
> LaTeX and  user interaction is necessary for the language-independent 
> ``WEB''s. However, I think nuweb's method of index collecting is better
> than the one suggested for the funnelweb users (namely use macros for
> each index entry); you are not cluttered with a macro for every global
> variable! Even with the new additions, the nuweb users' manual is still
> 3-4 pages with only a 6 or so commands to learn, and one program that
> both tangles and weaves, and uses LaTeX. Looks like a winner to me!
> Osman
> 

With regard to my suggestion that FunnelWeb users could use a macro for each
index entry, I did mention that it would work for a *not too many* global 
variables or procedures.  If you use hundreds of global variables (naughty you!)
then this method would almost certainly be a nuisance (essentially 4 extra
keystrokes for each identifier, plus you may not like all the cross-references
in the middle of the program output).

	In any case, I wasn't meaning to take anything away from nuweb, nor
suggesting that FunnelWeb macros were equivalent.  I was just pointing out the
quickest alternative I could think of for FW users, and noting that in some
cases it may be sufficient at the lower end of things.

						Cheers,
								Tony.
________________________________________________________________________________
A.B.Coates (Tony)
Laboratoire de Spectroscopie Hertzienne de l'ENS
Universite Pierre et Marie Curie
Case 74, 4 place Jussieu		Email:	   coates@spectro.jussieu.fr
F-75252 Paris CEDEX 05			Telephone: +33 1 44 27 44 09
France					Fax:	   +33 1 44 27 38 45

"J'ai mes opinions.  L'universite a ses opinions.  L'intersection de ces deux ensembles est probablement vide."
"I have my opinions.  The university has its opinions.  The intersection of these two sets is probably empty."
________________________________________________________________________________
================================================================================
Archive-Date: Thu, 20 May 1993 13:39:12 CST
Sender: LP-Mgr@SHSU.edu
From: David Thompson <dthompson@coe2.coe.ttu.edu>
Reply-To: LitProg@SHSU.edu, dthompson@COE2.COE.TTU.EDU
To: LitProg <litprog@shsu.edu>
CC: David Thompson <dthompson@coe2.coe.ttu.edu>
Subject: RE: language-independent indices
Date: Thu, 20 May 93 13:36:00 PDT
Message-ID: <2BFBEBB3@cpds01.coe.ttu.edu>



Osman writes:

> However, I think nuweb's method of index collecting is better than the one 

> suggested for the funnelweb users (namely use macros for each index 
entry);
> you are not cluttered with a macro for every global variable!

I've seen nuweb mentioned on the mailing list several times.  However, I 
don't recall a source for the software.  Where is this software available 
and what platforms does it run on?

 -=d

============================================================================  
==============
David B. Thompson                             internet: wqdbt@ttacs1.ttu.edu
Assistant Professor of Civil Engineering      internet: 
dthompson@coe2.coe.ttu.edu
Texas Tech University                         internet: 
thompson@sun1.coe.ttu.edu
P.O. Box 41023
Lubbock, Texas 79409-1023
USA
============================================================================  
==============

================================================================================
Archive-Date: Thu, 20 May 1993 15:35:49 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 1993 16:32:02 -0400
From: ae1181t@stnfor.ae.ge.com (Osman F Buyukisik)
Reply-To: LitProg@SHSU.edu, ae1181t@STNFOR.AE.GE.COM
Message-ID: <9305202032.AA11726@stnfor.ae.ge.com>
To: LitProg@SHSU.edu, dthompson@coe2.coe.ttu.edu.ae.ge.com.ae.ge.com
Subject: RE: language-independent indices

I obtained nuweb from the author Preston Briggs (preston@cs.rice.edu).
It came as a shar file. Runs on unix (I  have Hp 710 hpux 8.07), dos
using djgpp (port of gcc to dos). I did not have to make any changes to 
run it under dos, so probably very portable if you have a form of gcc.
You also need LaTeX to get anything out of it. 
================================================================================
Archive-Date: Thu, 20 May 1993 16:55:35 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 20 May 93 16:54:07 CDT
From: preston@cs.rice.edu (Preston Briggs)
Reply-To: LitProg@SHSU.edu, preston@CS.RICE.EDU
Message-ID: <9305202154.AA12664@dawn.cs.rice.edu>
To: LitProg@shsu.edu, dthompson@coe2.coe.ttu.edu
Subject: RE: language-independent indices

 David Thompson asked about nuweb.
I give it away to anyone who asks.
I'm still hacking on it, mostly trying to document the code,
so I haven't yet put it out for ftp at shsu.

It's written in C.  I run it on Unix and AIX.
Needs latex (based on TeX version 3.0 or up).
Probably an easy port to other machines, but I haven't tried.

If you'd like an early release, send me a note

Preston Briggs
================================================================================
Archive-Date: Mon, 24 May 1993 13:01:24 CST
Sender: LP-Mgr@SHSU.edu
Date: Mon, 24 May 93 19:59:52 +0200
From: marcus@x4u.desy.de (Marcus Speh)
Reply-To: LitProg@SHSU.edu, marcus@X4U.DESY.DE
Message-ID: <9305241759.AA29682@x4u.desy.de>
To: Literate Programmers <litprog@shsu.edu>
Subject: LitProg on the World Wide Web [regular posting]

[[This is a regular posting to LitProg mailing list and Comp/TeX discussion
  groups, formatted for Emacs outline mode. Cut here and copy rest to file.]]

-----------------------------------------------------------------------------
* Literate Programming on the World Wide Web
-----------------------------------------------------------------------------
   FYI, there is a wealth of information on Literate Programming,
   the art of structured programming and documentation [especially
   using WEB-like systems with TeX formatting] available on the
   World Wide Web [WWW], a distributed HyperText system, a network
   of documents connected by links which can be activated electronically.
   Examples for LitProg environments are WEB for Pascal (DEK), CWEB for C/C++
   (Levy/Knuth), FWEB for C/C++/Fortran/ratfor/TeX (Krommes)...and many more.
-----------------------------------------------------------------------------
* How to get to the Web
-----------------------------------------------------------------------------
   If you have a WWW browser up and running, try going to

		        http://info.desy.de:80/

   (this brings you to the DESY home page), and look for "User Documents"
   in the panel which appears. The precise URL is

	   http://info.desy.de:80/gnu/ftp/pub/www/projects/LitProg.html

   If you have no clue what WWW is, you can go over the Internet with

        	telnet info.cern.ch

   which brings you to the WWW Home Page at CERN. You are now using the
   simple line mode browser. To move around the Web, enter the numbers
   given after an item. To go to the Literate Programming documents, enter

	go http://info.desy.de:80/gnu/ftp/pub/www/projects/LitProg.html

   This is what you should see now:
-----------------------------------------------------------------------------
* What you will see here
-----------------------------------------------------------------------------
			 LITERATE PROGRAMMING

Getting Started[1]
   A first look into Literate Programming with WEB 
Editing 
   GNU Emacs mode for WEB programming: Sources[2] and 
   Manual[3] (PostScript) 
Tools[4] 
   List of common, freely available Literate Programming
   environments 
Examples[5] 
   Literate Programming archives and selected examples 
LitProg Library[6]
   George D. Greenwade's Literate Programming Library at
   Niord.shsu.edu 
FAQs[7]
   Lists of Frequently Asked Questions for WEB systems 
Further Reading 
   Nelson Beebe's Literate Programming bibliography at
   ftp.math.utah.edu in directory /pub/tex/bib[8] (files litprog.*) 
HyperLitProg[9]
   Literate Programming using HyperText[10] Techniques 
OO-LitProg[11]
   Thoughts on Object-Oriented[12] Literate Programming 
LITPROG Mailing List[13]
   Information on the Literate Programming Mailing List 


 [[Now you can continue climbing down the documentation tree by
   entering numbers 1-13 and follow your own interests]]
-----------------------------------------------------------------------------
* More on Browsing the Web
-----------------------------------------------------------------------------
   The by far nicest way of "browsing" through WWW uses the X-Terminal
   based tool "XMosaic". Binaries for many platforms (ready for use)
   and sources are available via anonymous FTP from
   ftp.ncsa.uiuc.edu in directory Web/xmosaic.
     The general FTP repository for browser software is info.cern.ch
  (including a hypertext browser/editor for NeXTStep 3.0)
-----------------------------------------------------------------------------
* Contact for Further Information
-----------------------------------------------------------------------------
   Please feel free to contact me for questions, suggestions and further
   contributions, or just to tell me whether you found this information
   useful in any way. For questions related to WWW, consult the WWW-FAQ:
   Its most recent version is available via anonymous FTP on rtfm.mit.edu
   in /pub/usenet/news.answers/www-faq , or on WWW at
   http://www.vuw.ac.nz:80/overseas/www-faq.html
   Enjoy.

  Marcus Speh
  E-mail:  INTERnet: marcus@x4u.desy.de
	   BITnet:   i02msp@dhhdesy3
	   DECnet:   13313::speh
-----------------------------------------------------------------------------
Local Variables:
mode: outline
outline-regexp: "^\*"
eval: (show-all)
End:

================================================================================
Archive-Date: Wed, 26 May 1993 04:37:54 CST
Sender: LP-Mgr@SHSU.edu
Date: Wed, 26 May 1993 11:34 +0000 (GMT)
From: "Eric W. van Ammers, LUW, tel: (+31)8370-83356" <AMMERS@RCL.WAU.NL>
Reply-To: LitProg@SHSU.edu, AMMERS@RCL.WAU.NL
Subject: Re: Anybody there?
To: LitProg@SHSU.edu
Message-ID: <01GYMOJF4HQ88ZEZR8@RCL.WAU.NL>
Content-Transfer-Encoding: 7BIT

On 14-MAY-1993 Lee wrote

>A show of hands please:  How many of you out there have gotten so spoiled
>by literate programming that you'll fight to the death rather than
>program without your LP tools?  [Notice that my hand is raised.]

Although a bit late, I certainly would like to raise my hand. I have been
using the basic technique for many years and for me it is the most
convincing presentation of a program.
    The big problem I face, and all of us LP-ers expereince the same, is that
we cannot bring to words where exactly is the power of the LP paradigm. I have
several times before argued that we should discuss thIs sort of "phylosophical"
issues on the net. Once again I ask to all of you: Can we somehow make 
explicite the power of LP. Maybe this will finally convince managers to

						Eric
============================================================================
Eric W. van Ammers
Department of Computer Science
Wageningen Agricultural University
Dreijenplein 2				E-mail:	ammers@rcl.wau.nl
6703 HB  Wageningen			voice:	+31 (0)8370 83356/84154
The Netherlands				fax:	+31 (0)8370 84731
============================================================================

================================================================================
Archive-Date: Wed, 26 May 1993 16:43:50 CST
Sender: LP-Mgr@SHSU.edu
From: David Thompson <dthompson@coe2.coe.ttu.edu>
Reply-To: LitProg@SHSU.edu, dthompson@COE2.COE.TTU.EDU
To: LitProg <litprog@shsu.edu>
CC: David Thompson <dthompson@coe2.coe.ttu.edu>
Subject: Help for LitProg FAQ
Date: Wed, 26 May 93 16:37:00 PDT
Message-ID: <2C03FF46@cpds01.coe.ttu.edu>



Finally, my semester is over and teaching duties are finished! <yes!!!>  
I've redirected some of my attention to working on a FAQ I promised a few 
months ago.  It's time for some input from developers of literate 
programming tools.

If you are a developer or maintainer of a literate programming tool, please 
email me (see addresses below) the following information for inclusion in 
the FAQ.

* Name of tool.
* Name and email address of developer or maintainer.
* Hardware and operating system(s) supported.
* Software supported (programming languages/text formatters).
* Pointer to a location where the software can be retrieved via anonymous 
ftp.
* Pointer to a location where a brief document (readme) can be retrieved via 
anonymous ftp.
* A brief description of the tool.  In particular, what does it do, what are 
its strengths,
  what are it's weaknesses, and what future directions development is 
expected to take.
* A description of how support for the software is handled.  (Email, 
snailmail, none, ?)

Please, please, please email this information directly to me.  Don't post it 
on the mailing list.  (Of course, the previous statement was unnecessary. 
;-)

Thanks for your support.

 -=d

P.S.  I have a skeleton prepared.  All I need is the above text and a few 
hours to get something together.

============================================================================  
==============
David B. Thompson                             internet: wqdbt@ttacs1.ttu.edu
Assistant Professor of Civil Engineering      internet: 
dthompson@coe2.coe.ttu.edu
Texas Tech University                         internet: 
thompson@sun1.coe.ttu.edu
P.O. Box 41023
Lubbock, Texas 79409-1023
USA
============================================================================  
==============
================================================================================
Archive-Date: Wed, 26 May 1993 17:16:48 CST
Sender: LP-Mgr@SHSU.edu
From: ralexand@mason1.gmu.edu (Roger T Alexander)
Reply-To: LitProg@SHSU.edu, ralexand@MASON1.GMU.EDU
Message-ID: <9305262214.AA19414@mason1.gmu.edu>
Subject: CWEB 3.0
To: litprog@shsu.edu
Date: Wed, 26 May 1993 18:14:51 -0400 (EDT)
Content-Type: text

Does anyone know when cweb 3.0 will be out ?

Roger Alexander.
rtalexander@acm.org

================================================================================
Archive-Date: Wed, 26 May 1993 17:18:51 CST
Sender: LP-Mgr@SHSU.edu
From: ralexand@mason1.gmu.edu (Roger T Alexander)
Reply-To: LitProg@SHSU.edu, ralexand@MASON1.GMU.EDU
Message-ID: <9305262216.AA19441@mason1.gmu.edu>
Subject: Scientific Word
To: litprog@shsu.edu
Date: Wed, 26 May 1993 18:16:12 -0400 (EDT)
Content-Type: text

Does anyone know the phone number/address of the vendor for the TeX word
processing package called "Scientific Word" ?

Thanks,

Roger Alexander (rtalexander@acm.org)

================================================================================
Archive-Date: Wed, 26 May 1993 18:21:48 CST
Sender: LP-Mgr@SHSU.edu
Date: Wed, 26 May 93 17:17:20 MDT
From: "Nelson H. F. Beebe" <beebe@math.utah.edu>
Reply-To: LitProg@SHSU.edu, beebe@MATH.UTAH.EDU
To: ralexand@mason1.gmu.edu (Roger T Alexander)
CC: beebe@math.utah.edu, LitProg@SHSU.edu
Subject: Scientific Word
Message-ID: <CMM.0.90.4.738458221.beebe@plot79.math.utah.edu>

Scientific Word is distributed by 

	ARSoftware
	8201 Corporate Driver, Suite 1110
	Landover, MD 20785
	Tel: (310) 459-3773, (800) 257-0073
	FAX: (301) 459-3776


========================================================================
Nelson H. F. Beebe                      Tel: +1 801 581 5254
Center for Scientific Computing         FAX: +1 801 581 4148
Department of Mathematics, 105 JWB      Internet: beebe@math.utah.edu
University of Utah
Salt Lake City, UT 84112, USA
========================================================================
================================================================================
Archive-Date: Wed, 26 May 1993 19:20:40 CST
Sender: LP-Mgr@SHSU.edu
Date: 26 May 93 16:27 -0700
From: Gerry Rohling <rohling@mech.ubc.ca>
Reply-To: LitProg@SHSU.edu, rohling@MECH.UBC.CA
To: LitProg@shsu.edu, ralexand@mason1.gmu.edu
Message-ID: <723*rohling@mech.ubc.ca>
Subject: Scientific Word

Hi,
	The vendor for Scientific Word is ARSoftware. I talked to
a Mr. Sat Want Khalsa, who is the manager of marketing. His number
is (301)459-3773 (Fax: (301)459-3776)

Hope this helps.

Gerry
================================================================================
Archive-Date: Thu, 27 May 1993 02:22:50 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 27 May 93 09:16:49 MDT
From: Zdenek Wagner <WAGNER%CSEARN.BITNET@SHSU.edu>
Reply-To: LitProg@SHSU.edu, WAGNER%CSEARN.BITNET@SHSU.EDU
Subject: formatting examples in CWEB
To: Literate Progaramming list <litprog@SHSU.edu>


Dear LitProggers,
I am writing a C++ pure virtual class in CWEB. The class is intended to be
used by other programmers even those who do not know WEB (they will just get
the tangled code and printed documentation)and also those who are not very
familiar with object oriented programming. Therefore I should supply good
information how they will derive their own classes.

And now comes the question. The WEB file should contain examples which should
be formatted in the similar way as the C-part. I do not like to study the
macros from ``cwebmac.tex'' and dothe formatting by hand. I therefore need
some trick to put blocks which will be ignored by tangle and formatted like C
by weave. The trick with

@(nul@>=...

will not work because I intend to leave some modules unresolved. Imagine the
part of the example:

if (errorCode != 0) {
 @<Display error message@>@;
}

I will not specify how to display the error message because each programmer
has his own way for managing error messages or even his own libraries. It is
even more evident on data inputand output of results which does not depend
upon the properties of the base class but on the nature of the problem.

Is there a solution in CWEB?

Thanks in advance for your answers.

                                                ,
,~~~/        /`               /     /|      /~~~
   /        /           |_/  /__/  ' |     /
  /     /~~/ /~~/ /~~/ /~~/ /\       | /| / /~~/ /~~/ /~~/ /~~/ /~~~
 /   , /  / /~~~ /  / /~~~ /  \      |/ |/ /  /_/  / /  / /~~~ /
 ~~~~  ~~~  ~~~ '  '  ~~~ '    `     '  '  ~~~  ~~/ '  '  ~~~ '
                              Zdenek Wagner______/

Some gateway between me and you may garble backslash. It will appear
on your screen as ã
================================================================================
Archive-Date: Thu, 27 May 1993 09:02:14 CST
Sender: LP-Mgr@SHSU.edu
Date: Thu, 27 May 93 10:00:36 -0400
From: figuei@lutece.rutgers.edu (Francisco Figueirido)
Message-ID: <9305271400.AA26218@lutece.rutgers.edu>
To: LitProg@SHSU.edu, WAGNER%CSEARN.BITNET@SHSU.EDU
CC: litprog@SHSU.edu
Subject: Re: formatting examples in CWEB
Reply-To: LitProg@SHSU.edu, figuei@lutece.rutgers.edu

Zdenek Wagner writes:

> And now comes the question. The WEB file should contain examples which should
> be formatted in the similar way as the C-part. I do not like to study the
> macros from ``cwebmac.tex'' and dothe formatting by hand. I therefore need
> some trick to put blocks which will be ignored by tangle and formatted like C
> by weave. The trick with

I use FWEB rather than CWEB but I would suggest sending the C code to a
separate file (something like dustbin.c). This way tangle will happily throw
them away while weave will format them correctly (this works in FWEB).

================================================================================
Archive-Date: Thu, 27 May 1993 15:43:14 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nyoik-0005McC@satyr.sylvan.com>
Date: Thu, 27 May 93 13:38 PDT
To: WAGNER%CSEARN.BITNET@cunyvm.cuny.edu
CC: Literate Progaramming list <litprog@SHSU.edu>
Subject: formatting examples in CWEB
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM

>>>>> "Zdenek" == Zdenek Wagner <apple!CSEARN.BITNET!WAGNER> writes:

Zdenek> And now comes the question. The WEB file should contain
Zdenek> examples which should be formatted in the similar way as the
Zdenek> C-part. I do not like to study the macros from ``cwebmac.tex''
Zdenek> and dothe formatting by hand. I therefore need some trick to
Zdenek> put blocks which will be ignored by tangle and formatted like
Zdenek> C by weave. [...]

The way that comes to my mind is judicious use of #ifdef directives in
the C part of your code. This will make blocks that are tangled, but
ignored by your C compiler.

Zdenek> [...] I intend to leave some modules unresolved. Imagine the
Zdenek> part of the example:

Zdenek> if (errorCode != 0) {
Zdenek>  @<Display error message@>@;
Zdenek> }

Zdenek> I will not specify how to display the error message because
Zdenek> each programmer has his own way for managing error messages or
Zdenek> even his own libraries. It is even more evident on data
Zdenek> inputand output of results which does not depend upon the
Zdenek> properties of the base class but on the nature of the problem.

This would seem to imply that you're attempting to get these other
people to write WEB code that interfaces with yours. Are you? Or are
they going to be writing C++ code that uses the tangled output?

I think getting other people to write in WEB in small doses (and
getting them addicted!) is a Good Thing. :-)

However, it would seem to be a better solution to provide something
like:

    @ This code is for reporting errors. If you |#define DEFAULT| when
    compiling this code, the default error display will be used.

    @<Display err...@>=
    #ifdef DEFAULT
    cerr << "!! Error " << errorCode << " encountered.\n";
    #endif

That way, if the programmer wants to provide their own WEB additions,
they simply have to not define DEFAULT and *add* a @<Display err...@>=
definition, appending their error handling code to the above fragment.

Another solution comes to mind as I'm writing this.

The best of all possible worlds, in my opinion, would be to create
default error handlers as C macros and provide a mechanism for users
to override these macros (in a separate include file, perhaps). This
would make for a fully documented standard interface to your code. It
would also mean that consumers would never change the code directly.

This would look something like this. Early in your file, you would
define the user-changeable macros (in the C part or the definition
part of your WEB, doesn't matter).

    @ These default macros are used throughout the rest of this C++
    class.

    @<Generic Macros@>=
    #define ErrorDisplay(errorCode) \
	cerr << "!! Error " << errorCode << " encountered.\n"

Then you do something like:

    @ User-supplied redefinitions file. If you want to use all the
    defaults, just leave this file empty.

    @<User Redefinitions@>=
    #include "local-hacks.h"	// Redefine ErrorDisplay macro, etc.

And then later, just do:

   @<Display error@>=
   ErrorDisplay(errorCode);

The "local-hacks.h" could contain code like this:

   #undef ErrorDisplay
   #define ErrorDisplay(errorCode) \
   cerr << "Dude!! I seem to have encountered error " << errorCode << "\n"

Hope this helps.


			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Fri, 28 May 1993 15:26:23 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305282021.AA16584@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Fri, 28 May 1993 15:20:58 -0500
To: LitProg@shsu.edu, ralexand@mason1.gmu.edu
Subject: Re: CWEB 3.0

Roger Alexander asks:

  > Does anyone know when cweb 3.0 will be out ?

Last I heard, it was supposed to be ready in April.  It seems that DEK
is still polishing off a few rough edges.  I suspect it's the C++
grammar that causing most of the problems.  C++ overloads a lot of
keywords (like ``public'') that require different formatting in
different contexts.  If he's trying to deal with templates as well,
he's got his work cut out for him.

		 -- Lee
================================================================================
Archive-Date: Fri, 28 May 1993 15:35:02 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <9305282032.AA17171@im4u.cs.utexas.edu>
From: leew@cs.utexas.edu (Lee Wittenberg)
Reply-To: LitProg@SHSU.edu, leew@CS.UTEXAS.EDU
Date: Fri, 28 May 1993 15:32:16 -0500
To: LitProg@shsu.edu, WAGNER@csearn.bitnet
Subject: Re: formatting examples in CWEB

Zdenek Wagner writes:

 > Dear LitProggers,
 > I am writing a C++ pure virtual class in CWEB. The class is intended to be
 > used by other programmers even those who do not know WEB (they will just get
 > the tangled code and printed documentation)and also those who are not very
 > familiar with object oriented programming. Therefore I should supply good
 > information how they will derive their own classes.
 > 
 > And now comes the question. The WEB file should contain examples which should
 > be formatted in the similar way as the C-part. I do not like to study the
 > macros from ``cwebmac.tex'' and dothe formatting by hand. I therefore need
 > some trick to put blocks which will be ignored by tangle and formatted like C
 > by weave. The trick with
 > 
 > @(nul@>=...
 > 
 > will not work because I intend to leave some modules unresolved. Imagine the
 > part of the example:
 > 
 > if (errorCode != 0) {
 >  @<Display error message@>@;
 > }
 > 
 > I will not specify how to display the error message because each programmer
 > has his own way for managing error messages or even his own libraries. It is
 > even more evident on data inputand output of results which does not depend
 > upon the properties of the base class but on the nature of the problem.
 > 
 > Is there a solution in CWEB?

Even though CWEAVE complains about unresolved modules, it formats them
correctly (with a zero for the section number).  CTANGLE will also
complain, but carry on (expanding nothing into the specified slot,
which is what you want).  I use this facility quite a bit while
building and testing programs in a piecemeal fashion (I did this
yesterday, in fact).  If the problem is that your make program stops when
CTANGLE or CWEAVE exits with a non-zero value, you can do what I do:
change the command line in the makefile to begin with a ``-''.
For example:

	.w.tex:
	    -cweave $*
	.w.c:
	    -ctangle $*

As far as I know, the @(nul@>=  (or @(/dev/null@>= for Unix types)
should work.  I've thought about it, but never actually had occasion
to try it.

		 -- Lee
================================================================================
Archive-Date: Sat, 29 May 1993 23:28:01 CST
Sender: LP-Mgr@SHSU.edu
Message-ID: <m0nzetg-0005McC@satyr.sylvan.com>
Date: Sat, 29 May 93 21:21 PDT
To: litprog@shsu.edu
Subject: Re:  NuWeb
From: Kayvan Sylvan <kayvan@satyr.Sylvan.COM>
Reply-To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM

Okay, I finally got around to using NuWeb.

I just finished converting a perl script I had written in noweb over
to nuweb. It was quick and painless and behaved exactly as I would
have expected.

Here are the features that make me recommend it over noweb at this
point for language-independant literate programming.

* NuWeb combines weave/tangle into one program (written in NuWeb, of
  course). This small program creates both the LaTeX code and the
  tangle output, and it's fast.

* NuWeb takes some care to keep all of a scrap on one page, if
  possible. 

* NuWeb lets you create multiple output files, and compares the output
  to avoid overwriting unchanged files (this is nice when you are
  working with make on a large program).

* The index of user-defined identifiers. This feature of NuWeb
  compensates in some part for the lack of the automatically generated
  identifier indices present in language-sensitive WEB systems.

NuWeb, like noweb, is {\em real} simple to use.

Thanks to Preston Briggs for a nice tool!!

			---Kayvan

| Kayvan Sylvan, Sylvan Associates, kayvan@satyr.Sylvan.COM, (408) 978-1407  |
| Consulting, Training, Development, SysAdmin, {BSD,SVr3,SVr4} Unix Systems  |
| "Think Globally, Act Locally." "Only you can make your dreams come true."  |
| Proud Dad of Katherine Yelena (born 8/8/89) & Robin Gregory (born 2/28/92) |
================================================================================
Archive-Date: Sun, 30 May 1993 11:16:34 CST
Sender: LP-Mgr@SHSU.edu
From: geb@diktyon.han.de (Martin Gebhardt)
Reply-To: LitProg@SHSU.edu, geb@DIKTYON.HAN.DE
Message-ID: <9305301349.AA24322@diktyon.han.de>
Subject: Re: NuWeb
To: LitProg@SHSU.edu, kayvan@SATYR.SYLVAN.COM
Date: Sun, 30 May 1993 15:49:42 +0200 (MET DST)
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII

Hello,

> Okay, I finally got around to using NuWeb.

I just wonder why I seem to have missed the original introduction to
NuWeb. It'd be nice if someone could send it to me. (Or if the author
could send me a copy, which is what this may lead to, anyway.)

Thanks, Martin.

