Skip to content

Commit

Permalink
8312414: Make java.util.ServiceLoader.LANG_ACCESS final
Browse files Browse the repository at this point in the history
Reviewed-by: alanb, jpai
  • Loading branch information
Andrey Turbanov committed Jul 21, 2023
1 parent d55d7e8 commit f4ba7b2
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/java.base/share/classes/java/util/ServiceLoader.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2022, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2023, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -422,10 +422,7 @@ public final class ServiceLoader<S>
// Incremented when reload is called
private int reloadCount;

private static JavaLangAccess LANG_ACCESS;
static {
LANG_ACCESS = SharedSecrets.getJavaLangAccess();
}
private static final JavaLangAccess LANG_ACCESS = SharedSecrets.getJavaLangAccess();

/**
* Represents a service provider located by {@code ServiceLoader}.
Expand Down

1 comment on commit f4ba7b2

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.