HEX$の桁数が負の場合エラーを出すようにした

This commit is contained in:
otya128 committed 2016-09-03 17:33:52 +09:00
1 parent e1dd8fce41
commit e878837b95
1 file changed
+1 -1
+1 -1
View File
@@ -880,7 +880,7 @@ class BuiltinFunction
static wstring HEX(int val, DefaultValue!(int, false) digits)
{
import std.format;
if(digits > 8)
if(digits > 8 || digits < 0)
{
throw new OutOfRange();
}