コード例 #1
0
ファイル: TranslationUnit.cs プロジェクト: JadeHub/LibClangCS
 public SourceRange GetSourceRange(SourceLocation start, SourceLocation end)
 {
     Library.SourceRange handle = Library.clang_getRange(start.Handle, end.Handle);
     return _itemStore.CreateSourceRange(handle);
 }
コード例 #2
0
ファイル: LibClangcs.cs プロジェクト: JadeHub/LibClangCS
 static SourceLocation()
 {
     NullLocation = Library.clang_getNullLocation();
 }
コード例 #3
0
ファイル: TranslationUnit.cs プロジェクト: JadeHub/LibClangCS
        public Cursor GetCursorAt(SourceLocation location)
        {
            if (location == null)
                throw new ArgumentException("null Location passed to GetCursotAt().");

            Library.Cursor cur = Library.clang_getCursor(Handle, location.Handle);
            if (cur.IsNull)
                return null;
            cur = Library.clang_getCursor(Handle, location.Handle);
            return _itemStore.CreateCursor(cur);
        }
コード例 #4
0
ファイル: LibClangcs.cs プロジェクト: JadeHub/LibClangCS
 internal static extern SourceRange clang_getRange(SourceLocation start, SourceLocation end);
コード例 #5
0
ファイル: LibClangcs.cs プロジェクト: JadeHub/LibClangCS
 internal static unsafe extern void clang_getInstantiationLocation(SourceLocation location, IntPtr* file, 
                                     out uint line, out uint column, out uint offset);
コード例 #6
0
ファイル: LibClangcs.cs プロジェクト: JadeHub/LibClangCS
 internal static extern Cursor clang_getCursor(IntPtr tu, SourceLocation loc);
コード例 #7
0
ファイル: LibClangcs.cs プロジェクト: JadeHub/LibClangCS
 internal static extern uint clang_equalLocations(SourceLocation l1, SourceLocation l2);
コード例 #8
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SourceRange"/> class.
 /// </summary>
 /// <param name="begin">The begin<see cref="SourceLocation"/></param>
 /// <param name="end">The end<see cref="SourceLocation"/></param>
 public SourceRange(SourceLocation begin, SourceLocation end)
 {
     this.m_value = clang.clang_getRange((CXSourceLocation)begin.Value, (CXSourceLocation)end.Value);
 }