Deutsch English Français Italiano |
<v3merq$b1uj$1@dont-email.me> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Lawrence D'Oliveiro <ldo@nz.invalid> Newsgroups: comp.lang.c Subject: Interval Comparisons Date: Tue, 4 Jun 2024 07:14:02 -0000 (UTC) Organization: A noiseless patient Spider Lines: 13 Message-ID: <v3merq$b1uj$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Tue, 04 Jun 2024 09:14:02 +0200 (CEST) Injection-Info: dont-email.me; posting-host="d7d916175bb629e2353c22c0a9deb72e"; logging-data="362451"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19Gfv1U/RChBXlm/KX3pZxd" User-Agent: Pan/0.158 (Avdiivka; ) Cancel-Lock: sha1:UTWfC70/1XFtcdX/BYp+fZgmCNw= Bytes: 1297 Would it break backward compatibility for C to add a feature like this from Python? Namely, the ability to check if a value lies in an interval: def valid_char(c) : "is integer c the code for a valid Unicode character." \ " This excludes surrogates." return \ ( 0 <= c <= 0x10FFFF and not (0xD800 <= c < 0xE000) ) #end valid_char