[analyzer] Implement UseAfterLifetimeEnd checker (#205521)
Implemented the UseAfterLifetimEnd checker which is responsible for detecting lifetime safety violations involving the [[clang::lifetimebound]] annotation. This checker can catch violations in annotated code such as dangling pointer/reference bound to local variables that go out of scope. This checker is one of the reporting checkers that depend on the LifetimeModeling checker #205951. To detect dangling sources the checker queries the state at function exit points through the checkEndFunction callback. This checker does not handle lifetime issues where the code is unannotated.
Detailed work history of this checker can be found here: #200145
Co-authored-by: Balázs Benics <benicsbalazs at gmail.com>
locale: make install Unicode 17.0.0/CLDR 48.2
Data changes:
48.1:
- Update RSD (Serbian Dinar) to use 2-digits for non-cash and 0-digits
for cash.
- Fix issue with tippi and bindi in Punjabi exemplars.
- Fix parsing issue in numeric date+time patterns for zh_Hant and yue.
- Fix issues with hour cycle display names for several languages.
https://cldr.unicode.org/downloads/cldr-48#481-changes
48.2:
- Group separator for number formatting was updated to ' in fr-CH
consistent with other Swiss locales.
- Some fixes to date formats including: Hv available formats were
updated to match behavior in CLDR 47 due to web compatibility issues
related to current JS capabilities.
[9 lines not shown]
locale: Update Unicode to CLDR 48.2
Notable changes:
- Group separator for number formatting was updated to ' in fr-CH
consistent with other Swiss locales.
- Some fixes to date formats including: Hv available formats were
updated to match behavior in CLDR 47 due to web compatibility issues
related to current JS capabilities.
- Emoji annotations fixes including collisions between emoji short
names.
- Updated AM/PM for ko & ps to be consistent with how the wide forms are
localized.
Reviewed by: bapt
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D57626
locale: Do not strip the suffix from CLDRVERSION
The upstream CLDR directory structure requires the full version string.
Remove the ':R' modifier to fix the fetch paths.
Previously this worked because major releases were published in a
directory without the ".0" suffix, while the filenames included it.
Starting with CLDR 47, the upstream layout changed to use the full
version string exclusively, causing the fetch URLs to break for point
releases.
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D57625
[clang][Driver] Include stdc-predef.h by default on musl
Match GCC behavior for musl-based Linux targets by implicitly passing
`-include stdc-predef.h` for non-freestanding compilations.
Unlike glibc, musl does not arrange for this header to be included through
its normal system headers. As a result, Clang may miss predefined C macros
provided by musl's stdc-predef.h unless users include it manually, while the
same code works with GCC.
Add Driver tests covering musl, non-musl, freestanding, preprocessed input,
missing-header diagnostics, and actual macro visibility.
This patch is based on: https://reviews.llvm.org/D137043 and
slightly tweaks it, as the code has drifted since 2023 when
that was authored.
Co-authored-by: Tao Liang <Origami404 at foxmail.com>
Co-authored-by: YingChi Long <me at inclyc.cn>
Be truly pedantic about UTF-8 encodings
If we're not going to be accepting "legacy" UTF-8
(5 and 6 byte encodings for code points >= 0x00200000 which the
standards don't allow, as they won't fit in UTF-16) then we
certainly should never be able to generate them, and even more
should certainly be pedantic about not allowing the various
forms of mis-coded strings for which there is no justification
but have been known to be used to attempt to violate security.
This, I believe, now enforces all the current restrictions, eg,
it will no longer be possible to encode ascii in 2 bytes (0xc0 '.')
and similar, the shortest legal encoding is all that will be
accepted (and all that will be generated, but that was always true).
It is quite possible that this will break things, probably many
tests, as now random garbage won't be accepted as valid, things
must be properly encodedd.
ocaml-zarith: update to 1.14
Release 1.14 (2024-07-10)
- #148, #149: Fail unmarshaling when it would produce non-canonical big ints
- #145, #150: Use standard hash function for `Z.hash` and add `Z.seeded_hash`
- #140, #147: Add fast path for `Z.divisible` on small arguments
Release 1.13 (2023-07-19)
- #113: add conversions to/from small unsigned integers `(to|fits)_(int32|int64|nativeint)_unsigned` [Antoine Miné]
- #128: add functions to pseudo-randomly generate integers [Xavier Leroy]
- #105: add `Big_int.big_int_of_float` [Yishuai Li]
- #90: add fast path to `Z.extract` when extraction leads to a small integer [Frédéric Recoules]
- #137: more precise bounds for of_float conversion to small ints [Antoine Miné]
- #118: fix Z_mlgmpidl interface for mlgmpidl >= 1.2 [Simmo Saan]
- #109: fix typo in `ml_z_mul` function [Bernhard Schommer]
- #108: fix dependency on C evaluation order in `ml_z_remove` [Xavier Clerc]
- #117 #120 #129 #132 #135 #139 #141: configure & build simplifications and fixes [various authors]
- #134: CI testing: add Windows, test both 4.14 and 5.0 [Hugo Heuzard]
devel/ocaml-mew: New port
Mew - Modal Editing Witch - is an general modal editing engine
generator. Users must provide an implementation for Key, Mode,
Concurrent modules to the functor.
WWW: https://github.com/kandu/mew
devel/ocaml-mew_vi: New port
Mew_vi - Modal Editing Witch, VI interpreter - is an VI-like modal
editing engine generator. Users must provide an implementation for
Key, Mode, Concurrent modules to the functor.
WWW: https://github.com/kandu/mew_vi
devel/ocaml-trie: New port
This OCaml library implements a trie tree in OCaml. A trie is a
datastructure used to implement a prefix search efficiently.
WWW: https://github.com/kandu/trie
devel/ocaml-merlin: New port
Merlin assists you writing OCaml code by providing features commonly
found in integrated development environments (IDEs) such as code
completion, browsing, error reporting, etc. Integration with Emacs and
VIM are provided. Merlin is also a set of OCaml libraries to help one
implement said features.
WWW: https://ocaml.github.io/merlin/
devel/ocaml-magic-mime: New port
This OCaml library provides lookup functions to map a filename to a
MIME type (based on the extension of the file), and conversely from a
MIME type to a list of file extensions. As the database is bundled
inside an OCaml module, the lookups do not access the filesystem.
WWW: https://github.com/mirage/ocaml-magic-mime
devel/ocaml-lwt_log: New port
Lwt_log is a logging library for OCaml applications using the Lwt
threading library.
WWW: https://github.com/ocsigen/lwt_log
devel/ocaml-js_of_ocaml-ocamlbuild: New port
This OCaml library provide a non-blocking interface to OpenSSL that is
compatible with application using the "lwt" cooperative threading
library.
WWW: https://ocsigen.org/js_of_ocaml
devel/ocaml-gmap: New port
This library provides an hashmap implementation whose values are typed
by the type parameter of the associated (polymorphic) key. This
library relies on generalized algebraic data type (GADT) of OCaml.
WWW: https://github.com/hannesm/gmap
databases/ocaml-pgocaml: New port
This library implements the PostgreSQL wire protocol (version 2, for
PostgreSQL 7 and above) in pure OCaml. In addition to a low-level
interface, this library provides a PPX syntax extension to type-check
and validate SQL expressions at build time.
WWW: https://github.com/darioteixeira/pgocaml