1. 05 7月, 2021 3 次提交
    • M
      s/die/terminate/ in abort documentation. · 08d912fd
      Mara Bos 提交于
      08d912fd
    • I
      abort docs: Document buffer non-flushing · 4e7c3481
      Ian Jackson 提交于
      There is discussion of this in #40230 which requests clarification.
      Signed-off-by: NIan Jackson <ijackson@chiark.greenend.org.uk>
      4e7c3481
    • I
      aborts: Clarify documentation and comments · a8bb7fa7
      Ian Jackson 提交于
      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: NMark Wooding <mdw@distorted.org.uk>
      Signed-off-by: NIan Jackson <ijackson@chiark.greenend.org.uk>
      a8bb7fa7
  2. 02 7月, 2021 1 次提交
  3. 26 6月, 2021 1 次提交
  4. 15 6月, 2021 1 次提交
  5. 12 5月, 2021 5 次提交
  6. 22 4月, 2021 1 次提交
  7. 21 4月, 2021 1 次提交
  8. 27 3月, 2021 1 次提交
  9. 10 3月, 2021 1 次提交
    • K
      Demonstrate best practice for feeding stdin of a child processes · ce2d95cd
      Kornel 提交于
      It's possible to create a deadlock with stdin/stdout I/O on a single thread:
      
      * the child process may fill its stdout buffer, and have to wait for the parent process to read it,
      * but the parent process may be waiting until its stdin write finishes before reading the stdout.
      
      Therefore, the parent process should use separate threads for writing and reading.
      ce2d95cd
  10. 23 2月, 2021 1 次提交
    • I
      ExitStatus: Improve documentation re wait status vs exit status · 4bb8425a
      Ian Jackson 提交于
      The use of `ExitStatus` as the Rust type name for a Unix *wait
      status*, not an *exit status*, is very confusing, but sadly probably
      too late to change.
      
      This area is confusing enough in Unix already (and many programmers
      are already confuxed).  We can at least document it.
      
      I chose *not* to mention the way shells like to exit with signal
      numbers, thus turning signal numbers into exit statuses.  This is only
      relevant for Rust programs using `std::process` if they run shells.
      Signed-off-by: NIan Jackson <ijackson@chiark.greenend.org.uk>
      4bb8425a
  11. 11 2月, 2021 1 次提交
  12. 23 11月, 2020 1 次提交
  13. 19 11月, 2020 1 次提交
  14. 01 11月, 2020 1 次提交
  15. 31 10月, 2020 1 次提交
  16. 19 10月, 2020 1 次提交
  17. 27 9月, 2020 1 次提交
  18. 21 9月, 2020 1 次提交
  19. 11 9月, 2020 1 次提交
  20. 03 9月, 2020 1 次提交
  21. 31 8月, 2020 1 次提交
  22. 24 8月, 2020 1 次提交
  23. 14 8月, 2020 1 次提交
    • J
      Improve documentation on process::Child.std* fields · 90e4c905
      Jonas Berlin 提交于
      As a relative beginner, it took a while for me to figure out I could just steal the references to avoid partially moving the child and thus retain ability to call functions on it (and store it in structs etc).
      90e4c905
  24. 12 8月, 2020 2 次提交
  25. 11 8月, 2020 1 次提交
  26. 28 7月, 2020 1 次提交
  27. 23 5月, 2020 1 次提交
  28. 18 5月, 2020 1 次提交
  29. 26 4月, 2020 2 次提交
  30. 30 11月, 2019 1 次提交
    • D
      Format libstd with rustfmt · 4436c9d3
      David Tolnay 提交于
      This commit applies rustfmt with rust-lang/rust's default settings to
      files in src/libstd *that are not involved in any currently open PR* to
      minimize merge conflicts. THe list of files involved in open PRs was
      determined by querying GitHub's GraphQL API with this script:
      https://gist.github.com/dtolnay/aa9c34993dc051a4f344d1b10e4487e8
      
      With the list of files from the script in outstanding_files, the
      relevant commands were:
      
          $ find src/libstd -name '*.rs' \
              | xargs rustfmt --edition=2018 --unstable-features --skip-children
          $ rg libstd outstanding_files | xargs git checkout --
      
      Repeating this process several months apart should get us coverage of
      most of the rest of libstd.
      
      To confirm no funny business:
      
          $ git checkout $THIS_COMMIT^
          $ git show --pretty= --name-only $THIS_COMMIT \
              | xargs rustfmt --edition=2018 --unstable-features --skip-children
          $ git diff $THIS_COMMIT  # there should be no difference
      4436c9d3
  31. 07 11月, 2019 1 次提交
  32. 21 10月, 2019 1 次提交