diff options
| author | Dylan MacKenzie <ecstaticmorse@gmail.com> | 2019-09-18 07:32:42 -0700 |
|---|---|---|
| committer | Dylan MacKenzie <ecstaticmorse@gmail.com> | 2019-09-18 07:32:42 -0700 |
| commit | a526e4faa6b69f1b6ea60e5e692b679e24bb1994 (patch) | |
| tree | 70d495fe00159242dbbde32c6bf6d07b58064c92 /src/librustc_mir/dataflow | |
| parent | cbaaf05b9425996d8d14bbd5fe435ac7d3d955f1 (diff) | |
| download | rust-a526e4faa6b69f1b6ea60e5e692b679e24bb1994.tar.gz rust-a526e4faa6b69f1b6ea60e5e692b679e24bb1994.zip | |
Use an associated const for `name`
Diffstat (limited to 'src/librustc_mir/dataflow')
| -rw-r--r-- | src/librustc_mir/dataflow/generic.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustc_mir/dataflow/generic.rs b/src/librustc_mir/dataflow/generic.rs index 73f17e75afe..6ee81de19f1 100644 --- a/src/librustc_mir/dataflow/generic.rs +++ b/src/librustc_mir/dataflow/generic.rs @@ -40,11 +40,11 @@ pub trait Analysis<'tcx>: BottomValue { /// The index type used to access the dataflow state. type Idx: Idx; - /// A name describing the dataflow analysis being implemented. + /// A name, used for debugging, that describes this dataflow analysis. /// /// The name should be suitable as part of a filename, so avoid whitespace, slashes or periods /// and try to keep it short. - fn name() -> &'static str; + const NAME: &'static str; /// The size of each bitvector allocated for each block. fn bits_per_block(&self, body: &mir::Body<'tcx>) -> usize; |
