forked from espruino/Espruino
-
Notifications
You must be signed in to change notification settings - Fork 4
/
.gdbinit
21 lines (21 loc) · 895 Bytes
/
.gdbinit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
break jsAssertFail
break jsErrorAt
break jsError
define jsvTrace
print jsvTrace(execInfo.root, 0)
end
define whereami
print jslPrintTokenLineMarker(jsiConsolePrintString, 0, execInfo.lex, execInfo.lex->tokenStart, 0)
end
define typeof
if (($arg0)->flags&JSV_VARTYPEMASK)>=JSV_NAME_STRING_0 && (($arg0)->flags&JSV_VARTYPEMASK)<=JSV_NAME_STRING_MAX
printf "JSV_NAME_STRING_%d\n", (($arg0)->flags&JSV_VARTYPEMASK)-JSV_NAME_STRING_0
end
if (($arg0)->flags&JSV_VARTYPEMASK)>=JSV_STRING_0 && (($arg0)->flags&JSV_VARTYPEMASK)<=JSV_STRING_MAX
printf "JSV_STRING_%d\n", (($arg0)->flags&JSV_VARTYPEMASK)-JSV_STRING_0
end
if (($arg0)->flags&JSV_VARTYPEMASK)>=JSV_STRING_EXT_0 && (($arg0)->flags&JSV_VARTYPEMASK)<=JSV_STRING_EXT_MAX
printf "JSV_STRING_EXT_%d\n", (($arg0)->flags&JSV_VARTYPEMASK)-JSV_STRING_EXT_0
end
print (JsVarFlags)(($arg0)->flags&(JSV_VARTYPEMASK))
end