[mod.computers.apollo] Movie Review & Cautionary Warning

srt@LOCUS.UCLA.EDU.UUCP (08/01/86)

"The Great Wall" is Peter Wang's ("Chan is Missing", "Dim Sum") most recent
film.  It concerns a Chines-American family's return to the mainland and
the comedy (and drama) that results.  It is quite a good film, in my opinion,
but what concerns this group is that in the background of one scene can be
spotted a DN300.  The first cameo in a major motion picture by an Apollo?

Also, I recently ran across a rather obscure problem in Pascal that I
thought I'd bring up.  I had an IF statement of the form:

        if ((p <> NIL) AND (link[p^.lp] = 0)) then ...

where the first test is "guard" to prevent a problem on the second.  Normally
this works - Pascal does the right thing and evaluates left to right - but
in this case, the compiler pulls the subscript reference outside the IF
form, causing an error.  In essence, it turns this into:

        x := p^.lp;
        if ((p <> NIL) AND (link[x] = 0)) then ...

A hard problem to catch.  The solution is to use nested IFs.

                                                -- Scott

rees@apollo.UUCP (Jim Rees) (08/05/86)

    "The Great Wall" is Peter Wang's ("Chan is Missing", "Dim Sum") most recent
    film.  It concerns a Chines-American family's return to the mainland and
    the comedy (and drama) that results.  It is quite a good film, in my opinion,
    but what concerns this group is that in the background of one scene can be
    spotted a DN300.  The first cameo in a major motion picture by an Apollo?

I saw that too, but wasn't really sure whether it was an Apollo or not.

More film trivia:  In "The Terminator," if you watch the computer stuff
going by in the Arnold point-of-view shots, at one point you see the line
"VTOC is full."

    Also, I recently ran across a rather obscure problem in Pascal that I
    thought I'd bring up.  I had an IF statement of the form:
    
            if ((p <> NIL) AND (link[p^.lp] = 0)) then ...

If you look this up in your favorite reference manual, you will find that
Pascal does not guarantee the order of evaluation.  This is actually a
feature, because usually the compiler can save some computation if it gets
to choose.  If you need to guarantee the order, it's easy enough to do:

            if ((p <> NIL) AND THEN (link[p^.lp] = 0)) then ...

Nested ifs are not necessary.
-------