Commit 1627bf07 authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Move lexNum to base/tests

parent 56d233a1
......@@ -19,4 +19,5 @@ test('unicode002',
test('data-fixed-show-read', normal, compile_and_run, [''])
test('showDouble', normal, compile_and_run, [''])
test('hash001', normal, compile_and_run, [''])
test('lexNum', normal, compile_and_run, [''])
module Main where
testStrings
= [ "0x3y",
"0X3abx",
"0o39y",
"0O334z",
"NaN",
"Infinity",
"34yy",
"34.4x",
"034.4x",
"31.45e-6y",
"49.2v",
"049.2v",
"35e-3x",
"035e-3x",
"35e+3y",
"83.3e-22",
"083.3e-22"
]
main = mapM test testStrings
test s = print (lex s)
[("0x3","y")]
[("0X3ab","x")]
[("0o3","9y")]
[("0O334","z")]
[("NaN","")]
[("Infinity","")]
[("34","yy")]
[("34.4","x")]
[("034.4","x")]
[("31.45e-6","y")]
[("49.2","v")]
[("049.2","v")]
[("35e-3","x")]
[("035e-3","x")]
[("35e+3","y")]
[("83.3e-22","")]
[("083.3e-22","")]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment