source: rtems/testsuites/psxtests/psxhdrs/math/modf.c @ 9598f83e

5
Last change on this file since 9598f83e was 9598f83e, checked in by Shashvat Jain <shashvatjain2002@…>, on 12/06/18 at 13:08:12

psxhdrs: Add POSIX Conformance Tests for math.h (GCI 2018)

Includes API tests for y0l, y1l, and ynl which are in glibc but
not in POSIX or newlib. They are disabled until further investigation
as to compatibility requirements are determined per the referenced
ticket.

Updates #3638.

  • Property mode set to 100644
File size: 965 bytes
Line 
1/**
2 *  @file
3 *  @brief modf() API Conformance Test
4 */
5
6 /*
7  *  COPYRIGHT (c) 2018.
8  *  Shashvat Jain
9  *
10  *  Permission to use, copy, modify, and/or distribute this software
11  *  for any purpose with or without fee is hereby granted.
12  *
13  *  THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
14  *  WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
15  *  WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR
16  *  BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES
17  *  OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
18  *  WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
19  *  ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
20  */
21
22#ifdef HAVE_CONFIG_H
23#include "config.h"
24#endif
25
26#include <math.h>
27
28int test( void );
29
30int test( void )
31{
32  double x = 4 ,  result , iptr ;
33
34  result = modf( x , &iptr ) ;
35
36  return (result);
37}
Note: See TracBrowser for help on using the repository browser.