deprecated node.js API
there are some deprecated API documented in current node.js docs. we could add @:deprecated metadata in haxe to warn user about that. think that's a nice free feature that plain node.js doesn't have.
thoughts?
I'm ok! Users will be delighted :)
No reason not to do that.
I added a guideline on using @:deprecated, but we need to review our current externs and add that it where apropriate.
I have an issue with some of these. For example js.node.Util.isArray gives a deprecated warning, however I cannot find the non-deprecated way of calling the function that this deprecated call maps to (Array.isArray(...)).
I cannot find the 'NativeArray' equivalent Javascript class. So without a clear and obvious way to use the non-deprecated version in Haxe, I would rather not give compiler warnings for cases where the use cannot correct it.
Isn't standard Haxe way Std.is(obj, Array) sufficient?
Perhaps. I made the assumption that Haxe arrays were not the same runtime object as JS arrays. So that assumption is wrong?
It's the same. However, we probably should provide Haxe-way examples in those deprecation messages indeed.