Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[libc++] Add an ABI setting to harden unique_ptr<T[]>::operator[] #91798

Merged
merged 1 commit into from
Sep 27, 2024

Commits on Sep 26, 2024

  1. [libc++] Harden unique_ptr<T[]>::operator[] when we can

    This patch adds an ABI configuration that allows bounds-checking in
    unique_ptr<T[]>::operator[] when it has been constructed with bounds
    information in the API.
    
    The patch also adds support for bounds-checking when an array cookie
    is known to exist, which allows validating bounds without even changing
    the ABI.
    
    Drive-by changes:
    - Improve the tests for `operator[]`
    - Improve the tests for `.get()`
    - Add a test for incomplete types support
    ldionne committed Sep 26, 2024
    Configuration menu
    Copy the full SHA
    76fc808 View commit details
    Browse the repository at this point in the history