Skip to content
Permalink
Browse files
8247115: Fix typos in java.lang.invoke and java.lang
Reviewed-by: lancea
  • Loading branch information
pavelrappo committed Jun 9, 2020
1 parent 3df95aa commit 6e43cddad779f59b06df0edd40b7db0ef8f0e5d3
Showing 11 changed files with 18 additions and 18 deletions.
@@ -2659,7 +2659,7 @@ public static double scalb(double d, int scaleFactor) {
* round it away to zero. This is done by first multiplying
* by 2 ^ (scaleFactor % n) and then multiplying several
* times by 2^n as needed where n is the exponent of number
* that is a covenient power of two. In this way, at most one
* that is a convenient power of two. In this way, at most one
* real rounding error occurs. If the double value set is
* being used exclusively, the rounding will occur on a
* multiply. If the double-extended-exponent value set is
@@ -1046,7 +1046,7 @@ public static Version parse(String s) {
} else {
if (optional.isPresent() && !pre.isPresent()) {
throw new IllegalArgumentException("optional component"
+ " must be preceeded by a pre-release component"
+ " must be preceded by a pre-release component"
+ " or '+': '" + s + "'");
}
}
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2020, 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
@@ -237,7 +237,7 @@ private void close() {
final R walk() {
checkState(NEW);
try {
// VM will need to stablize the stack before walking. It will invoke
// VM will need to stabilize the stack before walking. It will invoke
// the AbstractStackWalker::doStackWalk method once it fetches the first batch.
// the callback will be invoked within the scope of the callStackWalk frame.
return beginStackWalk();
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2020, 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
@@ -351,7 +351,7 @@ private final MethodType transformHelperType(int whichtm) {
* You can override this to return null or throw if there are no transforms.
* This method exists so that the transforms can be "grown" lazily.
* This is necessary if the transform *adds* a field to an instance,
* which sometimtes requires the creation, on the fly, of an extended species.
* which sometimes requires the creation, on the fly, of an extended species.
* This method is only called once for any particular parameter.
* The species caches the result in a private array.
*
@@ -35,7 +35,7 @@
/**
* An indirect var handle can be thought of as an aggregate of the method handles implementing its supported access modes.
* Its varform contains no method name table (given that some of the method handles composing a bound var handle might
* not be direct). The set of method handles constituting an inditrect var handle are retrieved lazily, to minimize
* not be direct). The set of method handles constituting an indirect var handle are retrieved lazily, to minimize
* code spinning (since not all the access modes will be used anyway).
* Indirect var handles are useful when constructing var handle adapters - that is, an adapter var handle
* can be constructed by extracting the method handles constituting the target var handle, adapting them
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2020, 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
@@ -801,7 +801,7 @@ boolean isLoop(int pos) {
* (a) redundant compilation work and (b) extra I$ pressure.
* To control repeated versions, we need to be ready to
* erase details from LFs and move them into MH data,
* whevener those details are not relevant to significant
* whenever those details are not relevant to significant
* optimization. "Significant" means optimization of
* code that is actually hot.
*
@@ -895,7 +895,7 @@ void compileToBytecode() {
private static boolean argumentTypesMatch(String sig, Object[] av) {
int arity = signatureArity(sig);
assert(av.length == arity) : "av.length == arity: av.length=" + av.length + ", arity=" + arity;
assert(av[0] instanceof MethodHandle) : "av[0] not instace of MethodHandle: " + av[0];
assert(av[0] instanceof MethodHandle) : "av[0] not instance of MethodHandle: " + av[0];
MethodHandle mh = (MethodHandle) av[0];
MethodType mt = mh.type();
assert(mt.parameterCount() == arity-1);
@@ -1685,7 +1685,7 @@ MethodHandle withInternalMemberName(MemberName member, boolean isInvokeSpecial)
if (member != null) {
return MethodHandleImpl.makeWrappedMember(this, member, isInvokeSpecial);
} else if (internalMemberName() == null) {
// The required internaMemberName is null, and this MH (like most) doesn't have one.
// The required internalMemberName is null, and this MH (like most) doesn't have one.
return this;
} else {
// The following case is rare. Mask the internalMemberName by wrapping the MH in a BMH.
@@ -33,7 +33,7 @@

/**
* A symbolic reference obtained by cracking a direct method handle
* into its consitutent symbolic parts.
* into its constituent symbolic parts.
* To crack a direct method handle, call {@link Lookup#revealDirect Lookup.revealDirect}.
* <h2><a id="directmh"></a>Direct Method Handles</h2>
* A <em>direct method handle</em> represents a method, constructor, or field without
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2008, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2008, 2020, 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
@@ -510,7 +510,7 @@ static MemberName linkMethodTracing(Class<?> callerClass, int refKind,
/**
* Obtain the method to link to the VarHandle operation.
* This method is located here and not in Invokers to avoid
* intializing that and other classes early on in VM bootup.
* initializing that and other classes early on in VM bootup.
*/
private static MemberName varHandleOperationLinkerMethod(String name,
MethodType mtype,
@@ -105,7 +105,7 @@
* A {@code MethodType} can be described in {@linkplain MethodTypeDesc nominal form}
* if and only if all of the parameter types and return type can be described
* with a {@link Class#describeConstable() nominal descriptor} represented by
* {@link ClassDesc}. If a method type can be described norminally, then:
* {@link ClassDesc}. If a method type can be described nominally, then:
* <ul>
* <li>The method type has a {@link MethodTypeDesc nominal descriptor}
* returned by {@link #describeConstable() MethodType::describeConstable}.</li>
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 2020, 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
@@ -2031,7 +2031,7 @@ private final MethodHandle getMethodHandleUncached(int mode) {
insertParameterTypes(0, VarHandle.class);
MemberName mn = vform.getMemberName(mode);
DirectMethodHandle dmh = DirectMethodHandle.make(mn);
// Such a method handle must not be publically exposed directly
// Such a method handle must not be publicly exposed directly
// otherwise it can be cracked, it must be transformed or rebound
// before exposure
MethodHandle mh = dmh.copyWith(mt, dmh.form);
@@ -2191,7 +2191,7 @@ private VarHandleDesc(Kind kind, String name, ClassDesc declaringClass, ClassDes
* Returns a {@linkplain VarHandleDesc} corresponding to a {@link VarHandle}
* for an instance field.
*
* @param name the unqualifed name of the field
* @param name the unqualified name of the field
* @param declaringClass a {@link ClassDesc} describing the declaring class,
* for field var handles
* @param fieldType a {@link ClassDesc} describing the type of the field

0 comments on commit 6e43cdd

Please sign in to comment.