Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [BUG] emulate sh: arith assignment assigns variable type
- X-seq: zsh-workers 37494
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: [BUG] emulate sh: arith assignment assigns variable type
- Date: Sat, 2 Jan 2016 12:46:59 -0800
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=from:message-id:date:in-reply-to:comments:references:to:subject :mime-version:content-type; bh=ArfgM/qGisSCQpuYgtjHMzRzHgbuqGIKbGGyCZoxn9g=; b=cSU25UJoGoUMuXPOE0hnt16UFHQvgmxRKRVxmHjZcUr3QdkjS3WSJQ3fkpj7ih0l8M Bobgy+WTAVNpRYUXq75E+Jbt85DGpKdaOazlRf+pJISFcDJT0Qpm5pSlogZ1M1iFPOLI Fm5LpjrurUg7TpNaeKpN+Qu7jNQ0GkCFsdO21QahH9NsX/8STvucMpSzVmUAOw/lpugB rXw3z4L+eqP4D8VxSw9Kivaoc8fXPSN/+bDYgKdD4onue1jZ/p28/w0Nxo/bPIhIbrLb QHGahjLoRRNSeQEDRoikNpT0gtCCSOTLbe1yY/lYnh+YcL36VAqTLfofncoDFLb5ZOos rBfQ==
- In-reply-to: <20160102181126.364cc450@ntlworld.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <5686DB95.2090602@inlv.org> <20160102181126.364cc450@ntlworld.com>
On Jan 2, 6:11pm, Peter Stephenson wrote:
}
} Does this need a special option? The linkage is a bit tenouous.
Are there other assignment-time differences? Maybe a POSIX_ASSIGNMENT
option is in order, though I dislike moving functionality from one
option to another.
On the other hand, is this --
} pm = createparam(t, ss ? PM_ARRAY :
} + isset(POSIXIDENTIFIERS) ? PM_SCALAR :
} (val.type & MN_INTEGER) ? PM_INTEGER : PM_FFLOAT);
-- really the correct fix? I was thinking more along the lines of
creating it as an integer but then changing the type back to scalar
at the time of assignment if the assigned string did not parse as an
arithmetic expression.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author