[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] mbrtowc: remove a redundant condition
From: |
Bruno Haible |
Subject: |
Re: [PATCH] mbrtowc: remove a redundant condition |
Date: |
Sun, 21 Mar 2021 19:22:01 +0100 |
User-agent: |
KMail/5.1.3 (Linux/4.4.0-203-generic; KDE/5.18.0; x86_64; ; ) |
Hi Benno,
> * lib/mbrtowc-impl-utf8.h: There is no need to check for c == 0xf4
> when !(c < 0xf4), as ten lines earlier c <= 0xf4 was established.
Your patch is correct. But we generally don't need to do micro-
optimizations that a compiler easily can do for us. Just curious:
Did you get a compiler warning about this code? If so, from which
compiler? Or did you find this redundancy by staring at the code?
Bruno