Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/sqlite/blob/master/test/atof2.test # sqlite [Ported from github.com/sqlite/sqlite] Fix bugs in and improve the interface to the ".check" command of the CLI. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `sqlite / test / atof2.test` 35 lines ยท 871 bytes Raw Blame History 1 # 2026-02-20 2 # 3 # The author disclaims copyright to this source code. In place of 4 # a legal notice, here is a blessing: 5 # 6 # May you do good and not evil. 7 # May you find forgiveness for yourself and forgive others. 8 # May you share freely, never taking more than you give. 9 # 10 #*********************************************************************** 11 # 12 # Tests of the sqlite3AtoF() function. 13 # 14 15 set testdir [file dirname $argv0] 16 source $testdir/tester.tcl 17 18 # Rounding cases: 19 # 20 do_execsql_test atof2-1.0 { 21 SELECT format('%g',192.496475); 22 } 192.496 23 do_execsql_test atof2-1.1 { 24 SELECT format('%g',192.496501); 25 } 192.497 26 27 load_static_extension db ieee754 28 do_execsql_test atof2-2.1 { 29 SELECT format('%!.30f',ieee754_inc(100.0,-1)); 30 } 99.`9999999999999858` 31 do_execsql_test atof2-2.2 { 32 SELECT format('%!.30f',ieee754_inc(100.0,-2)); 33 } 99.`9999999999999716` 34 35 finish_test