aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMu Qiao <qiaomuf@gentoo.org>2011-07-29 19:50:09 +0800
committerMu Qiao <qiaomuf@gentoo.org>2011-08-02 15:52:19 +0800
commit2736a7699bd775649a9f0c3ebdae6bf1331c71aa (patch)
tree1cacc1e81dab0f23ab9d3d7ed6a4f455c6db4432 /scripts
parentParser: allow 'test' to be string literal (diff)
downloadlibbash-2736a7699bd775649a9f0c3ebdae6bf1331c71aa.tar.gz
libbash-2736a7699bd775649a9f0c3ebdae6bf1331c71aa.tar.bz2
libbash-2736a7699bd775649a9f0c3ebdae6bf1331c71aa.zip
Parser: allow 'function' to be string literal
Diffstat (limited to 'scripts')
-rw-r--r--scripts/function_def.bash6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/function_def.bash b/scripts/function_def.bash
index 3918896..b425221 100644
--- a/scripts/function_def.bash
+++ b/scripts/function_def.bash
@@ -94,5 +94,9 @@ function shift_test() {
}
shift_test 1 2
-test-flag-CC() { echo "CC" "$1"; }
+test-flag-CC() {
+ function="$1"
+ echo "'${function}' function is not defined"
+ echo "CC" "$1";
+}
test-flag-CC abc