Change linkage of datafunction in V8_DEFINE_EXTENSION to static.
authorJustin McPherson <justin.mcpherson@nokia.com>
Fri, 10 Feb 2012 06:04:11 +0000 (16:04 +1000)
committerQt by Nokia <qt-info@nokia.com>
Mon, 13 Feb 2012 01:58:23 +0000 (02:58 +0100)
Stops interaction with items of the same name elsewhere.

Change-Id: I37ffdc8253d76247f03bd593785a35069636eba8
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
src/declarative/qml/qdeclarativecomponent.cpp
src/declarative/qml/v8/qv8engine_p.h

index 5bfa821..c168c8f 100644 (file)
@@ -78,7 +78,7 @@ public:
     v8::Persistent<v8::Script> initialProperties;
     v8::Persistent<v8::Function> forceCompletion;
 };
-static V8_DEFINE_EXTENSION(QDeclarativeComponentExtension, componentExtension);
+V8_DEFINE_EXTENSION(QDeclarativeComponentExtension, componentExtension);
 
 /*
     Try to do what's necessary for a reasonable display of the type
index ca70109..a39f673 100644 (file)
@@ -113,7 +113,7 @@ private:
 }
 
 #define V8_DEFINE_EXTENSION(dataclass, datafunction) \
-    inline dataclass *datafunction(QV8Engine *engine) \
+    static inline dataclass *datafunction(QV8Engine *engine) \
     { \
         static int extensionId = -1; \
         if (extensionId == -1) { \