14,600 reputation
13460
bio website
location
age
visits member for 4 years, 6 months
seen 5 hours ago

Mar
13
comment Is serialization strategy part of an abi?
@DavidCowden Which part specifically do you want a reference for? That inputs and output files can be part of an API? That serialization formats are usually documented? That they are expected to remain compatible? Anything else?
Mar
13
comment Is serialization strategy part of an abi?
@h.j.k. Those libraries document their formats, yes, but applications that either use those or roll their own custom format (binary or more often JSON/XML/etc.) frequently don't.
Mar
12
revised Is serialization strategy part of an abi?
deleted 23 characters in body
Mar
12
answered Is serialization strategy part of an abi?
Mar
12
comment Why isn't the addremove recommended by default in Mercurial?
@ShashankSawant Tough place to be in. You should certainly throw out files that have no reason to be tracked so the future looks brighter, but the history would still be a mess. If you care about repo size and a clean history, you could create a new repository and replay a cleaned-up version of history (same commits at the same date/time, omitting pointless files), but automating this is beyond my expertise and doing it manually is probably too much work and too error-prone. Maybe ask a new question?
Mar
8
answered Can one deny specific parties the right to use and modify otherwise open source software?
Mar
7
comment Interview Question - Adding Method to interface that has been implemented by thousands of class
What? Why? A class with a thousand subclasses is much more questionable. Some interfaces, like Iterable, Comparable, Collection, or Runnable are simply very general and apply to a lot of otherwise unrelated classes.
Mar
6
revised Why doesn't v8 compile typescript instead of javascript?
added 170 characters in body
Mar
6
answered Why doesn't v8 compile typescript instead of javascript?
Mar
5
revised Why isn't the addremove recommended by default in Mercurial?
added 41 characters in body
Mar
5
answered Why isn't the addremove recommended by default in Mercurial?
Mar
4
comment Origin of naming generic types as T?
I think the convention is also strong in some lineages that couldn't have been influenced by Pascal/Delphi/C#, such as and C++ and Java.
Mar
3
comment Is a 'least significant bit' used anywhere practically today?
As far as I know, "least significant bit" is merely a name for the bit in a word with the smallest positional value. I am not aware of any "format" or encoding that goes by that name. Are you perhaps confusing this with the terms big endian and little endian?
Mar
3
comment Algorithm to 'segment' a number into blocks of n?
Divide the input number by the number of nodes, scatter the remainder among some subset of the nodes. What's so hard? (Now if the work per number is not uniform, things would get more interesting...)
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin I asked for a string processing problem. I am quite sure that no customer has ever needed a program that takes a string and extracts the Nth code point. To the best of my knowledge, it's only used by some algorithms that solve such customer demands. And UTF-8 has advantages other than space savings: For starters, it's more ASCII-compatible, which helps with legacy systems (including C libraries using 0-terminated strings). I would also argue that making codepoint access harder is good, as it nudges beginners in the right direction (towards the concept of grapheme clusters).
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin Given all these problems, I can not seriously consider your suggestion as an alternative. (But yes, one could ignore the problem in the spec and leave that for the implementation to figure out.)
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin Please give me an example of a string processing problem that is hard or "impossible" to solve efficiently with UTF-8 but easy with UTF-32. Note that it's easy to extract a code unit from a UTF-8 string if you have its byte index, so it would have to be a problem where the code point index is produced in a way that's not trivial to adapt to produce byte indices (e.g., substring search or string length)
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin That (alternate file stream) is even worse. It's not portable across file systems, it gets dropped on copy & paste or when passing through anything that's not a file system (e.g. HTTP or FTP or similar file transfer), it's harder to edit, and most people don't even know it exists. It also leaks file system details into the language specification.
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin UTF-32 is not only wasteful, it is pointlessly wasteful: The only operations it speeds up or makes easier are those that are subtly wrong anyway (mistaking code points for grapheme clusters), and I've yet to encounter any real string processing problem for which random access to code points is useful. Read the UTF-8 Everywhere Manifesto, especially the FAQ.
Mar
2
comment How can frond-end developer support different encoding (UTF-8 , UTF-16,..)other than ASCII?
@JerryCoffin Where should that separate metadata go that's more reliable than the alternative? In a separate file? That gets lost easily, especially when sharing code. Restricting the prefix until the encoding cookie to ASCII-like works well enough, especially for programming languages.