Files
epics-base/modules/libcom/test/epicsInlineTest2.c
Andrew Johnson 3c99391d93 Added SPDX License ID to all EPICS-original source files
In some cases the license-identification header was missing,
so I added that as well. Replaced the remaining headers that
specifically identified "Versions 3.13.7 and higher".

Makefiles and the build system were deliberately excluded.
2020-08-03 11:53:01 -05:00

30 lines
789 B
C

/*************************************************************************\
* Copyright (c) 2015 Brookhaven Science Associates, as Operator of
* Brookhaven National Laboratory.
* SPDX-License-Identifier: EPICS
* EPICS BASE is distributed subject to a Software License Agreement found
* in file LICENSE that is included with this distribution.
\*************************************************************************/
#include "compilerSpecific.h"
#include "epicsUnitTest.h"
static EPICS_ALWAYS_INLINE int epicsInlineTestFn1(void)
{
return 2;
}
/* Fails to link in C99
inline int epicsInlineTestFn2(void)
{
return 42;
}
*/
void epicsInlineTest2(void)
{
testDiag("epicsInlineTest2()");
testOk1(epicsInlineTestFn1()==2);
/*testOk1(epicsInlineTestFn2()==42);*/
}