Skip to content

Commit

Permalink
Update ClientEnvironmentFunction.Key to use @AutoCodec.Interner i…
Browse files Browse the repository at this point in the history
…nstead of `@AutoCodec.Instantiator`.

PiperOrigin-RevId: 600530886
Change-Id: I7f4bed967ef993309ea83585fc05d9d05fd221ab
  • Loading branch information
Googler authored and copybara-github committed Jan 22, 2024
1 parent 6d579e4 commit 84dd8c1
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,16 @@ private Key(String arg) {
super(arg);
}

@VisibleForSerialization
@AutoCodec.Instantiator
static Key create(String arg) {
private static Key create(String arg) {
return interner.intern(new Key(arg));
}

@VisibleForSerialization
@AutoCodec.Interner
static Key intern(Key key) {
return interner.intern(key);
}

@Override
public SkyFunctionName functionName() {
return SkyFunctions.CLIENT_ENVIRONMENT_VARIABLE;
Expand Down

0 comments on commit 84dd8c1

Please sign in to comment.