Add support for float data type.

This commit is contained in:
2020-02-16 21:50:43 -06:00
parent b496b10578
commit bdd62cad66
2 changed files with 4 additions and 1 deletions

View File

@ -197,6 +197,9 @@ proc createParseStmt*(t, value: NimNode): NimNode =
elif t.typeKind == ntyInt:
result = quote do: parseInt(`value`)
elif t.typeKind == ntyFloat:
result = quote do: parseFloat(`value`)
elif t.typeKind == ntyBool:
result = quote do: "true".startsWith(`value`.toLower)