feat(Tactic/Translate): warn when adding a docstring to an existing declaration#41883
feat(Tactic/Translate): warn when adding a docstring to an existing declaration#41883gasparattila wants to merge 3 commits into
Conversation
PR summary 457f039fa3Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
JovanGerb
left a comment
There was a problem hiding this comment.
Thanks for making the PR. I would be in favour of an even stronger restriction: if the translation already exists, then we should always give this warning, whether or not there is already a doc-string. Because it is better to give the docstring immediately, rather than later via to_additive.
| /-- An optional doc string. -/ | ||
| doc : Option String := .none | ||
| /-- An optional doc string, together with its `Syntax` for logging warnings. -/ | ||
| doc : Option (String × Syntax) := .none |
There was a problem hiding this comment.
It would make more sense to just store the Option Syntax, because we can simply get the string from the syntax.
There was a problem hiding this comment.
See #41886, which removes the deprecated "docstring" syntax and makes this field an Option (TSyntax _).
fbb2e5a to
457f039
Compare
|
This PR/issue depends on: |
@[to_additive "docstring"]syntax #41886