Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: In POSIX mode, ${#var} measures length in bytes, not characters



When we started multibyte support, traditional sh's all only supported
the portable character set, so we let zsh behave as if characters were
all 8 bit as the least disruptive change.  Multibyte is on in all other
emulations, even ksh.

With multibyte character sets virtually universal, it's probably time to
assume obeying the localization screws things up least.

With MULTIBYTE always on when available, the "EMULATE" flag becomes
redundant.

pws

diff --git a/Src/options.c b/Src/options.c
index 3e3e074..78f603d 100644
--- a/Src/options.c
+++ b/Src/options.c
@@ -192,7 +192,7 @@ static struct optname optns[] = {
 {{NULL, "monitor",	      OPT_SPECIAL},		 MONITOR},
 {{NULL, "multibyte",
 #ifdef MULTIBYTE_SUPPORT
-			      OPT_EMULATE|OPT_ZSH|OPT_CSH|OPT_KSH
+			      OPT_ALL
 #else
 			      0
 #endif



Messages sorted by: Reverse Date, Date, Thread, Author