Path: csiph.com!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Andreas Leitgeb Newsgroups: comp.lang.java.programmer Subject: Re: Type conversions with the empty string Date: Mon, 13 Feb 2017 17:48:22 -0000 (UTC) Organization: A noiseless patient Spider Lines: 24 Message-ID: References: <15m3gy8mef7tv$.93ppj4f0t83$.dlg@40tude.net> <7fa3ca72-434c-4a41-88d4-1dfe900903f2@googlegroups.com> Reply-To: avl@logic.at Injection-Date: Mon, 13 Feb 2017 17:48:22 -0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="fbae4ca4b17641248da9630807ef5e16"; logging-data="612"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19CBAU21gKf6cnuru3sPSpR" User-Agent: slrn/1.0.2 (Linux) Cancel-Lock: sha1:QF/ERoRykRVEGKvDId7EVv5tV24= Xref: csiph.com comp.lang.java.programmer:36254 Andreas Leitgeb wrote: > Joerg Meier wrote: >> On Sun, 12 Feb 2017 11:20:49 -0800 (PST), lewbloch@gmail.com wrote: >>> Anyone who puts classes in `java.lang....` like that is evil and >>> breaking the law. >> What law ? > The law of good taste, for example ;-) Wait, forget it. It's not about spelling out the "java.lang." for class like String or System, it's about putting custom classes into that package. I'm too lazy to check if it's relevant for java.lang, but in principle it's possible to "seal" a package, and then it's against the java compiler's "law" to add or replace classes in it. Maybe, the Navy Seals will come to arrest threspassers. Anyway, that's not the point of a few posts upthread, where the point was about a scenario of someone messing with the JVM itself, to get their own java.lang.String dummy in, e.g. to troll some 3rd- party closed-source code. People with that agenda are not likely to care about laws (might even be a case of DMCA-violation for those who live where it matters - so much for "What law?").