summary refs log tree commit diff
path: root/Functions/Zle
diff options
context:
space:
mode:
authorPeter Stephenson <pws@zsh.org>2016-06-16 11:39:42 +0100
committerPeter Stephenson <pws@zsh.org>2016-06-16 11:39:42 +0100
commit4cacf1624f0393c43a9a2c3259957b8d78eb7609 (patch)
tree02c8f0a91e37e26da61ba02391784e81388138ad /Functions/Zle
parentf497573c80eff3ee0434867e24c1a4dc67ad80ee (diff)
downloadzsh-4cacf1624f0393c43a9a2c3259957b8d78eb7609.tar.gz
zsh-4cacf1624f0393c43a9a2c3259957b8d78eb7609.tar.xz
zsh-4cacf1624f0393c43a9a2c3259957b8d78eb7609.zip
38693: Add RPN mode to zcalc
Diffstat (limited to 'Functions/Zle')
-rw-r--r--Functions/Zle/zcalc-auto-insert3
1 files changed, 2 insertions, 1 deletions
diff --git a/Functions/Zle/zcalc-auto-insert b/Functions/Zle/zcalc-auto-insert
index c9a5c8867..e1affd1c3 100644
--- a/Functions/Zle/zcalc-auto-insert
+++ b/Functions/Zle/zcalc-auto-insert
@@ -1,6 +1,7 @@
 # Bind to a binary operator keystroke for use with zcalc
+# Not useful in RPN mode.
 
-if [[ -n $ZCALC_ACTIVE ]]; then
+if [[ -n $ZCALC_ACTIVE && $ZCALC_ACTIVE != rpn ]]; then
   if [[ $CURSOR -eq 0 || $LBUFFER[-1] = "(" ]]; then
     LBUFFER+=${ZCALC_AUTO_INSERT_PREFIX:-"ans "}
   fi