-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Document -Zcache-proc-macros
#151227
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
base: main
Are you sure you want to change the base?
Document -Zcache-proc-macros
#151227
Conversation
|
Is there a tracking issue? |
If there isn't one, we should create one and link it from the new page. |
| @@ -0,0 +1,3 @@ | |||
| ## `cache-proc-macros` | |||
|
|
|||
| This option instructs `rustc` to cache (derive) proc-macro invocations using the incremental system. Note that this can be unsouned - we currently do not check if the macro invocation is actually "cacheable" or not. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| This option instructs `rustc` to cache (derive) proc-macro invocations using the incremental system. Note that this can be unsouned - we currently do not check if the macro invocation is actually "cacheable" or not. | |
| This option instructs `rustc` to cache (derive) proc-macro invocations using the incremental system. Note that this can be unsound - we currently do not check if the macro invocation is actually "cacheable" or not. |
also, about the "we currently do not check" part, is the plan is to infer whether the proc-macro is cacheable (seems unlikely), or rather respect what the user promises about its behavior? This could just mention that enabling the flag for proc-macros that are not pure functions is bound to reuse stale extensions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rather respect what the user promises about its behavior?
That is the plan, I suppose? There were a lot of proposals for this, but I don't think we have a winner :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AFAICT
d552bac to
345e9a0
Compare
|
Created a tracking issue, mentioned it in the docs and reworded the cacheability aspect. |
Forgot about this in #145354.
Created a tracking issue in #151364.