From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 953 invoked from network); 16 May 2004 22:41:11 -0000 Received: from ns2.primenet.com.au (HELO primenet.com.au) (?aZodyYZgLFfWpeCWUKivNX6Nsel+ZhLw?@203.24.36.3) by ns1.primenet.com.au with SMTP; 16 May 2004 22:41:11 -0000 Received: (qmail 22807 invoked from network); 16 May 2004 21:36:26 -0000 Received: from thor.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.86) by proxy.melb.primenet.com.au with SMTP; 16 May 2004 21:36:26 -0000 Received: (qmail 18234 invoked from network); 16 May 2004 21:34:38 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 16 May 2004 21:34:38 -0000 Received: (qmail 17897 invoked by alias); 16 May 2004 21:34:29 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7458 Received: (qmail 17887 invoked from network); 16 May 2004 21:34:29 -0000 Received: from thor.dotsrc.org (HELO a.mx.sunsite.dk) (qmailr@130.225.247.86) by sunsite.dk with SMTP; 16 May 2004 21:34:26 -0000 Received: (qmail 17669 invoked from network); 16 May 2004 21:34:25 -0000 Received: from falcon.mail.pas.earthlink.net (207.217.120.74) by a.mx.sunsite.dk with SMTP; 16 May 2004 21:34:23 -0000 Received: from cpe-24-221-169-78.ca.sprintbbd.net ([24.221.169.78] helo=ckhb.org) by falcon.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 1BPTH1-0007Hp-00 for zsh-users@sunsite.dk; Sun, 16 May 2004 14:34:19 -0700 From: "S. Cowles" Reply-To: scowles@earthlink.net Organization: personal To: zsh-users@sunsite.dk Subject: parameter type differences? Date: Sun, 16 May 2004 14:34:06 -0700 User-Agent: KMail/1.5.1 References: <20040514102510.GF10581@greux.loria.fr> In-Reply-To: <20040514102510.GF10581@greux.loria.fr> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Description: clearsigned data Content-Disposition: inline Message-Id: <200405161434.14167.scowles@earthlink.net> X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=0.0 required=6.0 tests=none autolearn=no version=2.63 X-Spam-Hits: 0.0 I have the following script, with appended output. There are 3 cases teste= d,=20 comparing a reference value for parameter "bref" with 3 values of parameter= =20 "b". The utility od is used to verify the values of the "bref" and "b"=20 parameters. =20 My question is: why are the values of "b" not equal to "bref" in cases 1 a= nd=20 2? If the issue is parameter type, is there any way to display the paramet= er=20 type for "b"? Thank you. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3Dthe script=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D #!/bin/zsh emulate -R zsh bref=3D' ' echo "case 1." b=3D'\012' [[ ${bref} =3D=3D ${b} ]] && echo same || echo diff echo -n "${bref}" | od -b ; echo -n "${b}" | od -b echo "case 2." b=3D'\n' [[ ${bref} =3D=3D ${b} ]] && echo same || echo diff echo -n "${bref}" | od -b ; echo -n "${b}" | od -b echo "case 3." b=3D' ' [[ ${bref} =3D=3D ${b} ]] && echo same || echo diff echo -n "${bref}" | od -b ; echo -n "${b}" | od -b exit 0 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3Dthe output=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D case 1. diff 0000000 012 0000001 0000000 012 0000001 case 2. diff 0000000 012 0000001 0000000 012 0000001 case 3. same 0000000 012 0000001 0000000 012 0000001 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D