Skip to content

Commit

Permalink
Make emptyList public and mark the public EMPTY field as deprecated.
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 495154966
  • Loading branch information
protobuf-github-bot authored and Copybara-Service committed Dec 14, 2022
1 parent bfed218 commit c658e27
Showing 1 changed file with 8 additions and 3 deletions.
Expand Up @@ -67,12 +67,17 @@ public class LazyStringArrayList extends AbstractProtobufList<String>
EMPTY_LIST.makeImmutable();
}

static LazyStringArrayList emptyList() {
/** Returns an empty immutable {@code LazyStringArrayList} instance */
public static LazyStringArrayList emptyList() {
return EMPTY_LIST;
}

// For compatibility with older runtimes.
public static final LazyStringList EMPTY = EMPTY_LIST;
/**
* For compatibility with older runtimes.
*
* @deprecated use {@link emptyList()} instead
*/
@Deprecated public static final LazyStringList EMPTY = EMPTY_LIST;

private final List<Object> list;

Expand Down

0 comments on commit c658e27

Please sign in to comment.