Skip to content

Commit 8e8231f

Browse files
Remove deprecated math.c_frexp (#19518)
* Remove Deprecated math proc * Remove Deprecated math proc * Remove Deprecated math proc
1 parent 42eeab5 commit 8e8231f

File tree

3 files changed

+3
-11
lines changed

3 files changed

+3
-11
lines changed

changelog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ becomes an alias for `addr`.
4444

4545
- Changed mimedb to use an `OrderedTable` instead of `OrderedTableRef`, to use it in a const.
4646

47+
- Removed deprecated `math.c_frexp`.
48+
49+
4750
## Language changes
4851

4952
- Pragma macros on type definitions can now return `nnkTypeSection` nodes as well as `nnkTypeDef`,

lib/pure/math.nim

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,6 @@ when defined(c) or defined(cpp):
6969

7070
proc c_signbit(x: SomeFloat): cint {.importc: "signbit", header: "<math.h>".}
7171

72-
func c_frexp*(x: cfloat, exponent: var cint): cfloat {.
73-
importc: "frexpf", header: "<math.h>", deprecated: "Use `frexp` instead".}
74-
func c_frexp*(x: cdouble, exponent: var cint): cdouble {.
75-
importc: "frexp", header: "<math.h>", deprecated: "Use `frexp` instead".}
76-
7772
# don't export `c_frexp` in the future and remove `c_frexp2`.
7873
func c_frexp2(x: cfloat, exponent: var cint): cfloat {.
7974
importc: "frexpf", header: "<math.h>".}

tests/stdlib/tmath.nim

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -437,12 +437,6 @@ template main() =
437437
doAssert lgamma(-0.0) == Inf
438438
doAssert lgamma(-1.0) == Inf
439439

440-
when nimvm: discard
441-
else:
442-
var exponent: cint
443-
doAssert c_frexp(0.0, exponent) == 0.0
444-
doAssert c_frexp(-0.0, exponent) == -0.0
445-
doAssert classify(c_frexp(-0.0, exponent)) == fcNegZero
446440

447441
static: main()
448442
main()

0 commit comments

Comments
 (0)