Add a new transformation function: hex-to-dec

Closes #771
This commit is contained in:
Goo 2018-03-27 20:51:34 +08:00 committed by Dimitri Fontaine
parent 792c0d0357
commit c6271506ab

View File

@ -72,7 +72,8 @@
sql-server-uniqueidentifier-to-uuid
sql-server-bit-to-boolean
varbinary-to-string
base64-decode))
base64-decode
hex-to-dec))
;;;
@ -372,3 +373,8 @@
(etypecase string
(null nil)
(string (base64:base64-string-to-string string))))
(defun hex-to-dec (string)
(etypecase hex
(null nil)
(string (write-to-string (parse-integer hex :radix 16)))))