diff options
Diffstat (limited to 'tapset/conversions.stp')
-rw-r--r-- | tapset/conversions.stp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tapset/conversions.stp b/tapset/conversions.stp new file mode 100644 index 00000000..5c0230d4 --- /dev/null +++ b/tapset/conversions.stp @@ -0,0 +1,14 @@ +function _hexstring (num) %{ + sprintf (THIS->__retvalue, "0x%llx", (long long) THIS->num); +%} + +function hexstring (num) { + return "" . _hexstring (num + 0) +} +function _string (num) %{ + sprintf (THIS->__retvalue, "%lld", (long long) THIS->num); +%} + +function string (num) { + return "" . _string (num + 0) +} |