Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: "typeset -x" vs. "export" in 3.1.6
- X-seq: zsh-workers 8391
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxxxxxxxxx>
- To: Alexandre Duret-Lutz <alexandre.duret@xxxxxxxxxxxxxx>, zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: "typeset -x" vs. "export" in 3.1.6
- Date: Sun, 24 Oct 1999 16:09:17 +0000
- In-reply-to: <7du2nh54k2.fsf@xxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
- References: <991023083509.ZM21037@xxxxxxxxxxxxxxxxxxxxxxx> <991023174311.ZM22277@xxxxxxxxxxxxxxxxxxxxxxx> <7du2nh54k2.fsf@xxxxxxxxx>
On Oct 24, 1:25pm, Alexandre Duret-Lutz wrote:
} Subject: Re: "typeset -x" vs. "export" in 3.1.6
}
} >>> "BS" == Bart Schaefer <schaefer@xxxxxxxxxxxxxxxxxxxxxxx> writes:
}
} [...]
}
} BS> There doesn't seem to have ever been doc written for "typeset -g".
}
} I have just read a paragraph about it in zshbuiltins.1 !
Ah, there it is. I didn't see it before because it isn't among "The
following attribute flags ...".
} BS> Can someone who has a real ksh available please confirm
} BS> what the precise ksh behavior is? Does it differ in 88/93?)
}
} ~ % ksh
} venus:281> foo() { typeset -x bar=123; sh -c 'echo $bar'; }
} venus:282> foo # note: ^--- is needed
} 123
} venus:283>
}
} So having 'typeset -x' doing 'typeset -xg' seems to be right for
} ksh emulation.
Could you do one more test, please?
foo() { typeset -x bar=123; sh -c 'echo $bar'; }
bar() { typeset bar; foo }
Now run "bar".
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author