diff options
author | Eli Bendersky <eliben@gmail.com> | 2018-08-31 06:03:05 -0700 |
---|---|---|
committer | Eli Bendersky <eliben@gmail.com> | 2018-08-31 06:03:05 -0700 |
commit | 40f0d91ac66b9840ce407e7303bac116b8a1c214 (patch) | |
tree | 021e870f386a715002c69d9752753080db0436ff | |
parent | a915c3d09b8f15ae9b70cf03497089d5063f4f3b (diff) | |
download | pycparser-40f0d91ac66b9840ce407e7303bac116b8a1c214.tar.gz |
Add test for parsing a hex float constant to the right type
-rwxr-xr-x | tests/test_c_parser.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/test_c_parser.py b/tests/test_c_parser.py index cbba9b6..a48f1c6 100755 --- a/tests/test_c_parser.py +++ b/tests/test_c_parser.py @@ -1236,6 +1236,9 @@ class TestCParser_fundamentals(TestCParser_base): self.assertEqual(self.get_decl_init(d54), ['Constant', 'float', '1.0F']) + d55 = 'float ld = 0xDE.38p0;' + self.assertEqual(self.get_decl_init(d55), + ['Constant', 'float', '0xDE.38p0']) def test_decl_named_inits(self): d1 = 'int a = {.k = 16};' |