If you develop a library in Java and use it from Kotlin, the built-in Kotlin null-safety will recognize the JSpecify annotations on the library.
Null-restricted types are on the roadmap. See: https://openjdk.org/jeps/8303099
659 karma · joined January 27, 2012
If you develop a library in Java and use it from Kotlin, the built-in Kotlin null-safety will recognize the JSpecify annotations on the library.
Null-restricted types are on the roadmap. See: https://openjdk.org/jeps/8303099
POTS = Plain Old Telephony System COTS = Commercial Off-The-Shelf
Update: And mainline support and lack of proprietary boot blobs are two separate criteria. I've heard that NXP offers the former but not the latter.
[1] https://www.collabora.com/news-and-blog/blog/2024/02/21/almo...
https://en.wikipedia.org/wiki/Market_share
There are multiple methods of measuring multiple (related) things. What you are describing sounds more like the share of the installed base, which only works for certain types of products. (i.e. it doesn't work for consumables like apples or electricity)
I did however, find this humorous anecdote:
> A Lotus executive later joked, "The first month we shipped 62,000 copies, and the following month we got 64,000 copies back. It was such a failure they sent us the bootlegged copies back."
Exactly. That's the way accounting works. They did not know in the previous quarter that the product would be returned in the following quarter, so they end up having negative sales in the current quarter.
Yes it produces "garbage output", which I find amusing.
At one point in the late 1980's Microsoft had a GREATER than 100% market share of the Macintosh spreadsheet market.
How is this possible?
Market share (for a given period) is the participant's sales in the market divided by total sales. It just so happened that Lotus had more returns than sales of their failed spreadsheet, Lotus Jazz. So Lotus, had a negative market share and Microsoft had more sales of Excel than total sales in the market, resulting in a greater than 100% market share.
I don't remember the exact numbers and I believe there was at least one other competitor in the study. But let's just say the numbers were:
Microsoft: 102% Lotus: -2%
In that case the Herfindahl–Hirschman Index would be 102^2 + (-2)^2 = 10404 + 4 = 10408.
So, in this pathological case it is possible for the HHI to exceed 10,000.
Edited: Added (for a given period) above, for clarity.
The article focuses on a comparison between GUIX _system_ and NixOS. It would be interesting to see an equally thoughtful comparison that just focuses on GUIX vs. NIX as package managers used on another Linux distribution (e.g. Debian.)
In this case, GUIX might fare better as you won't have to worry about the complexities introduced by binary blobs needed for boot, etc.
If you search for pictures of "Original Lisa Keyboard" you can see that the layout is the same. However, in the pictures I found the key that corresponds to the small '=' in the screenshot in the article is labelled '-' and there appear to be some other differences. I don't remember these differences or any rationale for them.
Update: They screenshot in the article exactly matches the Macintosh Plus keyboard -- which is a keyboard I actually owned. Although I used Mac XL before getting my Plus, it's probably this keyboard that I'm remembering:
https://en.wikipedia.org/wiki/Apple_keyboards#Macintosh_Plus...
void main() {
IO.println("Hello, World!");
}
JEP 445 has been followed by JEP 512 which contained minor improvements and finalizes the feature [2].If you want to use 3rd-party libraries, I highly recommend trying JBang [3].
[1] https://jdk.java.net/25/release-notes
void main() {
CompletableFuture<String> future = CompletableFuture.supplyAsync(this::asyncMethod);
future.thenAccept(result -> IO.println(result));
IO.println("Prints first"); // prints before the async result
future.join(); // Wait for future to complete
}
String asyncMethod() {
try {
Thread.sleep(10000);
} catch (InterruptedException e) {
return "Interrupted";
}
return "Data Fetched";
}
I made the following changes:1. Move the asynchronous function called in the CompletableFuture to its own method
2. Use Java 25 "instance main method" (see JEP 25: https://openjdk.org/jeps/512)
3. Use Java 25 IO.println() to simplify console output
4. Instead of throwing a fatal exception on interruption, return "Interrupted" immediately.
5. Use future.join() so the main method waits for the future to complete and the "Data fetched" output is printed.
This program can be run directly from source with `java Example.java`. (If you're using Java 24 or a version of Java 25 prior to EA 22, you need to use `java --enable-preview Example.java`)
Here is a modified version of the example that interrupts the thread:
void main() {
ExecutorService executor = Executors.newSingleThreadExecutor();
CompletableFuture<String> future = CompletableFuture.supplyAsync(this::asyncMethod, executor);
future.thenAccept(result -> IO.println(result));
IO.println("Prints first"); // prints before the async result
executor.shutdownNow();
future.join(); // Wait for future to complete
}
String asyncMethod() {
try {
Thread.sleep(10000);
} catch (InterruptedException e) {
return "Interrrupted";
}
return "Data Fetched";
}"Regulation by enforcement" has been a real thing and a bad thing. You can't expect people to obey the law if you won't tell them what it is.
I would like to see the government prosecute actual fraud, so if the article goes on to say they will not prosecute that, then maybe the headline is accurate.
If you a writing libraries for the JVM, Java is preferred to Kotlin because it does not drag along a standard library dependency.
To be fair there is Kotlin Multiplatform where this is not the case. https://kotlinlang.org/docs/multiplatform.html
I think you were proven right at least a decade ago. As you said, this is just the final whimper.