Thread View: comp.sys.sequent
3 messages
3 total messages
Started by Michael Collier
Mon, 22 Oct 1990 21:13
cshell bug?
Author: Michael Collier
Date: Mon, 22 Oct 1990 21:13
Date: Mon, 22 Oct 1990 21:13
23 lines
1032 bytes
1032 bytes
i execute the following piece of cshell under dynix 3.0.12: #! /bin/csh if(0) then if(1) then echo cant get here else echo bug endif endif i get the following output: bug the shell is matching the "else" with the first, outermost "if", not with the second, nested "if". can anyone tell me if this is fixed under 3.0.17? if not, why not? thanks. -- Michael H. Collier INET: collier@ariel.unm.edu BITNET: COLLIER@UNMB home: 1160 Don Pasqual NW; Los Lunas, NM 87031; (505) 865 8770 work: UNM CIRT; 2701 Campus Bvd; Albuquerque, NM 87131; (505) 277 8039
Re: cshell bug?
Author: Keith Pyle
Date: Tue, 23 Oct 1990 17:52
Date: Tue, 23 Oct 1990 17:52
20 lines
1470 bytes
1470 bytes
In article <1990Oct22.211323.21097@ariel.unm.edu> collier@triton.unm.edu (Michael Collier) writes: >i execute the following piece of cshell under dynix 3.0.12: > ... >the shell is matching the "else" with the first, outermost "if", not with >the second, nested "if". can anyone tell me if this is fixed under 3.0.17? >if not, why not? thanks. The behavior is unchanged in Dynix 3.0.17. It also behaves this way under SunOS 4.0 & 4.1 and System V/386 Release 3.00 on a Unisys U6000/51. It does not have a problem on either Ultrix 3.1 or HP/UX 7.0. I'll refrain from commenting on why I think it wasn't fixed in 3.0.17. -- ----------------------------------------------------------------------------- Keith Pyle UUCP: ...!cs.utexas.edu!execu!keith Execucom Systems Corp., Austin, Texas Internet: keith@execu.com "It's 10 o'clock. Do you know where Disclaimer: What?? your child processes are?" You actually believed me? -----------------------------------------------------------------------------
Re: cshell bug? RTM
Author: John Barlow
Date: Mon, 29 Oct 1990 09:35
Date: Mon, 29 Oct 1990 09:35
33 lines
1672 bytes
1672 bytes
I run Dynix 3.0.12, and the following code works, as long as you
have the space between the "if" and the "(" :
#!/bin/csh
if (0) then
if (1) then
echo cant get here
else
echo bug
endif
endif
if you don't have the space it echos "bug".
Please note the manual (although you have to wade through 11 pages,
and then its only a few lines):
> ... It is important to note that no two components of
> an expression can appear in the same word; except when
>
>Revision 1.22 87/08/06 12
>
>CSH(1) DYNIX Programmer's Manual CSH(1)
>
> adjacent to components of expressions which are syntacti-
> cally significant to the parser (`&' `|' `<' `>' `(' `)')
> they should be surrounded by spaces.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
jdb = John Barlow, Parallel Computing Research Facility,
Australian National University, I-Block, PO Box 4, Canberra, 2601, Australia.
email = jdb@arp.anu.oz.au {soon to be jdb@arp.anu.edu.au}
[International = +61 6, Australia = 06] [Phone = 2492930, Fax = 2490747]
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads