[Info-vax] OpenVMS system programming language
Arne Vajhøj
arne at vajhoej.dk
Mon Feb 24 14:37:54 EST 2025
On 2/24/2025 2:10 PM, Simon Clubley wrote:
> On 2025-02-23, Scott Dorsey <kludge at panix.com> wrote:
>> Lawrence D'Oliveiro <ldo at nz.invalid> wrote:
>>> On Thu, 19 Dec 2024 15:56:43 +0900, David Meyer wrote:
>>>> Have all the MACRO and BLISS programs been ported to C or C++, or will
>>>> they be in the future?
>>>
>>> I hear there is this new language called “Javaâ€, that is supposed to take
>>> over from C++ ...
>>
>> When Java first came out, I had this image in my head of a bunch of
>> managers sitting around a table asking "What can we do to make computers
>> more slow? How can we sell people on more expensive hardware?" "I know,
>> we can get the UCSD P-System for the new millennium!"
>
> As Arne is well aware, my number one issue with Java is how the bloody
> ^&^%*& JNI interface was designed. It's utter crap, especially when you
> are trying to get it working on Android. There is a replacement in the
> works, but you still have legacy device issues to deal with so that
> will not really make a difference for a few years
JNI is very cumbersome to work with.
But I think that the design made sense back in the late 90's. Back then
it needed to be very efficient and there were lots of C developers
and no Java developers. So it was decided that the glue code should
be written in C/C++.
IT has changed since then. And JNI is an obsolete design.
On Windows or Linux you can use JNA to be able to write the
glue code in Java. I believe it is also available for Android.
On VMS you can use my VMSCALL library that does VMS calling
convention in Java.
And Java 16 (preview) / 22 (final) added Java Foreign Function,
which added a standardized way to do it.
I wonder whether we will get the preview in Java 17 on VMS or
we will have to wait for final in Java 25 or whatever.
> My number two issue is the lack of actual unsigned integers in Java.
> Some hacks have been added to later Java versions to support unsigned integer
> operations, but it's still signed integers at the core as I understand it.
The lack of unsigned integers is a PITA.
And they could have done it. Kotlin added unsigned integers (first as
experimental and then fully in version 1.5).
But if you are writing Android code, then you should use Kotlin!
I can think about a few other problems though.
The decision to implement generics in a backwards compatible
way in Java 5 had some immediate benefits, but we are also
paying the price today.
Arne
More information about the Info-vax
mailing list