blob: 579a8a37a41ce1d8db9685697a8849daa7a63a79 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
using System;
using System.Collections.Generic;
using System.Text;
using Irony.Parsing;
namespace Demo
{
public class Resolver : Demo.IASTResolver
{
#region IASTResolver Members
public IList<Demo.Declaration> FindCompletions(object result, int line, int col)
{
// Used for intellisense.
List<Demo.Declaration> declarations = new List<Demo.Declaration>();
// Add keywords defined by grammar
foreach (KeyTerm key in Configuration.Grammar.KeyTerms.Values)
{
if(key.OptionIsSet(TermOptions.IsKeyword))
{
declarations.Add(new Declaration("", key.Name, 206, key.Name));
}
}
declarations.Sort();
return declarations;
}
public IList<Demo.Declaration> FindMembers(object result, int line, int col)
{
List<Demo.Declaration> members = new List<Demo.Declaration>();
return members;
}
public string FindQuickInfo(object result, int line, int col)
{
return "unknown";
}
public IList<Demo.Method> FindMethods(object result, int line, int col, string name)
{
return new List<Demo.Method>();
}
#endregion
}
}
|