1*1f5207b7SJohn Levon /*
2*1f5207b7SJohn Levon * BSD Compatibility functions
3*1f5207b7SJohn Levon *
4*1f5207b7SJohn Levon *
5*1f5207b7SJohn Levon * Permission is hereby granted, free of charge, to any person obtaining a copy
6*1f5207b7SJohn Levon * of this software and associated documentation files (the "Software"), to deal
7*1f5207b7SJohn Levon * in the Software without restriction, including without limitation the rights
8*1f5207b7SJohn Levon * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9*1f5207b7SJohn Levon * copies of the Software, and to permit persons to whom the Software is
10*1f5207b7SJohn Levon * furnished to do so, subject to the following conditions:
11*1f5207b7SJohn Levon *
12*1f5207b7SJohn Levon * The above copyright notice and this permission notice shall be included in
13*1f5207b7SJohn Levon * all copies or substantial portions of the Software.
14*1f5207b7SJohn Levon *
15*1f5207b7SJohn Levon * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16*1f5207b7SJohn Levon * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17*1f5207b7SJohn Levon * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18*1f5207b7SJohn Levon * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19*1f5207b7SJohn Levon * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20*1f5207b7SJohn Levon * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21*1f5207b7SJohn Levon * THE SOFTWARE.
22*1f5207b7SJohn Levon */
23*1f5207b7SJohn Levon
24*1f5207b7SJohn Levon #include <sys/types.h>
25*1f5207b7SJohn Levon #include <string.h>
26*1f5207b7SJohn Levon
27*1f5207b7SJohn Levon #include "lib.h"
28*1f5207b7SJohn Levon #include "allocate.h"
29*1f5207b7SJohn Levon #include "token.h"
30*1f5207b7SJohn Levon
31*1f5207b7SJohn Levon #include "compat/mmap-blob.c"
32*1f5207b7SJohn Levon
string_to_ld(const char * nptr,char ** endptr)33*1f5207b7SJohn Levon long double string_to_ld(const char *nptr, char **endptr)
34*1f5207b7SJohn Levon {
35*1f5207b7SJohn Levon return strtod(nptr, endptr);
36*1f5207b7SJohn Levon }
37