1dnl Support macros for findloc.
2dnl This file is part of the GNU Fortran Runtime Library (libgfortran)
3dnl Distributed under the GNU GPL with exception.  See COPYING for details.
4include(iparm.m4)dnl
5define(header1,`extern void findloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
6       	    		'atype` * const restrict array, 'atype_name` *value,
7			 GFC_LOGICAL_4 back, gfc_charlen_type len_array, gfc_charlen_type len_value);
8
9export_proto(findloc0_'atype_code`);
10
11void
12findloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
13    	    'atype` * const restrict array, 'atype_name` *value,
14	    GFC_LOGICAL_4 back, gfc_charlen_type len_array, gfc_charlen_type len_value)')dnl
15dnl
16define(header2,`extern void mfindloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
17       	    		'atype` * const restrict array, 'atype_name` *value,
18			 gfc_array_l1 *const restrict, GFC_LOGICAL_4 back, gfc_charlen_type len_array,
19			 gfc_charlen_type len_value);
20export_proto(mfindloc0_'atype_code`);
21
22void
23mfindloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
24    	    'atype` * const restrict array, 'atype_name` *value,
25	    gfc_array_l1 *const restrict mask, GFC_LOGICAL_4 back,
26	    gfc_charlen_type len_array, gfc_charlen_type len_value)')
27dnl
28define(header3,`extern void sfindloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
29       	    		'atype` * const restrict array, 'atype_name` *value,
30			 GFC_LOGICAL_4 *, GFC_LOGICAL_4 back, gfc_charlen_type len_array,
31			 gfc_charlen_type len_value);
32export_proto(sfindloc0_'atype_code`);
33
34void
35sfindloc0_'atype_code` (gfc_array_index_type * const restrict retarray,
36    	    'atype` * const restrict array, 'atype_name` *value,
37	    GFC_LOGICAL_4 * mask, GFC_LOGICAL_4 back, gfc_charlen_type len_array,
38	    gfc_charlen_type len_value)')dnl
39dnl
40define(comparison,ifelse(atype_kind,4,dnl
41`compare_string_char4 (len_array, base, len_value, value) == 0',dnl
42`compare_string (len_array, (char *) base, len_value, (char *) value) == 0'))dnl
43define(len_arg,`, len_array, len_value')dnl
44define(base_mult,`len_array')dnl
45include(ifindloc0.m4)dnl
46
47
48
49