Closed
Description
The compiler does not warn about annotations it does not recognize. I recently noticed some code annotated with several instances of #[incline]
. Those annotations had been sitting there unnoticed for over a year. It would be nice if the compiler would emit a warning.
As discussed on IRC, one way this might be implemented would be marking annotations as 'used' when they are used, and then do a pass very late in compilation that checks for unused annotations. This would free the lint pass from having a list of valid annotations and their semantics.