Hi Paul,
about the API part (not the implementation),
there are location where the same concept is described with a different names
which doesn't help to understand how thing work
- vector length <=> vector lane count
- vector shape <=> vector bits size
- element size <=> lane size
"size" should
BTW, did you try to add an intermediary private non visible class between
Vector and IntVector to avoid all hand-written cast inside the implementation
of IntVector,
something along that line
public abstract class Vector {
abstract void foo(Vector vector);
abstract Vector bar();
}
Hi Maurizio, Mandy,
In
https://cr.openjdk.java.net/~mcimadamore/8243491_v2/webrev/src/java.base/share/classes/java/lang/invoke/MemoryAccessVarHandleGenerator.java.udiff.html,
using a condy inside a static init make me sad,
using a late loading constant to early load it in the static init seems co
Hallo !
This questions have been asked so many times since 1998,
Josh Bloch one of the designer of the API (who will later write Effective Java)
as created a FAQ around that time answering to that question:
https://docs.oracle.com/javase/8/docs/technotes/guides/collections/designfaq.html
Googl
- Mail original -
> De: "David Holmes"
> À: "Harold David Seigel" , "hotspot-runtime-dev"
> ,
> "amber-dev" , "core-libs-dev"
> , "serviceability-dev"
>
> Envoyé: Mardi 19 Mai 2020 07:26:38
> Objet: Re: RFR: JDK-8225056 VM support for sealed classes
> Hi Harold,
>
> Adding servicea
- Mail original -
> De: "Paul Sandoz"
> À: "Claes Redestad"
> Cc: "core-libs-dev"
> Envoyé: Vendredi 22 Mai 2020 19:28:39
> Objet: Re: RFR: 8245455: Remove alternative StringConcatFactory strategies
> Hi,
>
> I support the removal of all the other strategies to simplify SCF and make it
Hi Claes,
do you have evaluated the improvement (1) in separation of the others ?
(2) or (3) are clearly improvement but (1) is a trade of because you are adding
a second lookup into another table and make prepender() less likely to be
inlined.
Rémi
- Mail original -
> De: "Claes Redes
Hi Claes,
so instead of having a prefix and a suffix, there is only a prefix, a suffix
being seen as a prefix for the next iteration
and if at the end instead of just allocating an array, you allocate an array
and stuff it with the last prefix.
Are you sure having a suffix at the end is uncommon
Hi Claes,
For the code below the comment "Mock the recipe to reuse the concat generator
code",
i believe you can use String.repeat() that was introduced recently.
The code that parse the the receipe can be in its own method to make the code
more readable,
this method returns the list and use the
yep,
the inference is not smart enough.
So the way to fix the code is either to explicitly specify the type arguments
var rs1 = x.entrySet().stream().sorted(
Map.Entry.comparingByValue().reversed()
);
or to store the result of comparingByValue() in a variable (so it's a poly
express
- Mail original -
> De: "Tagir Valeev"
> À: "Attila Szegedi"
> Cc: "core-libs-dev"
> Envoyé: Mardi 9 Juin 2020 09:05:42
> Objet: Re: Comparator.reversed() type inference issue
> Hello!
>
> This is more related to Java language specification and implementation
> than to core libraries,
Hi Mndy,
Looks good,
I don't like too much the fact that there is a new boolean field in j.l.r.Field
instead of using the modifiers like in the VM counterpart,
but it will require masking and unmasking the modifiers which is a far bigger
change, too big to worth it in my opinion.
So +1
Rémi
--
Hi Peter,
is their a reason to not use a ClassValue using the record class
as key instead of the more complex keys you are proposing ?
Rémi
- Mail original -
> De: "Chris Hegarty"
> À: "Peter Levart"
> Cc: "core-libs-dev"
> Envoyé: Mardi 16 Juin 2020 17:15:03
> Objet: Re: RFR: 8247532
Hi Sergei,
the problem is that you are changing the semantics if there are several fields.
By example with the code below, you have the guarantee that the code will print
4 (if it prints something),
if you remove the assignment field = false, the code can print 0 or 4.
class A {
int i = 4;
Hi Patrick,
- Mail original -
> De: "Patrick Concannon"
> À: "core-libs-dev"
> Envoyé: Mercredi 24 Juin 2020 12:57:01
> Objet: RFR[8238286]: 'Add new flatMap stream operation that is more amenable
> to pushing’
> Hi,
Hi,
>
> Could someone please review myself and Julia's RFE and CS
- Mail original -
> De: "Remi Forax"
> À: "Daniel Fuchs"
> Cc: "Patrick Concannon" , "core-libs-dev"
>
> Envoyé: Jeudi 25 Juin 2020 23:46:08
> Objet: Re: RFR[8238286]: 'Add new flatMap stream operation that is more
>
- Mail original -
> De: "Christoph Dreis"
> À: "hotspot-runtime-dev"
> Envoyé: Samedi 27 Juin 2020 11:54:19
> Objet: Explicitly constructed NPE is showing (wrong) message
> Hi,
Hi Christoph,
>
> I hope this is the correct mailing list.
>
> The latest changes on JDK-8233014 to enable
Hi Patrick & Julia,
this version starts to look good.
I just don't understand why the new functional interfaces are not in
java.util.function like the other ones ?
(BTW, in the javadoc, the link to the summary overview point to the wrong one,
to java.util.stream and not java.util.function).
Abo
- Mail original -
> De: "Maurizio Cimadamore"
> À: "Justin Dekeyser" , "core-libs-dev"
>
> Envoyé: Lundi 27 Juillet 2020 12:26:40
> Objet: Re: Type inference: bug or feature?
> CC'ing compiler-dev
>
> Hi Justin,
> the behavior you are observing is normal. For a Java expression to be
>
Hi Patrick,
I still don't like the fact that IntMapMultiConsumer, DoubleMapMultiConsumer
and LongMapMultiConsumer are not in java.util.function unlike all other
functional interfaces used by the Stream API.
Otherwise looks good.
regards,
Rémi
- Mail original -
> De: "Patrick Concannon"
- Mail original -
> De: "Attila Szegedi"
> À: "core-libs-dev"
> Envoyé: Jeudi 20 Août 2020 22:40:53
> Objet: Review request for JDK-8251538: Modernize and lint Dynalink code
> Following up on the previous e-mail, here’s the modernization and linting work
> on the existing Dynalink codeba
Hi Uwe,
- Mail original -
> De: "Uwe Schindler"
> À: "core-libs-dev"
> Envoyé: Samedi 5 Septembre 2020 13:55:03
> Objet: JDK 15 hidden classes & stack trace visibility
> Hi,
>
> I am doing a mockup for dynamically compiled scripts in Apache Lucene (later
> also painless scripting in el
- Mail original -
> De: "Nir Lisker"
> À: "core-libs-dev"
> Envoyé: Lundi 14 Septembre 2020 20:56:27
> Objet: 'Find' method for Iterable
> Hi,
>
> This has probably been brought up at some point. When we need to find an
> item in a collection based on its properties, we can either do it
- Mail original -
> De: "Jorn Vernee"
> À: "core-libs-dev"
> Envoyé: Lundi 26 Octobre 2020 16:37:20
> Objet: RFR: 8255398: Add a dropReturn MethodHandle combinator
> Hi,
>
> This patch adds a `dropReturn` combinator to `MethodHandles` that can be used
> to
> create a new method handle
- Mail original -
> De: "Stuart Marks"
> À: "core-libs-dev"
> Envoyé: Mardi 3 Novembre 2020 04:18:08
> Objet: RFR: 8180352: Add Stream.toList() method
> This change introduces a new terminal operation on Stream. This looks like a
> convenience method for Stream.collect(Collectors.toList(
- Mail original -
> De: "Martin Desruisseaux"
> À: "core-libs-dev"
> Envoyé: Mardi 3 Novembre 2020 23:16:49
> Objet: Re: RFR: 8180352: Add Stream.toList() method
> Hello
>
> Le 03/11/2020 à 21:30, fo...@univ-mlv.fr a écrit :
>
>> You know that you can not change the implementation of
>
- Mail original -
> De: "Stuart Marks"
> À: "core-libs-dev"
> Envoyé: Mercredi 4 Novembre 2020 01:14:54
> Objet: Re: RFR: 8180352: Add Stream.toList() method
> On Tue, 3 Nov 2020 18:53:23 GMT, Stuart Marks wrote:
>
>>> Should there be a test that tests the default implementation in
>>
- Mail original -
> De: "Simon Roberts"
> À: "core-libs-dev"
> Envoyé: Jeudi 5 Novembre 2020 18:40:44
> Objet: Re: RFR: 8180352: Add Stream.toList() method
> At the risk of a can of worms, or at least of raising something that has
> long since been discussed and rejected...
>
> This dis
Is it different from
headMap(key, true).size() / tailMap(key, true).size() ?
https://docs.oracle.com/en/java/javase/15/docs/api/java.base/java/util/NavigableMap.html#headMap(K,boolean)
https://docs.oracle.com/en/java/javase/15/docs/api/java.base/java/util/NavigableMap.html#tailMap(K,boolean)
che
Hi Mandy,
maybe a stupid question but why this mechanism is limited to hidden classes ?
regards,
Rémi
- Mail original -
> De: "Mandy Chung"
> À: "core-libs-dev" , "hotspot compiler"
>
> Envoyé: Mercredi 11 Novembre 2020 19:57:04
> Objet: RFR: 8230501: Class data support for hidden clas
- Mail original -
> De: "Brian Goetz"
> À: "Michael Kuhlmann" , "core-libs-dev"
>
> Envoyé: Mardi 17 Novembre 2020 20:44:17
> Objet: Re: 'Find' method for Iterable
> On 9/21/2020 4:08 AM, Michael Kuhlmann wrote:
>> But after thinking about it, I'm now convinced that it would be a bad
>>
An honest question,
why do we need so many interfaces for the different categories of
RandomGenerator ?
My fear is that we are encoding the state of our knowledge of the different
kinds of random generators now so it will not be pretty in the future when new
categories of random generator are d
- Mail original -
> De: "Florian Weimer"
> À: "Peter Levart"
> Cc: "Stuart Marks" , "core-libs-dev"
>
> Envoyé: Mercredi 18 Novembre 2020 12:55:02
> Objet: Re: RFR: 8180352: Add Stream.toList() method [v2]
> * Peter Levart:
>
>> But I see that the new IMM_LIST_NULLS type is needed fo
Hi Andy,
A code like this is not safe
try (Writer w = new BufferedWriter(new FileWriter( ...
because new BufferedWriter may throw an OutOfMemoryError, in that case the file
descriptor used by the FileWriter is not freed.
There are two ways to fix that, either you need to expand the
try-with-
Hi Kasper,
as usual, a getter on a volatile field will return a method handle that does a
volatile read.
The idea of the basic methodhandles, the one for field access, method calls,
etc is to have exactly the same semantics as the bytecode equivalent, so
unreflectGetter works like getfield and u
- Mail original -
> De: "John Rose"
> À: "Ioi Lam"
> Cc: "core-libs-dev" , "hotspot-runtime-dev"
>
> Envoyé: Lundi 24 Juin 2019 19:13:04
> Objet: Re: RFR: JDK-8222373 Improve CDS performance for custom class loaders
> On Jun 20, 2019, at 12:12 AM, Ioi Lam wrote:
>> ...
>> I have a
Is a boolean isEnded that records if end() was already called is not enough ?
Rémi
- Mail original -
> De: "Alan Bateman"
> À: "Jaikiran Pai" , "core-libs-dev"
>
> Envoyé: Jeudi 27 Juin 2019 09:13:41
> Objet: Re: Inputs on patch for JDK-8225763?
> On 27/06/2019 05:28, Jaikiran Pai wro
Hi Kasper,
did you store the StackWalker instance in a static final field ?
Rémi
- Mail original -
> De: "Kasper Nielsen"
> À: "core-libs-dev"
> Envoyé: Mardi 2 Juillet 2019 11:09:11
> Objet: Slow performance of StackWalker.getCallerClass() vs
> Reflection.getCallerClass()
> Hi,
>
>
It is intentional and the implementation details are planned to change in the
future
(there are already some patches in the valhalla/nestmates branch).
The slash in the name is because you can create several classes from the same
bytecode by patching it at runtime,
the number after the slash is
Hi Rob,
the problem is that if wrap() raises an exception before the wrapper is created
and returned, the resource will be never closed.
The correct way to fix the issue is to use several assignments in the
try-with-resources
try (FileInputStream fileInputStream = new FileInputStream("filename"
A follow up should to use constant dynamic (introduce in Java 11) to get the
j.l.r.Method object instead of pre-calculating all of them in the static init
block.
The idea is that a ldc on a constant dynamic with bootstrap method that takes a
MethodHandle as parameter (as boostrap argument) can r
This remember me something,
we should refactor most of the the package-private final methods (and the
corresponding constructors) at least inside java.lang/java.util to make them
private, there is no need to make them package-private anymore given that since
Java 11 the compiler emits nestmate a
Hi Goetz,
in bytecodeUtils.cpp, in print_local_var(),
i believe that the code
if (!method->is_static() && (slot == 0)) {
os->print("this");
}
...
is only true if the bytecode is generated by javac and ecj, tools like proguard
that tries to obfuscate the code will reuse the slot 0 once
- Mail original -
> De: "joe darcy"
> À: "Roger Riggs" , "core-libs-dev"
>
> Envoyé: Jeudi 19 Septembre 2019 21:39:54
> Objet: Re: JDK 14 RFR of JDK-8231202: Suppress warnings on non-serializable
> non-transient instance fields in
> serializable classes
> Hi Roger,
>
> I think the Obj
Hi Cyrus,
as the javadoc says RandomAccess is a marker interface,
an interface used at runtime to indicate if the implementation provides a fast
random access operation or not.
"marker interface" is the precursor of a runtime visible annotation.
RandomAccess was introduce in 1.4 while annotations
Looks good to me.
Remi
On October 28, 2019 10:29:58 PM UTC, mark.reinh...@oracle.com wrote:
>2019/10/28 11:10:25 -0700, vojin.jovano...@oracle.com:
>> This email proposes a change to the LambdaMetaFactory that allows to
>> disable eager initialization (with Unsafe) of generated lambdas. ...
>>
>
Hi David,
in java.lang.Thread interrupt0 should be renamed to setInterruptEvent, because
what it does now
and I don't really understand the comment in interrupted(), if a thread is
interrupted by two other threads calling interrupt(), you will loose an
interrupt anyway.
Rémi
- Mail origina
Hi Jim,
the rationale to add \ is well explain but why do you want to
introduce \s given we already have \u0020 ?
Rémi
- Mail original -
> De: "Jim Laskey"
> À: "core-libs-dev" , "compiler-dev"
>
> Envoyé: Mardi 5 Novembre 2019 19:00:32
> Objet: Re: RFR: CSR JDK-8233117 Escape Sequen
Hi Jorn, Claes,
Is it not better to always store in a local variable, like javac does, instead
of doing the double SWAP if there is a return value of size 1 ?
Rémi
- Mail original -
> De: "Jorn Vernee"
> À: "Claes Redestad" , "core-libs-dev"
>
> Envoyé: Mardi 12 Novembre 2019 15:56:0
- Mail original -
> De: "Gunnar Morling"
> À: "core-libs-dev"
> Envoyé: Mardi 19 Novembre 2019 09:34:41
> Objet: JEP 358 (Helpful NPEs) and single source file mode
> Hi,
>
> I've been exploring the new helpful NPE feature a bit.
>
> It's a very welcomed improvement, but I noticed one p
- Mail original -
> De: "Johannes Kuhn"
> À: "core-libs-dev"
> Envoyé: Vendredi 22 Novembre 2019 04:23:31
> Objet: Looking for Sponsor: JDK-8229959 Convert proxy class to use constant
> dynamic
> Hi everyone,
Hi Johannes,
>
> a few hours ago I signed the Oracle Contributor Agreement.
Hi Sergey,
hum, it doesn't work :)
int.class is compiled by javac as Integer.TYPE,
the opcode ldc only works with an object/interface class, not with a primitive
type [1].
regards,
Rémi
[1] https://docs.oracle.com/javase/specs/jvms/se13/html/jvms-6.html#jvms-6.5.ldc
- Mail original -
>
Nice !
there is a wikipedia article about WAVL tree [1].
I did not know this new kind of balanced tree, worth the exploration i believe.
and TreeMap code really needs some love anyway, unlike ArrayList and HashMap,
this code has not be updated since a long time.
Rémi
[1] https://en.wikipedia.or
Hi Maurizio,
that's a huge work :)
So as a guy discovering the API,
i've not taken a deep look to the implementation because i've noob questions.
The first sentence of the overview of GroupLayout should say that there are two
types of GroupLayout struct and union instead of talking about members
Hi Roman,
addAll() returns a boolean that will be not easy to compute given that
forEach() takes a lambda (that can only capture local values and not change
them).
and the javadoc of AbstractCollection clearly states that addAll has to use an
iterator if implemented
https://docs.oracle.com/en/j
Seem to be a JIT bug to me,
the fields of Set12 are declared final not @Stable (even if the field storing
the instanceof of Set&2 itself is marked @Stable) so there is no reason not not
let the constant folding happen.
Rémi
- Mail original -
> De: "Claes Redestad"
> À: "core-libs-dev"
- Mail original -
> De: "Joe Wang"
> À: "Daniel Fuchs" , "core-libs-dev"
>
> Envoyé: Jeudi 16 Janvier 2020 18:40:18
> Objet: Re: RFR [15/java.xml] 8235368 : Update BCEL to Version 6.4.1
> On 1/16/20 2:35 AM, Daniel Fuchs wrote:
>> Hi Joe,
>>
>> Looks OK to me as well.
>
> Thanks for th
Hi Robert,
first this is the wrong mailing list,
this mailing list is about how to implement the JDK, not how it works,
usually stackoverflow is better for the kind of questions you are asking.
- Mail original -
> De: "Robert Olofsson"
> À: "core-libs-dev"
> Envoyé: Vendredi 17 Janvier 2
- Mail original -
> De: "David Lloyd"
> À: "David Holmes"
> Cc: "hotspot-dev" , "core-libs-dev"
>
> Envoyé: Lundi 27 Janvier 2020 14:56:57
> Objet: Re: New candidate JEP: 371: Hidden Classes
> On Fri, Jan 24, 2020 at 4:56 PM David Holmes wrote:
>>
>> FYI.
>
> I'm a bit curious about
- Mail original -
> De: "Сергей Цыпанов"
> À: "jonathan gibbons" , "core-libs-dev"
>
> Envoyé: Mardi 4 Février 2020 08:53:31
> Objet: Re: [PATCH] Enhancement proposal for java.util.StringJoiner
> Hello,
Hi Sergey,
>
> I'd probably agree about a new class in java.lang, but what is wro
Stuart, Martin, Kiran,
I think this "bug" should not be fixed because it's one of the cases where
providing more information is actually bad from a user POV.
The current code throws NoSuchElementException when the iterator reach the end
so from the user POV, this is the right exception because
Hi Claes,
In ArchivedModuleGraph, there is no point to take the mainModule as parameter
given that it should always be null.
In ModuleLoaderMap, the constants PLATFORM_LOADER_INDEX and APP_LOADER_INDEX
should be moved inside the nested class Mapper given that there are only needed
by the Mapper
Hi Claes,
looks good,
it can be written in a less Doug Lea-ish way like this
V v = get(key);
return (v != null)? v: default;
I believe it using the same number of bytecodes :)
with a ALOAD instead of a DUP
Rémi
- Mail original -
> De: "Claes Redestad"
> À: "core-libs-dev"
> Envoyé
- Mail original -
> De: "向伟(识月)"
> À: "Florian Weimer"
> Cc: "core-libs-dev" , "hotspot-runtime-dev"
>
> Envoyé: Mercredi 26 Février 2020 13:45:52
> Objet: 回复:回复:VM crashed at StringTable expansion
> Hi Florian, Alan,
>
>public static void main(String[] args) throws Exception {
Hi Magnus,
please try not to use @SuppressWarnings("unchecked") on methods, but on local
variable instead to reduce the scope,
you can introduce a local variable for that.
In Bundle, your patch declare @SuppressWarnings("unchecked") on the method
while you already have a local variable with a @
Hi Mandy,
in ReflectionFactory, why in the case of a constructor the check to the
anonymous class is removed ?
in BytecodeGenerator, the comment "// bootstrapping issue if using condy"
can be promoted on top of clinit, because i ask myself the same question seeing
a static block was generated
i
- Mail original -
> De: "David Holmes"
> À: "mandy chung" , "Vicente Romero"
> , "jan lahoda"
>
> Cc: "serviceability-dev" , "hotspot-dev"
> ,
> "core-libs-dev" , "valhalla-dev"
>
> Envoyé: Samedi 28 Mars 2020 00:01:58
> Objet: Re: Review Request: 8238358: Implementation of JEP 371: H
Hi all,
it's a little bit OT even if the JDK itself as a dependency on ASM.
I'm proud to announce that ASM 8 (nicknamed the Quarantine Edition) was
released today !
It fully supports Java 14 (the Record attribute) and even support sealed types
(the attribute PermittedSubtypes) as an experimenta
- Mail original -
> De: "Stuart Marks"
> À: "joe darcy"
> Cc: "core-libs-dev"
> Envoyé: Dimanche 29 Mars 2020 04:37:06
> Objet: Re: JDK 15 RF(pre)R of JDK-8241374: add Math.absExact
> Hi Joe,
>
> Overall this looks quite good. Thanks for being thorough about this; I
> certainly
> woul
Ok, i've taking the time to read some literature about random generators
because for me the Mersenne Twister was still the king.
The current API proposed as clearly two levels, you have the user level and the
implementation level, at least the implementation level should seen as a SPI
RandomGe
- Mail original -
> De: "David Holmes"
> À: "Harold David Seigel" , "Vicente Romero"
> , "compiler-dev"
> , "core-libs-dev"
> , "hotspot-dev"
>
> Envoyé: Mardi 24 Novembre 2020 02:04:55
> Objet: Re: RFR: 8246778: Compiler implementation for Sealed Classes (Second
> Preview)
> Hi Harol
- Mail original -
> De: "Mandy Chung"
> À: "compiler-dev" , "core-libs-dev"
> , "hotspot-dev"
>
> Envoyé: Mercredi 25 Novembre 2020 00:02:53
> Objet: Re: RFR: 8246778: Compiler implementation for Sealed Classes (Second
> Preview)
> On Tue, 17 Nov 2020 00:25:51 GMT, Mandy Chung wrote:
- Mail original -
> De: "Stuart Marks"
> À: "core-libs-dev"
> Envoyé: Mardi 24 Novembre 2020 08:10:14
> Objet: Re: RFR: 8180352: Add Stream.toList() method [v4]
>> This change introduces a new terminal operation on Stream. This looks like a
>> convenience method for Stream.collect(Collec
Hi Mandy, hi all,
it seems that when defineAnonymousClass rewrites the currentClass, it doesn't
work if there is an invokedynamic in the classfile, so defineHiddenClass fails
with a VerifyError when the hidden class is verified.
Here is an example showing the issue
---
import java.io.IOException
I've forgotten a cast in an invokedynamic, hence a call to wrongTargetType,
but in order to create the error message, MethodType.toString(),
getSimpleName() is called and it fails because getDeclaringClass() verifies the
InnerClasses attribute.
For me InnerClasses was just an attribute for javac
- Mail original -
> De: "Dave Franken"
> À: "core-libs-dev"
> Envoyé: Mardi 8 Décembre 2020 13:17:25
> Objet: Has it been considered to add inverse methods to collections which are
> in Optional?
> Dear all,
Hi Dave,
>
> The class java.util.Optional could be considered a collection w
- Mail original -
> De: "Mandy Chung"
> À: "core-libs-dev" , "hotspot-dev"
>
> Envoyé: Mardi 8 Décembre 2020 23:57:39
> Objet: RFR: 8257596: Clarify trusted final fields for record classes
Hi Mandy,
> This is a follow-up on JDK-8255342 that removes non-specified JVM checks on
> classes
- Mail original -
> De: "Mandy Chung"
> À: "core-libs-dev" , "hotspot-runtime-dev"
>
> Envoyé: Mercredi 9 Décembre 2020 01:43:34
> Objet: Re: RFR: 8257596: Clarify trusted final fields for record classes
> On Tue, 8 Dec 2020 22:52:37 GMT, Mandy Chung wrote:
>
>> This is a follow-up on
A student of mine send me a code that can be reduced to this code
---
import java.lang.invoke.MethodHandles;
import java.lang.invoke.VarHandle;
public class ThereIsABugButWhere {
private static final VarHandle TEXT;
static {
try {
TEXT = MethodHandles.lookup().findVarHandle(ThereIs
Set.of() is the closest way we've got to a literal Set without having
introduced a special syntax for that in the language.
The idea is that if you conceptually want to write
Set set = { "hello", "world" };
instead, you write
Set set = Set.of("hello", "world");
In that context, it makes sens
- Mail original -
> De: "Johannes Kuhn"
> À: "core-libs-dev"
> Envoyé: Lundi 1 Février 2021 15:50:51
> Objet: JDK-6824466 java.lang.reflect.Method should use
> java.lang.invoke.MethodHandle
> While implementing a prototype for JDK-8242888 (Convert dynamic proxy to
> hidden classes) I ca
Hi Patrick,
"Iterable" is Ok as runtime type of the classical instanceof but not in a type
pattern where it is a raw type,
so
if (e instanceof Iterable elements) {
should be
if (e instanceof Iterable elements) {
regards,
Rémi
- Mail original -
> De: "Patrick Concannon"
> À: "core-l
Hi Loic,
You can use Optional.OfNullable() which is a kind of the general bridge between
the nullable world and the non-nullable one.
var fooOptional = Optional.ofNullable(System.getenv("FOO"));
var fooValue = fooOptional.orElse(defaultValue);
regards,
Rémi Forax
- Mail original -
or-using-the-optional-class-as-its-meant-to-be-used
yep, you are right.
Optional.ofNullable(...).orElse(...) is not the best pattern in term of
readability.
>
> Best,
> Michael
regards,
Rémi
>
> On 2/15/21 3:09 PM, Remi Forax wrote:
>> Hi Loic,
>> You can use Optional.OfNulla
- Mail original -
> De: "Attila Szegedi"
> À: "core-libs-dev"
> Envoyé: Dimanche 21 Février 2021 21:14:48
> Objet: Class.getRecordComponents security checks
> Hey folks,
>
> Why are security checks for Class.getRecordComponents as strict as those for
> e.g. getDeclaredMethods? I would’v
Hi Joe,
i think the overview of the package java.lang.reflect should discuss the fact
that the reflection view is what is stored in the classfile, not exactly a
reflection of the java code.
So depending on what you are requesting, you can see synthetic parameters
generated by javac or only the
- Mail original -
> De: "Bernd Eckenfels"
> À: "core-libs-dev"
> Cc: "jdk-dev"
> Envoyé: Jeudi 11 Mars 2021 02:12:49
> Objet: Re: New candidate JEP: 400: UTF-8 by Default
> I like it. The only thing which I feel is missing would be an official API to
> get the operating environments def
- Mail original -
> De: "Michael Kuhlmann"
> À: "core-libs-dev"
> Envoyé: Mercredi 24 Mars 2021 13:23:08
> Objet: Re: RFR: 8263668: Update java.time to use instanceof pattern variable
> On 3/24/21 12:09 PM, Rémi Forax wrote:
>> On Wed, 24 Mar 2021 09:56:16 GMT, Patrick Concannon
>> wrot
- Mail original -
> De: "Marcin Grzejszczak"
> À: "core-libs-dev"
> Envoyé: Vendredi 9 Avril 2021 16:29:32
> Objet: Instrumenting Executors - issues in Spring Cloud Sleuth and JDK16
> Hi!
>
> I'm the lead of Spring Cloud Sleuth [1], a project dedicated to working with
> distributed trac
- Mail original -
> De: "Jorn Vernee"
> À: "core-libs-dev"
> Envoyé: Vendredi 9 Avril 2021 12:51:53
> Objet: RFR: 8263087: Add a MethodHandle combinator that switches over a set
> of MethodHandles
> This patch adds a `tableSwitch` combinator that can be used to switch over a
> set
> of
> De: "John Rose"
> À: "Remi Forax"
> Cc: "Jorn Vernee" , "core-libs-dev"
>
> Envoyé: Samedi 10 Avril 2021 01:43:49
> Objet: Re: [External] : Re: RFR: 8263087: Add a MethodHandle combinator that
> switches over a set of MethodHandles
- Mail original -
> De: "Jorn Vernee"
> À: "core-libs-dev"
> Envoyé: Mardi 13 Avril 2021 16:59:58
> Objet: Re: RFR: 8263087: Add a MethodHandle combinator that switches over a
> set of MethodHandles
> On Thu, 8 Apr 2021 18:51:21 GMT, Jorn Vernee wrote:
>
>> This patch adds a `tableSwi
- Mail original -
> De: "Kengo TODA"
> À: "core-libs-dev"
> Envoyé: Mercredi 14 Avril 2021 11:03:14
> Objet: Re: ObjectMethods seems generating wrong methods for array-type field
Hello,
> I found that the JLS 16 does not cover the array type record component:
> https://docs.oracle.com/j
- Mail original -
> De: "Rafael Winterhalter"
> À: "core-libs-dev" , "serviceability-dev"
>
> Envoyé: Vendredi 16 Avril 2021 15:52:07
> Objet: RFR: 8200559: Java agents doing instrumentation need a means to define
> auxilary classes
> To allow agents the definition of auxiliary classes
- Mail original -
> De: "Stuart Marks"
> À: "core-libs-dev"
> Envoyé: Vendredi 16 Avril 2021 19:40:55
> Objet: ReversibleCollection proposal
> This is a proposal to add a ReversibleCollection interface to the Collections
> Framework. I'm looking for comments on overall design before I wo
- Mail original -
> De: "Stuart Marks"
> À: "core-libs-dev"
> Envoyé: Vendredi 16 Avril 2021 19:40:55
> Objet: ReversibleCollection proposal
> This is a proposal to add a ReversibleCollection interface to the Collections
> Framework. I'm looking for comments on overall design before I wo
- Mail original -
> De: "Stephen Colebourne"
> À: "core-libs-dev"
> Envoyé: Jeudi 22 Avril 2021 00:14:10
> Objet: Re: ReversibleCollection proposal
> On Wed, 21 Apr 2021 at 18:39, Stuart Marks wrote:
>> The value being provided here is that the ReversibleCollection interface
>> provides
- Mail original -
> De: "Stephen Colebourne"
> À: "core-libs-dev"
> Envoyé: Samedi 24 Avril 2021 00:14:51
> Objet: Re: New Collections interface - Sized
> On Fri, 23 Apr 2021 at 23:07, Brian Goetz wrote:
>> >> Is there a compelling example of where this would be used by clients?
>> > He
- Mail original -
> De: "Stephen Colebourne"
> À: "core-libs-dev"
> Envoyé: Vendredi 23 Avril 2021 11:23:03
> Objet: New Collections interface - Sized
> Hi all,
> While a discussion on ReversibleCollection is going on, I'd like to
> raise the interface I've always found most missing from
- Mail original -
> De: "Stuart Marks"
> À: "Peter Levart"
> Cc: "core-libs-dev" , "Stephen Colebourne"
>
> Envoyé: Mercredi 28 Avril 2021 02:04:22
> Objet: Re: ReversibleCollection proposal
> On 4/27/21 2:25 AM, Peter Levart wrote:
>> Right, I'm persuaded. Now if only the problems of
1 - 100 of 737 matches
Mail list logo