Title / Description
Code /* ==================== handle argv ==================== */ #define ustring_delete_range_p(/*UString **/ ustr, /*UChar **/ from, /*UChar **/ to) \ ustring_delete_len(ustr, from - ustr->ptr, to - from) #define ustring_subreplace_len_p(/*UString **/ ustr, /*UChar **/ from, /*UChar **/ to, /*UChar **/ what, /*size_t*/ len) \ ustring_subreplace_len(ustr, what, len, from - ustr->ptr, to - from) static int hexadecimal_digit(UChar c) { if (c >= U_0 && c <= U_9) { // '0' .. '9' return (c - U_0); } if (c >= U_A && c <= U_F) { // 'A' .. 'F' return (c - (U_A - 10)); } if (c >= U_a && c <= U_f) { // 'a' .. 'f' return (c - (U_a - 10)); } return -1; }
Author
Highlight as C C++ CSS Clojure Delphi ERb Groovy (beta) HAML HTML JSON Java JavaScript PHP Plain text Python Ruby SQL XML YAML diff code