Firefox, Safari, and Chrome all use 1-based column numbers -- estree should too #65

fitzgen opened this Issue Mar 16, 2015 · 6 comments


None yet

6 participants

fitzgen commented Mar 16, 2015

Or somehow convince everyone else to use 0-based columns (if it doesn't break the web).

dherman commented Mar 16, 2015

I am pretty confident changing error stack indices would break the web.

nzakas commented Mar 16, 2015

👎 If such compatibility is an issue, it can be handled downstream by tools.


@nzakas 👍 I don't see reasons to break established logic and tools that rely on it.


@fitzgen thanks for contributing! We can't break the web, so closing this issue.

@mikesherov mikesherov closed this Mar 18, 2015
getify commented Mar 18, 2015

Not disagreeing with the resolution here. I also think we should leave them 0-based. Such re-mapping of line numbers or column numbers is entirely in the realm of tools and not standards. IIRC, JSLint awhile back begrudgingly added a feature to change the numbering.

But the "would break the web" assertion is not terribly obvious. I've tried for a bit to come up with many practical use-cases where that's true and I can't. We might want to add more detail here, or somewhere, to document for posterity why that would be the case.


"Break the web" is generic shorthand for "break all downstream consumers of esprima, acorn, and Spidermonkey".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment