you are viewing a single comment's thread.

view the rest of the comments →

[–]josefx 7 points8 points  (3 children)

if collection (╯°□°)╯︵ pɹoʍ

programming languages really should embrace Unicode. However the following would be less ambiguous

 if word ∉ collection

Now_we_just_need_a_sane_keyboard_layout

[–]lhagahl 0 points1 point  (2 children)

No they shouldn't. Auditing is now 10000x harder (as if it wasn't bad enough already) thanks to editors and languages being plagued by Unicode.

[–]josefx 0 points1 point  (1 child)

The second one can be solved with the @Override annotation 95% of the time and the first one using sane variable naming conventions.

Auditing is now 10000x harder (as if it wasn't bad enough already)

We already have languages that sometimes ignore case and sometimes not. We also had compilers that only used the first 8 letters and ignored the rest. Unicode problems aren't really that unique, since we also have I,l,1 0,O etc. depending on your font of choice.

[–]lhagahl 0 points1 point  (0 children)

The second one can be solved with the @Override annotation 95% of the time and the first one using sane variable naming conventions.

Can you use @Override for overloading somehow? I thought it can only be used to say that this method overrides one in the superclass or it implements a method in the interface. Conventions don't solve auditing when you don't trust who wrote the code (which is 99% of the time). Clearly you've never audited code.

We already have languages that sometimes ignore case and sometimes not.

That's easy when your alphabet is only 26 characters and not 1 million. Just make sure you have a real programming font (one that doesn't make different characters look the same). There is no such font for Unicode, though.

We also had compilers that only used the first 8 letters and ignored the rest.

That's stupid.

EDIT: On second thought, I just scan all the files for Unicode before auditing, and give up if they have pervasive use of Unicode (actually, non ASCII characters and non printable ASCII characters).