3 ms·
Agreed on this one, the "fix" involving the capacity flag, e.g. "2:3:3" is unintuitive compared to Python where there is no such concept. Still, as far as shar
by metadat 2y ago
Agreed on this one, the "fix" involving the capacity flag, e.g. "2:3:3" is unintuitive compared to Python where there is no such concept.
Still, as far as sharp edges go these are nothing compared to Java.
See the discussion from:
Common I/O Tasks in Modern Java
https://news.ycombinator.com/item?id=41142737 https://news.ycombinator.com/item?id=41142737
House of horrors, especially the URL equality triggering DNA requests.
- throwaway8e83 2y ago> URL equality triggering DNS requests I agree it can be confusing, as the URL also can act as a client that performs actual connections. The documentation actually mentions that URI is a better choice when you want only a representation In general I don't think the other examples are that bad. The reason why there are so many different ways of performing I/O, is because Java is evolving and adding better solutions, but can't really remove older stuff like "URL" because it is widely used. I see similar issues with other languages as they evolve, and I think Java has managed it well. The IDEs are also often good at making suggestions on how to replace outdated code.