about summary refs log tree commit diff
path: root/src/libstd/sys/unix/stack_overflow.rs
diff options
context:
space:
mode:
authorZack M. Davis <code@zackmdavis.net>2018-06-30 20:34:18 -0700
committerZack M. Davis <code@zackmdavis.net>2018-06-30 22:41:01 -0700
commit4ae89129e1beefbe80cca4a13f6fd6e783653926 (patch)
tree865dc804eefd1634fb7ad16b497f34db4a89ceba /src/libstd/sys/unix/stack_overflow.rs
parent9df9c9df7bdcd688bcad9e91b9e2669f01d9f858 (diff)
downloadrust-4ae89129e1beefbe80cca4a13f6fd6e783653926.tar.gz
rust-4ae89129e1beefbe80cca4a13f6fd6e783653926.zip
in which hir::Visibility recalls whence it came (i.e., becomes Spanned)
There are at least a couple (and plausibly even three) diagnostics that
could use the spans of visibility modifiers in order to be reliably
correct (rather than hacking and munging surrounding spans to try to
infer where the visibility keyword must have been).

We follow the naming convention established by the other `Spanned` HIR
nodes: the "outer" type alias gets the "prime" node-type name, the
"inner" enum gets the name suffixed with an underscore, and the variant
names are prefixed with the prime name and `pub use` exported from here
(from HIR).

Thanks to veteran reviewer Vadim Petrochenkov for suggesting this
uniform approach. (A previous draft, based on the reasoning that
`Visibility::Inherited` should not have a span, tried to hack in a named
`span` field on `Visibility::Restricted` and a positional field on
`Public` and `Crate`. This was ... not so uniform.)
Diffstat (limited to 'src/libstd/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions