Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Bug: Unicode character of zsh module will become weird characters
- X-seq: zsh-workers 52928
- From: "Wu, Zhenyu" <wuzhenyu@xxxxxxxx>
- To: zsh-workers@xxxxxxx
- Cc: zsh-users@xxxxxxx
- Subject: Bug: Unicode character of zsh module will become weird characters
- Date: Sat, 11 May 2024 21:40:39 +0800
- Archived-at: <https://zsh.org/workers/52928>
- List-id: <zsh-workers.zsh.org>
Excuse me:
Reproduce procedures:
```zsh
% git clone --depth=1 https://github.com/zsh-users/zsh
% cd zsh
% sed -i 's/strparam = ztrdup("example");/strparam = ztrdup("你好");/' Src/Modules/example.c
% autoreconf -vif
% ./configure
% make
```
Actual behavior:
```zsh
% zsh -f
laptop% module_path+=( $PWD/Src/Modules )
laptop% zmodload example
The example module has now been set up.
laptop% echo ${(q)exstr}
$'\344'$'\275'\好
laptop%
```
Expected behavior:
```zsh
% zsh -f
laptop% module_path+=( $PWD/Src/Modules )
laptop% zmodload example
The example module has now been set up.
laptop% echo ${(q)exstr}
你好
laptop%
```
Is it a bug? TIA!
--
Best Regards
Wu, Zhenyu
Messages sorted by:
Reverse Date,
Date,
Thread,
Author