Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move core::task::local_data to core::local_data #6306

Closed
brson opened this issue May 7, 2013 · 5 comments
Closed

Move core::task::local_data to core::local_data #6306

brson opened this issue May 7, 2013 · 5 comments
Labels
A-runtime Area: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflows C-cleanup Category: PRs that clean code up or issues documenting cleanup.

Comments

@brson
Copy link
Contributor

brson commented May 7, 2013

Local data is probably going to be available outside of tasks.

@brson
Copy link
Contributor Author

brson commented May 7, 2013

Nominating backward compat.

@brson
Copy link
Contributor Author

brson commented May 9, 2013

@graydon had some reservations about this. He is concerned that people should know whether they are getting task-local data or thread-local data. I don't think of it like that though - more as 'language-local' data. The language itself and a number of tightly integrated services expect access to 'local' things. This has always meant task-local in the past, but I am trying to make the required runtime as minimal as possible, primarily by factoring out these services in a way that they can be accessible without tasks. One of them is task-local data.

It's possible that task-local data is not one of these requires services though (it's not as important as the heap) and could only be accessible from inside a task. We could also expose the API through two different paths so that you have to specify which one you want. We wouldn't do that for other local services though, e.g. fail!(), log!().

@brson
Copy link
Contributor Author

brson commented May 9, 2013

Ah, the reason local data is required outside of tasks is because conditions use TLS and I/O uses conditions and I/O (the blocking implementations) should be usable outside of tasks.

@graydon
Copy link
Contributor

graydon commented May 9, 2013

accepted for backwards-compatibility milestone

bors added a commit that referenced this issue May 10, 2013
@alexcrichton
Copy link
Member

Closing because of commit 6da2c98.

flip1995 added a commit to flip1995/rust that referenced this issue Dec 6, 2020
add `internal-lints` feature to enable clippys internal lints (off by default)

This PR moves the internal lint tests into a new subdirectory (I couldn't find a different way to compile-time-conditionally exclude them from compiletest) and only builds and tests internal lints if the `internal-lints` feature is enabled.

Fixes rust-lang#6306

changelog: put internal lints behind a feature ("internal-lints")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-runtime Area: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflows C-cleanup Category: PRs that clean code up or issues documenting cleanup.
Projects
None yet
Development

No branches or pull requests

3 participants