diff --git a/src/cmd/ksh93/bltins/typeset.c b/src/cmd/ksh93/bltins/typeset.c index 1c3c3d0001ce..0994d966fdfe 100644 --- a/src/cmd/ksh93/bltins/typeset.c +++ b/src/cmd/ksh93/bltins/typeset.c @@ -491,7 +491,7 @@ int b_typeset(int argc,char *argv[],Shbltin_t *context) } if((flag&NV_REF) && (flag&~(NV_REF|NV_IDENT|NV_ASSIGN|NV_SCOPES))) { - errormsg(SH_DICT,2,e_optincompat2,"-n","other options except -c, -D and -g"); + errormsg(SH_DICT,2,e_optincompat2,"-n","other options except -P, -D and -g"); error_info.errors++; } if((flag&NV_TYPE) && (flag&~(NV_TYPE|NV_VARNAME|NV_ASSIGN))) @@ -522,12 +522,12 @@ int b_typeset(int argc,char *argv[],Shbltin_t *context) } if((flag&NV_SCOPES) && sh.mktype) { - errormsg(SH_DICT,ERROR_exit(2),"type members cannot use the scoping flags -c, -D and -g"); + errormsg(SH_DICT,ERROR_exit(2),"type members cannot use the scoping flags -P, -D and -g"); UNREACHABLE(); } if(scoping_flags > 1) { - errormsg(SH_DICT,ERROR_exit(2),"the scoping flags -c, -D and -g cannot be combined"); + errormsg(SH_DICT,ERROR_exit(2),"the scoping flags -P, -D and -g cannot be combined"); UNREACHABLE(); } if(troot==sh.var_tree && !sh.mktype && sh.infunction && !(flag&(NV_SCOPES))) diff --git a/src/cmd/ksh93/data/builtins.c b/src/cmd/ksh93/data/builtins.c index 6029ac86b51a..7f40810b23da 100644 --- a/src/cmd/ksh93/data/builtins.c +++ b/src/cmd/ksh93/data/builtins.c @@ -1919,7 +1919,7 @@ const char sh_opttypeset[] = "[p?Causes the output to be in a format that can be used as input to the " "shell to recreate the attributes for variables. If this flag " "is used by \btypeset\b in a POSIX function without also passing " - "\b-D\b or \b-c\b, the local scope is ignored and \btypeset\b will " + "\b-D\b or \b-P\b, the local scope is ignored and \btypeset\b will " "only use the global scope.]" "[r?Enables readonly. Once enabled it cannot be disabled. See " "\breadonly\b(1).]" diff --git a/src/cmd/ksh93/sh.1 b/src/cmd/ksh93/sh.1 index 74781d7aaa12..8bc97bed9ed3 100644 --- a/src/cmd/ksh93/sh.1 +++ b/src/cmd/ksh93/sh.1 @@ -8485,7 +8485,7 @@ for infinite loops. The same as .BR whence\ \-v . .TP -\(dg\(dd \f3typeset\fP \*(OK \f3\(+-ACDHSbcfglmnprstux\^\fP \*(CK \*(OK \f3\(+-EFLRXZi\*(OK\f2n\^\fP\*(CK \*(CK \*(OK \f3\+-M \*(OK \f2mapname\fP \*(CK \*(CK \*(OK \f3\-T \*(OK \f2tname\fP=(\f2assign_list\fP) \*(CK \*(CK \*(OK \f3\-h \f2str\fP \*(CK \*(OK \f3\-a\fP \*(OK \f2\*(OKtype\*(CK\fP \*(CK \*(CK \*(OK \f2vname\^\fP\*(OK\f3=\fP\f2value\^\fP \*(CK \^ \*(CK .\|.\|. +\(dg\(dd \f3typeset\fP \*(OK \f3\(+-ACDHPSbfglmnprstux\^\fP \*(CK \*(OK \f3\(+-EFLRXZi\*(OK\f2n\^\fP\*(CK \*(CK \*(OK \f3\+-M \*(OK \f2mapname\fP \*(CK \*(CK \*(OK \f3\-T \*(OK \f2tname\fP=(\f2assign_list\fP) \*(CK \*(CK \*(OK \f3\-h \f2str\fP \*(CK \*(OK \f3\-a\fP \*(OK \f2\*(OKtype\*(CK\fP \*(CK \*(CK \*(OK \f2vname\^\fP\*(OK\f3=\fP\f2value\^\fP \*(CK \^ \*(CK .\|.\|. Sets attributes and values for shell variables and functions. When invoked inside a function defined with the .B function @@ -8735,7 +8735,7 @@ above) or in a name space (see .I Name Spaces\^ above). .TP -.B \-c +.B \-P Forces variables to be created or modified using static local scoping, even when .B typeset