This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch release in repository https://gitbox.apache.org/repos/asf/commons-lang.git
The following commit(s) were added to refs/heads/release by this push: new c56be9c Format tweak. c56be9c is described below commit c56be9c3ddbcaefac9dcc720238462cfc529fc06 Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Thu Jul 16 19:23:10 2020 -0400 Format tweak. --- src/main/java/org/apache/commons/lang3/ClassUtils.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/org/apache/commons/lang3/ClassUtils.java b/src/main/java/org/apache/commons/lang3/ClassUtils.java index a6d1d1d..11c71bd 100644 --- a/src/main/java/org/apache/commons/lang3/ClassUtils.java +++ b/src/main/java/org/apache/commons/lang3/ClassUtils.java @@ -82,6 +82,7 @@ public class ClassUtils { * Maps names of primitives to their corresponding primitive {@code Class}es. */ private static final Map<String, Class<?>> namePrimitiveMap = new HashMap<>(); + static { namePrimitiveMap.put("boolean", Boolean.TYPE); namePrimitiveMap.put("byte", Byte.TYPE); @@ -98,6 +99,7 @@ public class ClassUtils { * Maps primitive {@code Class}es to their corresponding wrapper {@code Class}. */ private static final Map<Class<?>, Class<?>> primitiveWrapperMap = new HashMap<>(); + static { primitiveWrapperMap.put(Boolean.TYPE, Boolean.class); primitiveWrapperMap.put(Byte.TYPE, Byte.class); @@ -114,6 +116,7 @@ public class ClassUtils { * Maps wrapper {@code Class}es to their corresponding primitive types. */ private static final Map<Class<?>, Class<?>> wrapperPrimitiveMap = new HashMap<>(); + static { for (final Map.Entry<Class<?>, Class<?>> entry : primitiveWrapperMap.entrySet()) { final Class<?> primitiveClass = entry.getKey(); @@ -133,6 +136,7 @@ public class ClassUtils { * Maps an abbreviation used in array class names to corresponding primitive class name. */ private static final Map<String, String> reverseAbbreviationMap; + // Feed abbreviation maps static { final Map<String, String> m = new HashMap<>();