about summary refs log tree commit diff
path: root/compiler/rustc_codegen_gcc
diff options
context:
space:
mode:
authorJacob Pratt <jacob@jhpratt.dev>2024-12-21 01:18:43 -0500
committerGitHub <noreply@github.com>2024-12-21 01:18:43 -0500
commitcc27e3f08bf05d80fbfd4d165521ab5eb26fd817 (patch)
tree3d1b23dfa8f2bfd09a2a128eac7c3b2feec624b6 /compiler/rustc_codegen_gcc
parentc682d303378efc2b41efe31b9247ef55ac31bda2 (diff)
parent7b42bc0c7935e9f5fefd017249041d64f27bb583 (diff)
downloadrust-cc27e3f08bf05d80fbfd4d165521ab5eb26fd817.tar.gz
rust-cc27e3f08bf05d80fbfd4d165521ab5eb26fd817.zip
Rollup merge of #134593 - kornelski:less-unwrap, r=jhpratt
Less unwrap() in documentation

I think the common use of `.unwrap()` in examples makes it overrepresented, looking like a more typical way of error handling than it really is in real programs.

Therefore, this PR changes a bunch of examples to use different error handling methods, primarily the `?` operator. Additionally, `unwrap()` docs warn that it might abort the program.
Diffstat (limited to 'compiler/rustc_codegen_gcc')
0 files changed, 0 insertions, 0 deletions