diff options
| author | Tomas Tauber <2410580+tomtau@users.noreply.github.com> | 2019-09-14 10:06:05 +0800 |
|---|---|---|
| committer | Tomas Tauber <tomtau@connect.hku.hk> | 2019-09-15 13:35:02 +0800 |
| commit | df7789c902eb198a107422dd8e4e4c81ec3cb6ad (patch) | |
| tree | 6c1384f5fc4a8f403cf10aec258f00bae293f07b /src/libstd/thread | |
| parent | 572d3d9634b253bdd85af32380b10d1f7d189cdb (diff) | |
| download | rust-df7789c902eb198a107422dd8e4e4c81ec3cb6ad.tar.gz rust-df7789c902eb198a107422dd8e4e4c81ec3cb6ad.zip | |
Made a thread local storage panic message more explanatory
(TLS is usually understood as Transport Layer Security outside rust-std internals)
Diffstat (limited to 'src/libstd/thread')
| -rw-r--r-- | src/libstd/thread/local.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/thread/local.rs b/src/libstd/thread/local.rs index f85b5d632f1..a2bbe371de7 100644 --- a/src/libstd/thread/local.rs +++ b/src/libstd/thread/local.rs @@ -236,8 +236,8 @@ impl<T: 'static> LocalKey<T> { #[stable(feature = "rust1", since = "1.0.0")] pub fn with<F, R>(&'static self, f: F) -> R where F: FnOnce(&T) -> R { - self.try_with(f).expect("cannot access a TLS value during or \ - after it is destroyed") + self.try_with(f).expect("cannot access a Thread Local Storage value \ + during or after it is destroyed") } /// Acquires a reference to the value in this TLS key. |
