]> git.donarmstrong.com Git - lilypond.git/blob - flower/include/libc-extension.hh
Run grand-replace (issue 3765)
[lilypond.git] / flower / include / libc-extension.hh
1 /*
2   This file is part of LilyPond, the GNU music typesetter.
3
4   Copyright (C) 1997--2014 Han-Wen Nienhuys <hanwen@xs4all.nl>
5
6   LilyPond is free software: you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation, either version 3 of the License, or
9   (at your option) any later version.
10
11   LilyPond is distributed in the hope that it will be useful,
12   but WITHOUT ANY WARRANTY; without even the implied warranty of
13   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14   GNU General Public License for more details.
15
16   You should have received a copy of the GNU General Public License
17   along with LilyPond.  If not, see <http://www.gnu.org/licenses/>.
18 */
19
20 #ifndef LIBC_EXTENSION_HH
21 #define LIBC_EXTENSION_HH
22
23 #include <cstddef>
24 #include <cstdarg>
25 using namespace std;
26
27 #include "config.hh"
28
29 char *strnlwr (char *start, int n);
30 char *strnupr (char *start, int n);
31
32 #if ! HAVE_MEMMEM               /* GNU extension. */
33 void *memmem (void const *haystack, int haystack_len,
34               void const *needle, int needle_len);
35 #endif /* HAVE_MEMMEM */
36
37 #if ! HAVE_MEMRCHR
38 unsigned char *memrchr (unsigned char const *p, int n, char c);
39 #endif
40
41 #if ! HAVE_MEMREV
42 unsigned char *memrev (unsigned char *byte, int length_i);
43 #endif
44
45 double my_round (double);
46
47 /* namespace std { */
48
49 #if ! HAVE_SNPRINTF             /* GNU extension. */
50 int snprintf (char *str, size_t n, char const *format, ...);
51 __attribute__ ((format (printf, 3, 4)));
52 #endif
53
54 #if ! HAVE_VSNPRINTF            /* GNU extension. */
55 int vsnprintf (char *str, size_t, char const *format, va_list args);
56 #endif
57
58 #ifndef isinf
59 #if ! HAVE_ISINF                /* BSD extension. */
60 int isinf (double x);
61 #endif
62 #endif
63
64 /* }; */
65
66 #endif /* LIBC_EXTENSION_HH */