Comment #3 on issue 3075 by [email protected]: Public Version Macros
https://code.google.com/p/v8/issues/detail?id=3075

From Jakob's comment from https://codereview.chromium.org/23723003/:

"My point is that when these macros exist, projects will inevitably use them to effectively pin themselves against outdated V8 versions, especially in scenarios where they don't bundle/control the V8 version they run/compile against. That's irresponsible and dangerous, and we should not encourage it or make it easier to
do.

Of course *not* having version macros doesn't *force* them to update more
frequently either, but that's beside the point. *Having* version macros creates
the impression of supporting such risky and brittle practices.

Yes, embedders have to keep up with API changes. But they have to do that either way, and version macros don't make it easier. I think node.js's approach works fine: they track V8; every Node version (whether it's trunk or release) is built to work with a specific V8 version. There's no need for version macros in this
scenario."

I'm sympathetic to that argument but I want to point out that it already happens with node.js add-ons that target v0.10 and v0.11 (that's V8 3.14 vs. 3.18, 3.22, 3.24, 3.26 or 3.29, depending on the release.) Add-ons don't have control over the V8 version like node.js core does, their only option is to go wild with #ifdefs.

Another datum: in one of our (StrongLoop's) products, we currently (and rather creatively) SFINAE on v8::Object::GetConstructor() to distinguish between 3.26 and 3.29; the method was removed halfway through the 3.28 development cycle.

For that matter, you can pinpoint the V8 release with reasonable accuracy by specializing on the constants from v8::internal::Internals... and yes, I've been guilty of doing that. Please don't make me commit such heinous hacks again!

--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to