summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--Functions/Misc/zcalc4
2 files changed, 7 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index b921f63c3..3b010f073 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2015-11-27  Peter Stephenson  <p.stephenson@samsung.com>
+
+	* unposted: Functions/Misc/zcalc: ZCALCPROMPT created globally.
+
 2015-11-27  Daniel Shahaf  <d.s@daniel.shahaf.name>
 
 	* 37214: Functions/Prompts/prompt_walters_setup: 'prompt
diff --git a/Functions/Misc/zcalc b/Functions/Misc/zcalc
index 17700e48b..857007a94 100644
--- a/Functions/Misc/zcalc
+++ b/Functions/Misc/zcalc
@@ -114,7 +114,9 @@ forms=( '%2$g' '%.*g' '%.*f' '%.*E' '')
 zmodload -i zsh/mathfunc 2>/dev/null
 autoload -Uz zmathfuncdef
 
-: ${ZCALCPROMPT="%1v> "}
+if (( ! ${+ZCALCPROMPT} )); then
+  typeset -g ZCALCPROMPT="%1v> "
+fi
 
 # Supply some constants.
 float PI E