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

aborts: Clarify documentation and comments #85377

Merged
merged 7 commits into from
Jul 5, 2021
Merged

Commits on Jul 5, 2021

  1. aborts: Clarify documentation and comments

    In the docs for intrinsics::abort():
    
     * Strengthen the recommendation by to use process::abort instead.
     * Document the fact that it (ab)uses an LLVM debug trap and what the
       likely consequences are.
     * State that the precise behaviour is unstable.
    
    In the docs for process::abort():
    
     * Promise that we have the same behaviour as C `abort()`.
     * Document the likely consequences, including, specifically, the
       consequences on Unix.
    
    In the internal comment for unix::abort_internal:
    
     * Refer to the public docs for the public API functions.
     * Correct and expand the description of libc::abort.  Specifically:
     * Do not claim that abort() unregisters signal handlers.  It doesn't;
       it honours the SIGABRT handler.
     * Discuss, extensively, the issue with abort() flushing stdio buffers.
     * Describe the glibc behaviour in some detail.
    
    Co-authored-by: Mark Wooding <mdw@distorted.org.uk>
    Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
    2 people authored and m-ou-se committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    a8bb7fa View commit details
    Browse the repository at this point in the history
  2. abort docs: Do not claim that intrinsics::abort is always a debug trap

    As per discussion here
     rust-lang#85377 (review)
    
    Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
    ijackson authored and m-ou-se committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    de19e4d View commit details
    Browse the repository at this point in the history
  3. abort docs: Document buffer non-flushing

    There is discussion of this in rust-lang#40230 which requests clarification.
    
    Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
    ijackson authored and m-ou-se committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    4e7c348 View commit details
    Browse the repository at this point in the history
  4. Talk about invalid instructions rather than debug traps

    And withdraw the allegation of "abuse".
    
    Adapted from a suggestion by @m-ou-se.
    
    Co-authored-by: Mara Bos <m-ou.se@m-ou.se>
    Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
    ijackson and m-ou-se committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    44852e0 View commit details
    Browse the repository at this point in the history
  5. Talk about "terminate" rather than "die"

    Adapted from a suggestion by @m-ou-se.
    
    Co-authored-by: Mara Bos <m-ou.se@m-ou.se>
    Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
    ijackson and m-ou-se committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    19c347e View commit details
    Browse the repository at this point in the history
  6. Use american spelling for behaviour

    Co-authored-by: Yuki Okushi <jtitor@2k36.org>
    m-ou-se and JohnTitor committed Jul 5, 2021
    Configuration menu
    Copy the full SHA
    f73a555 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    08d912f View commit details
    Browse the repository at this point in the history