Commit 3e9c8812 authored by Christian Hergert's avatar Christian Hergert
Browse files

vala-pack: port to new code indexer API changes

parent e196faa9
......@@ -28,8 +28,7 @@ namespace Ide
public class ValaCodeIndexer : Ide.Object, Ide.CodeIndexer
{
/* Note: This runs in a thread */
public Ide.CodeIndexEntries index_file (GLib.File file,
public async Ide.CodeIndexEntries index_file_async (GLib.File file,
string[]? build_flags,
GLib.Cancellable? cancellable)
throws GLib.Error
......@@ -39,12 +38,7 @@ namespace Ide
var index = service.index;
var tree = index.get_symbol_tree_sync (file, cancellable);
Ide.ValaCodeIndexEntries? ret = null;
index.do_locked (_ => {
ret = new Ide.ValaCodeIndexEntries (tree as Ide.ValaSymbolTree);
});
var ret = new Ide.ValaCodeIndexEntries (tree as Ide.ValaSymbolTree);
if (ret == null)
throw new GLib.IOError.FAILED ("failed to build entries");
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment