DUchain query
Piyush Verma
piyush.verma at gmail.com
Tue Jul 24 19:50:00 UTC 2007
While Building the DUChain, is the editointegrator kind of necessary?
This might be Obvious Otherwise, but i had some trouble in it.
Working according to Cpp making a new editorintegrator was taking quite some
time+effort than usual, can the info regarding the current document be passed
with the url?
like the url being passed to contextbuilder here...is this of any real
use...OR the only solution is to write a editorintegrator?
Index: pythonparsejob.cpp
===================================================================
--- pythonparsejob.cpp (revision 691951)
+++ pythonparsejob.cpp (working copy)
@@ -129,8 +129,8 @@
if ( matched )
{
- kDebug() << m_document<<endl;
- new ContextBuilder(m_session);
+ kDebug() << m_url<<endl;
+ new ContextBuilder(m_session,m_url);
kDebug() << "----Parsing Succeded---"<<endl;//TODO: bind declarations
to the code model
}
else
Index: parser/contextbuilder.h
===================================================================
--- parser/contextbuilder.h (revision 691545)
+++ parser/contextbuilder.h (working copy)
@@ -53,7 +53,7 @@
{
public:
- ContextBuilder(ParseSession* session);
+ ContextBuilder(ParseSession* session, const KUrl &url);
ParseSession* parseSession() const;
virtual ~ContextBuilder ();
@@ -84,6 +84,7 @@
inline int& nextContextIndex() { return m_nextContextStack.top(); }
private:
ParseSession* m_session;
+ KUrl m_url;
};
#endif
Index: parser/parsesession.h
===================================================================
--- parser/parsesession.h (revision 691951)
+++ parser/parsesession.h (working copy)
@@ -47,7 +47,6 @@
private:
QByteArray m_contents;
- KUrl* url;
};
#endif
Index: parser/contextbuilder.cpp
===================================================================
--- parser/contextbuilder.cpp (revision 691951)
+++ parser/contextbuilder.cpp (working copy)
@@ -6,10 +6,11 @@
using namespace KDevelop;
using namespace python;
-ContextBuilder::ContextBuilder(ParseSession* session)
+ContextBuilder::ContextBuilder(ParseSession* session, const KUrl &url)
:m_session(session)
+ ,m_url(url)
{
- kDebug() << "=====Building Contexts===="<<endl;
+ kDebug() << "=====Building Contexts for===="<<m_url<<endl;
}
--
Regards,
Piyush Verma
0091-9811261908
Email:piyush.verma at gmail.com
Work: piyush at phire.com
More information about the KDevelop-devel
mailing list