diff options
author | Gergo Mocsi <gmocsi91@gmail.com> | 2013-07-20 13:03:42 +0200 |
---|---|---|
committer | Gergo Mocsi <gmocsi91@gmail.com> | 2013-09-02 18:16:46 +0200 |
commit | 6165d0b4846590d1d85d559636dd6587ea0dadd8 (patch) | |
tree | dedff6fd0d6387b4edd9a17653580a72a549e85c /include | |
parent | 6c1854f9f3f7308dce0e326aa063d929f8da5881 (diff) |
GSOC work, some code fixes
Fixed the link error: declared CodeCompleteDataCache as BASIC_DLLPUBLIC and it worked fine.
Fixed sergmentation fault error in CodeCompleteWindow.
The new cache implementation is fully functional.
CodeCompleteWindow is now being used as boost::scoped_ptr.
Change-Id: I76a0fc7407d589e7f94280fc4d50cea51b9639db
Diffstat (limited to 'include')
-rw-r--r-- | include/basic/codecompletecache.hxx | 10 | ||||
-rw-r--r-- | include/basic/sbmod.hxx | 1 |
2 files changed, 6 insertions, 5 deletions
diff --git a/include/basic/codecompletecache.hxx b/include/basic/codecompletecache.hxx index f375f04d0484..bba25d9b0659 100644 --- a/include/basic/codecompletecache.hxx +++ b/include/basic/codecompletecache.hxx @@ -32,7 +32,7 @@ typedef boost::unordered_map< OUString, OUString, OUStringHash > CodeCompleteVar typedef boost::unordered_map< OUString, CodeCompleteVarTypes, OUStringHash > CodeCompleteVarScopes; /* procedure, CodeCompleteVarTypes */ -class CodeCompleteDataCache +class BASIC_DLLPUBLIC CodeCompleteDataCache { /* * cache to store data for @@ -44,16 +44,18 @@ private: public: const OUString GLOB_KEY = OUString("global key"); const OUString NOT_FOUND = OUString("not found"); - CodeCompleteDataCache(){} + CodeCompleteDataCache(){} virtual ~CodeCompleteDataCache(){} + friend std::ostream& operator<< (std::ostream& aStream, const CodeCompleteDataCache& aCache); + void SetVars( const CodeCompleteVarScopes& aScopes ); const CodeCompleteVarScopes& GetVars() const; void InsertProcedure( const OUString& sProcName, const CodeCompleteVarTypes& aVarTypes ); - const OUString& GetVariableType( const OUString& sVarName, const OUString& sProcName ) const; - + OUString GetVariableType( const OUString& sVarName, const OUString& sProcName ) const; + void print() const; // wrapper for operator<<, prints to std::cerr }; #endif // CODECOMPLETECACHE_H diff --git a/include/basic/sbmod.hxx b/include/basic/sbmod.hxx index 763beefe3c5d..5a77cfb9dd2d 100644 --- a/include/basic/sbmod.hxx +++ b/include/basic/sbmod.hxx @@ -152,7 +152,6 @@ public: void RemoveVars(); ::com::sun::star::uno::Reference< ::com::sun::star::script::XInvocation > GetUnoModule(); bool createCOMWrapperForIface( ::com::sun::star::uno::Any& o_rRetAny, SbClassModuleObject* pProxyClassModuleObject ); - //std::vector< CodeCompleteData > GetCodeCompleteDataFromParse(); CodeCompleteDataCache GetCodeCompleteDataFromParse(); SbxArrayRef GetMethods(); }; |