Skip to content

Commit

Permalink
Latest docs on successful build 6125 auto-pushed to gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
copybara-service[bot] committed Apr 2, 2024
1 parent b3430c8 commit 78ac580
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion bugpattern/RestrictedApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,17 @@ To make changes, edit the @BugPattern annotation or the explanation in docs/bugp


## The problem
Calls to APIs marked @RestrictedApi are prohibited without a corresponding
Calls to APIs marked `@RestrictedApi` are prohibited without a corresponding
allowlist annotation.

The intended use-case for `@RestrictedApi` is to restrict calls to annotated
methods so that each usage of those APIs must be reviewed separately. For
example, an API might lead to security bugs unless the programmer uses it
correctly.

See the
[javadoc for `@RestrictedApi`](https://errorprone.info/api/latest/com/google/errorprone/annotations/RestrictedApi.html)
for more details.

## Suppression
Suppress false positives by adding the suppression annotation `@SuppressWarnings("RestrictedApi")` to the enclosing element.

0 comments on commit 78ac580

Please sign in to comment.