FreeBSD/contrib/elftoolchain/libelftc/libelftc_dem_gnu3.c
/*
 * Read template parameter that forms in 'T[number]_'.
 * This function much like to read_subst but only for types.
 */
Read template parameter that forms in 'T[number]_'.
This function much like to read_subst but only for types.
Read template parameter that forms in ' T [ number ] _ ' . This function much like to read_subst but only for types .
static int
cpp_demangle_read_tmpl_param(struct cpp_demangle_data *ddata)
{
	long nth;
	if (ddata == NULL || *ddata->cur != 'T')
		return (0);
	++ddata->cur;
	if (*ddata->cur == '_')
		return (cpp_demangle_get_tmpl_param(ddata, 0));
	else {
		errno = 0;
		if ((nth = strtol(ddata->cur, (char **) NULL, 36)) == 0 &&
		    errno != 0)
			return (0);
		++nth;
		while (*ddata->cur != '_')
			++ddata->cur;
		assert(nth > 0);
		return (cpp_demangle_get_tmpl_param(ddata, nth));
	}
	return (0);
}
static int cpp_demangle_read_tmpl_param ( struct cpp_demangle_data * ddata ) { long nth ; if ( ddata == NULL || * ddata -> cur != ' ' ) return ( 0 ) ; ++ ddata -> cur ; if ( * ddata -> cur == ' ' ) return ( cpp_demangle_get_tmpl_param ( ddata , 0 ) ) ; else { errno = 0 ; if ( ( nth = strtol ( ddata -> cur , ( char * * ) NULL , 36 ) ) == 0 && errno != 0 ) return ( 0 ) ; ++ nth ; while ( * ddata -> cur != ' ' ) ++ ddata -> cur ; assert ( nth > 0 ) ; return ( cpp_demangle_get_tmpl_param ( ddata , nth ) ) ; } return ( 0 ) ; }
Read template parameter that forms in 'T[number]_'.
Read template parameter that forms in ' T [ number ] _ ' .
/* T_ is first */ /* NOTREACHED */