Skip to content

Commit f827ea9

Browse files
committed
Revert "Remove vendored proguard annotation (react#26069)"
This reverts commit 35fc0ad.
1 parent b356ac7 commit f827ea9

2 files changed

Lines changed: 22 additions & 1 deletion

File tree

ReactAndroid/build.gradle

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,6 @@ android {
356356

357357
dependencies {
358358
api("com.facebook.infer.annotation:infer-annotation:0.11.2")
359-
api("com.facebook.yoga:proguard-annotations:1.14.1")
360359
api("javax.inject:javax.inject:1")
361360
api("androidx.appcompat:appcompat:1.0.2")
362361
api("com.facebook.fresco:fresco:${FRESCO_VERSION}")
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/**
2+
* Copyright (c) Facebook, Inc. and its affiliates.
3+
*
4+
* <p>This source code is licensed under the MIT license found in the LICENSE file in the root
5+
* directory of this source tree.
6+
*/
7+
package com.facebook.proguard.annotations;
8+
9+
import static java.lang.annotation.RetentionPolicy.CLASS;
10+
11+
import java.lang.annotation.ElementType;
12+
import java.lang.annotation.Retention;
13+
import java.lang.annotation.Target;
14+
15+
/**
16+
* Add this annotation to a class, method, or field to instruct Proguard to not strip it out.
17+
*
18+
* <p>This is useful for methods called via reflection that could appear as unused to Proguard.
19+
*/
20+
@Target({ElementType.TYPE, ElementType.FIELD, ElementType.METHOD, ElementType.CONSTRUCTOR})
21+
@Retention(CLASS)
22+
public @interface DoNotStrip {}

0 commit comments

Comments
 (0)