diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2022-08-15 09:58:38 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2022-08-15 13:29:28 +1000 |
| commit | 2ef04795681837153df7613192305a2ddbf13497 (patch) | |
| tree | 63ba7232dcbada3c9e175f7083118f3cba0e1748 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | |
| parent | 1e8497351d7cb15eddd9db2f88866294bab27a21 (diff) | |
| download | rust-2ef04795681837153df7613192305a2ddbf13497.tar.gz rust-2ef04795681837153df7613192305a2ddbf13497.zip | |
Simplify attribute handling in `parse_bottom_expr`.
`Parser::parse_bottom_expr` currently constructs an empty `attrs` and then passes it to a large number of other functions. This makes the code harder to read than it should be, because it's not clear that many `attrs` arguments are always empty. This commit removes `attrs` and the passing, simplifying a lot of functions. The commit also renames `Parser::mk_expr` (which takes an `attrs` argument) as `mk_expr_with_attrs`, and introduces a new `mk_expr` which creates an expression with no attributes, which is the more common case.
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
