Last active
December 11, 2015 20:09
-
-
Save ihnorton/4653523 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
julia> using cindex; tu = tu_init("Index.h") | |
Ptr{Void} @0x00000000034586c0 | |
julia> cu = ccall( (:test_cu1, "../lib/libwrapcindex"), CXCursor, (Ptr{Void},), tu) | |
hash out: b540fa27 kind out: 300 | |
CXCursor(300,0,Ptr{Void} @0x0000000002c12b40,Ptr{Void} @0x0000000000000001,Ptr{Void} @0x00000000034586c0) | |
julia> ccall( (:test_cu2, "../lib/libwrapcindex"), Void, (CXCursor,), cu) | |
hash in: c8e83387 kind in: 6 | |
julia> ccall( (:test_cu2, "../lib/libwrapcindex"), Void, (CXCursor,), cu) | |
hash in: c8e83387 kind in: 6 | |
julia> cindex.hashCursor(cu) | |
0x5079d960 | |
julia> cindex.hashCursor(cu) | |
0xc370f7bc | |
julia> cindex.hashCursor(cu) | |
0xc370f7bc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
julia> disassemble(cindex.hashCursor,typeof((cu,))) | |
define %jl_value_t* @julia_hashCursor742(%jl_value_t*, %jl_value_t**, i32) { | |
top: | |
%3 = load %jl_value_t** %1, !dbg !6597 | |
%4 = getelementptr inbounds %jl_value_t* %3, i32 0, i32 0, !dbg !6604 | |
%5 = getelementptr %jl_value_t** %4, i64 1, !dbg !6604 | |
%6 = bitcast %jl_value_t** %5 to %CXCursor*, !dbg !6604 | |
%7 = load %CXCursor* %6, !dbg !6604 | |
%8 = call i32 @clang_hashCursor(%CXCursor %7), !dbg !6604, !julia_type !6605 | |
%9 = call %jl_value_t* @jl_box_uint32(i32 %8), !dbg !6604 | |
ret %jl_value_t* %9, !dbg !6604 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```julia | |
julia> using cindex; tu = tu_init("Index.h"); cu = tu_cursor(tu) | |
CXCursor(300,0,Ptr{Void} @0x00000000020fe5e0,Ptr{Void} @0x0000000000000001,Ptr{Void} @0x000000000255b8b0) | |
julia> cindex.hashCursor(cu) | |
0xfcac80a1 | |
julia> cindex.hashCursor(cu) | |
0x1aedf0a3 | |
julia> cindex.hashCursor(cu) | |
0x1aedf0a3 | |
julia> cindex.hashCursor(cu) | |
0x1aedf0a3 | |
julia> cl = children(cu) | |
getChildren... hash: de93b824 kind: -1964500264 | |
CursorList(Ptr{Void} @0x0000000003365a90,0) | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment