8301190: [vectorapi] The typeChar of LaneType is incorrect when default locale is tr

Reviewed-by: psandoz
This commit is contained in:
Glavo 2023-01-27 01:17:02 +00:00 committed by Paul Sandoz
parent 7eff578768
commit c3ff151457

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2019, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2019, 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
@ -65,7 +65,7 @@ enum LaneType {
// int:128 or int:4 or float:16, report the size in the
// printName. If we do unsigned or vector or bit lane types,
// report that condition also.
this.typeChar = printName.toUpperCase().charAt(0);
this.typeChar = genericElementType.getSimpleName().charAt(0);
assert("FDBSIL".indexOf(typeChar) == ordinal()) : this;
// Same as in JVMS, org.objectweb.asm.Opcodes, etc.:
this.basicType = basicType;