Denis,

> Le 2 mai 2020 à 12:04, Denis Excoffier <[email protected]> a écrit :
> 
>> #include <config.h>
>> #include <stdio.h>
>> #include <locale.h>
>> #include <wchar.h>
>> #include "mbswidth.h"
>> int main ()
>> {
>> setlocale (LC_ALL, "en_US.UTF-8");
>> printf ("%d\n", (int) mbswidth ("{∇⃗×𝐸⃗ = -∂𝐵⃗/∂t}",0)); // 14 vs 17
>> printf ("%d\n", wcwidth (0x2207)); // 1 vs. 2
>> printf ("%d\n", wcwidth (0x20D7)); // 0
>> printf ("%d\n", wcwidth (0x00D7)); // 1
>> printf ("%d\n", wcwidth (0x1D438)); // 1
>> printf ("%d\n", wcwidth (0x2202)); // 1 vs. 2
>> printf ("%d\n", wcwidth (0x1D435)); // 1
>> }

Actually, I would like to make sure it used lib/wchar.h, not your system's 
wchar.h.  In fact, I don't know for sure that you have a lib/wchar.h in Bison's 
build tree.

Could you check that please?  And then check that it is that file that was used 
in your experimentation (You could add a #warning in lib/wchar.h, or play with 
-E, etc.).

And if indeed you were using lib/wchar.h, and not the system's, then please 
send it in full.

Thanks!



Reply via email to