News for hackers. Stuff that matters.
Re:Zig now has built-in HTTP server and client in std by lmm on Friday May 19, 2023 @02:48AM (#35998591)
> All those complains always forget that the standard library happens to be available everywhere the language has a full implementation available, while third party libraries are hit and miss.

Only if your dependency management is bad.

And if you're stuck running on e.g. an old install of the language, there's at least a chance that the third party library will support it, whereas if you want a new standard library feature you're SOL.

Re:Zig now has built-in HTTP server and client in std by pjmlp on Friday May 19, 2023 @03:01AM (#35998670)
All dependency managements are bad when they assume UNIX only workloads with C compilers pre-installed.

And on top of that download half of the Internet for doing an hello world with error handling or asynchronous code.

Re:Zig now has built-in HTTP server and client in std by JodieBenitez on Friday May 19, 2023 @04:16AM (#35999191)
> Only if your dependency management is bad.

Please give an example of good dependency management in any language. It seems to be one of these subjects draining constant displeasure.

I'm not advocating against third party libraries, I just think a reasonably rich standard library sets a good foundation for them.

Re:Zig now has built-in HTTP server and client in std by lmm on Friday May 19, 2023 @07:00AM (#36000117)
Maven has worked well for over a decade. I understand cargo is similar.

If your dependency management is any good then there's nothing to lose and a lot to gain from splitting your libraries out and allowing them to have independent release cycles. You can always do "platform" releases that aggregate together a bunch of finer-grained libraries with versions that are known together if you have a use case for that; going the other direction is a lot harder.

Re:Zig now has built-in HTTP server and client in std by pjmlp on Friday May 19, 2023 @11:13AM (#36002924)
As long as it is pure Java code.
Re:Zig now has built-in HTTP server and client in std by JodieBenitez on Sunday May 21, 2023 @05:27AM (#36019221)
Did maven help to split out Java's standard library ? Is Java's standard library small ?
Re:Zig now has built-in HTTP server and client in std by lmm on Sunday May 21, 2023 @05:37PM (#36024909)
> Did maven help to split out Java's standard library ?

I would say so, although splitting an existing standard library is still extremely painful and cumbersome thing to do (I don't think any other major language has seriously attempted it) - exactly why it's better to avoid having a large standard library to start with.

> Is Java's standard library small ?

I'd say no, but the parts of it that are used nowadays are. For example there is an HTTP client implementation in the standard library, but it's very rarely used by today's Java programs since its design is quite dated.