diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2023-11-28 09:11:03 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2023-11-28 09:42:07 +1100 |
| commit | d84d8d26042e4daa81858ac1e86da731c0ff2ec5 (patch) | |
| tree | a2d85d60619c401f061b6bdcdd88d1c21da0d123 /tests/codegen/patchable-function-entry | |
| parent | 24ce52a1993d8092d62ea652c6020f85e6c1027d (diff) | |
| download | rust-d84d8d26042e4daa81858ac1e86da731c0ff2ec5.tar.gz rust-d84d8d26042e4daa81858ac1e86da731c0ff2ec5.zip | |
Rework `ast::BinOpKind::to_string` and `ast::UnOp::to_string`.
- Rename them both `as_str`, which is the typical name for a function that returns a `&str`. (`to_string` is appropriate for functions returning `String` or maybe `Cow<'a, str>`.) - Change `UnOp::as_str` from an associated function (weird!) to a method. - Avoid needless `self` dereferences.
Diffstat (limited to 'tests/codegen/patchable-function-entry')
0 files changed, 0 insertions, 0 deletions
