Skip to content

Commit 8fe290e

Browse files
authored
[libc] Canonicalize generated fenv.h (llvm#127363)
This removes the custom template for fenv.h by declaring all the standard-specified macros using macro_header.
1 parent 2b41277 commit 8fe290e

File tree

2 files changed

+28
-24
lines changed

2 files changed

+28
-24
lines changed

libc/include/fenv.h.def

Lines changed: 0 additions & 17 deletions
This file was deleted.

libc/include/fenv.yaml

Lines changed: 28 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,32 @@
11
header: fenv.h
2-
header_template: fenv.h.def
3-
macros: []
2+
standards:
3+
- stdc
4+
macros:
5+
- macro_name: FE_ALL_EXCEPT
6+
macro_header: fenv-macros.h
7+
- macro_name: FE_DIVBYZERO
8+
macro_header: fenv-macros.h
9+
- macro_name: FE_INEXACT
10+
macro_header: fenv-macros.h
11+
- macro_name: FE_INVALID
12+
macro_header: fenv-macros.h
13+
- macro_name: FE_OVERFLOW
14+
macro_header: fenv-macros.h
15+
- macro_name: FE_UNDERFLOW
16+
macro_header: fenv-macros.h
17+
- macro_name: FE_DOWNWARD
18+
macro_header: fenv-macros.h
19+
- macro_name: FE_TONEAREST
20+
macro_header: fenv-macros.h
21+
- macro_name: FE_TOWARDZERO
22+
macro_header: fenv-macros.h
23+
- macro_name: FE_UPWARD
24+
macro_header: fenv-macros.h
25+
- macro_name: FE_DFL_ENV
26+
macro_header: fenv-macros.h
427
types:
528
- type_name: fenv_t
629
- type_name: fexcept_t
7-
enums: []
8-
objects: []
930
functions:
1031
- name: feclearexcept
1132
standards:
@@ -15,14 +36,14 @@ functions:
1536
- type: int
1637
- name: fedisableexcept
1738
standards:
18-
- GNUExtensions
39+
- gnu
1940
return_type: int
2041
arguments:
2142
- type: int
2243
guard: null
2344
- name: feenableexcept
2445
standards:
25-
- GNUExtensions
46+
- gnu
2647
return_type: int
2748
arguments:
2849
- type: int
@@ -35,7 +56,7 @@ functions:
3556
- type: fenv_t *
3657
- name: fegetexcept
3758
standards:
38-
- GNUExtensions
59+
- gnu
3960
return_type: int
4061
arguments: []
4162
- name: fegetexceptflag

0 commit comments

Comments
 (0)