summary refs log tree commit diff
path: root/Src/parse.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/parse.c')
-rw-r--r--Src/parse.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/Src/parse.c b/Src/parse.c
index ffd25de9d..0b54a904d 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -1612,7 +1612,8 @@ par_funcdef(int *cmplx)
 	    num++;
 	    zshlex();
 	}
-	*cmplx = 1;
+	if (num > 0)
+	    *cmplx = 1;
 	ecbuf[parg] = ecused - parg; /*?*/
 	ecbuf[parg+1] = num;
     }
@@ -1896,7 +1897,8 @@ par_simple(int *cmplx, int nr)
 		    argc++;
 		    zshlex();
 		}
-		*cmplx = 1;
+		if (argc > 0)
+		    *cmplx = 1;
 		ecbuf[parg] = ecused - parg; /*?*/
 		ecbuf[parg+1] = argc;
 	    }