Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: path PATH

On 2023-01-21 11:09, Roman Perepelitsa wrote:
Is the number 42 "in fact" 8#52?
Yes, it most certainly is -- in base 8, which is explicit.
I gotta say, in pretty much every thread where you asked a question
I'm left wondering whether you understood what I was saying. From my
point of view the answer is logical and in a sense obvious

Ah, we'll that's the thing, one can misunderstand some basic premise which makes everything subsequent illogical.  Bart cleared this up by disabusing me of the idea that that a tie was just another name for exactly the same thing, and that *appears* to be the case.  It seemed so obviously the case that I didn't even ask the question.  But no!  a tie creates a scalar with the array elements joined by colons ... $PATH!  But since typeset -p, in every other situation, shows you the value of a parameter I'm wanting the same for PATH.  I'd use set -- which shows it accurately with the colons -- *but* I'd also like to see the type of the variable besides it's value  which pushes me back to typeset -p.  So, there's no easy answer.  I just hafta remember that PATH, like any other tied param, will be a scalar created from an array and sorry, it can't be displayed  like that by typeset -p.    Dunno, maybe I can hack something together but probably not worth it.  One might wish for an option to set that would include type as well as value.  No typeset -p 'recreation', just the information.  I sorta understand why typeset itself is not the vehicle for this since it's not by nature a 'viewer' but a 'creator'.

Anyway I've wasted enough of you guy's time with this.

Messages sorted by: Reverse Date, Date, Thread, Author