Commit Graph

21 Commits

Author SHA1 Message Date
Strahinja Val Markovic
531e564a88 Removing Concurrent* & Future classes
They're not needed anymore.
2013-10-07 11:03:28 -07:00
Strahinja Val Markovic
6c53bad58f No more threading in completers!
The server is multi-threaded and will spawn a new thread for each new request.
Thus, the completers need not manage their own threads or even provide async
APIs; we _want_ them to block because now were implementing the request-response
networking API.

The client gets the async API through the network (i.e., it can do something
else while the request is pending).
2013-10-07 11:03:28 -07:00
Strahinja Val Markovic
454a961318 The identifier completer now reads tags files
See the docs for details. Fixes #135.
2013-05-26 13:33:40 -07:00
Strahinja Val Markovic
2805b0fe85 Better thread safety in IdentifierCompleter
Everything that needs access to filetype_map_ has been split into a new class
called IdentifierDatabase. This class is thread-safe. Previously, multiple
threads could access filetype_map_ at the same time, some reading things from
it, others writing to it. WTF was I doing? My best guess is that I introduced
this vile stupidity when I added the second thread to IdentifierCompleter;
previously it was impossible for multiple threads to stomp on filetype_map_
because only one thread ever accessed it. I changed that some time ago and
forgot to protect filetype_map_.

Idiot.
2013-05-25 11:43:14 -07:00
Strahinja Val Markovic
e1584a33b0 Code style fixes 2013-02-23 15:54:44 -08:00
Strahinja Val Markovic
e743076e14 Option to collect identifiers n comments/strings
Fixes #98.
2013-02-16 14:00:46 -08:00
Strahinja Val Markovic
30d5a3b8a5 Wrapping boost threads in scoped_ptr
Boost.Thread deprecated the copy ctor for threads; this is a better approach.
2013-02-16 12:25:29 -08:00
Strahinja Val Markovic
4308130ab3 Formatting more code with astyle 2013-01-19 20:10:52 -08:00
Strahinja Val Markovic
607b25e16b Lowering the visibility of some typdefs 2012-09-06 11:58:16 -07:00
Strahinja Val Markovic
f4d7d6ffdf ClangCompleter can now not be compiled
One more thing needs to be done though: the clang_completer.py file needs to not
trigger at all when YCM has been compiled without cpp support. FIX THAT!
2012-08-17 13:32:42 -07:00
Strahinja Val Markovic
f88c9feb4f Refactored the clang completer; many bugs fixed
This change should fix the random hangs and segfaults when using the clang
completer. Also, assertion errors printed to the console on vim exit should go
away too, same thing with segfaults on vim exit. These "on exit" errors were
caused by not cleanly shutting down the background threads; both the identifier
completer and the clang one now join the threads on destruction. This results in
a clean shutdown.

The new clang completer architecture now uses only one clang thread (again)
instead of a completion and parsing thread. Since the parsing task needs to wait
on the completion task if it was started first (and vice-versa) there's no point
to using two threads. The desired "simplicity" of using two threads for these
two tasks actually created needless complexity (and bugs). Sigh. Such is life.

A TranslationUnit abstraction was also created and this in turn also reduces the
complexity of the clang completer.

The clang completer now also has some (very) basic tests.
2012-08-11 19:37:08 -07:00
Strahinja Val Markovic
eab70838f0 New system for specifying clang flags
Now the .ycm_clang_options file is a python script that needs to implement our
API. This enables the user to do arbitrary things when computing flags.
2012-08-01 19:34:20 -07:00
Strahinja Val Markovic
3cc4cf8e10 Async clang parsing of the current file 2012-07-26 21:44:17 -07:00
Strahinja Val Markovic
13f87c5a62 Buffer identifiers are now extracted async 2012-07-24 20:09:09 -07:00
Strahinja Val Markovic
b120d6a5ba Now extracting identifiers in C++ code 2012-07-23 20:17:59 -07:00
Strahinja Val Markovic
44b671c2c0 ClangCompleter now returs extra data
This data is used to show more information about the completions in the
completion menu.
2012-07-19 21:17:39 -07:00
Strahinja Val Markovic
c9e1706fa1 ClangCompleter now async and caches Clang data
First off, we don't block the GUI thread anymore for ClangCompleter (that was
always temporary). Secondly, now ClangCompleter will cache the data coming from
clang so that query-based filtering of members is fast.
2012-07-15 20:49:56 -07:00
Strahinja Val Markovic
ce23b5ca55 Moving the LatestTask typedef to Future.h 2012-07-12 20:54:40 -07:00
Strahinja Val Markovic
dad2fc31bb Replacing a header file with a forward decl 2012-07-11 22:10:37 -07:00
Strahinja Val Markovic
be0085aca9 CandidateRepository is used for Candidate storage
This will make it easy to use the same Candidates for both the
IdentifierCompleter and the ClangCompleter, thereby reducing memory consumption
and increasing performance.
2012-07-11 22:08:04 -07:00
Strahinja Val Markovic
545792c055 Renaming Completer to IdentifierCompleter 2012-07-10 23:13:12 -07:00