Commit 99eec421 authored by Ronny Wichers Schreur's avatar Ronny Wichers Schreur 🏘
Browse files

made name generation depend on _ANALYSE_IDENT_

marked duplicate definitions of cTypeDelimiter _ANALYSE_IDENT_
parent c95db660
......@@ -284,7 +284,7 @@ static char *PrintTypesOfSymbol (char *type_repr, File file, ModuleInfo module_i
} /* PrintTypesOfSymbol */
#define _ANALYSE_IDENT_
#define _ANALYSE_IDENT_ /* also in optimisations.c */
#ifndef CLEAN2
#define _ANALYSE_INSTANCE_TYPES_
#endif
......
#define cTypeDelimiter ';'
#define cTypeDelimiter ';' /* also in optimisations.c */
#define cTypeFirstArg '<'
#define cTypeLastArg '>'
......
......@@ -26,6 +26,7 @@
# if TAIL_CALL_MODULO_TUPLE_CONS_OPTIMIZATION
#include "tuple_tail_recursion.h"
# endif
#include "dbprint.h"
static char *ECodeBlock = "incorrect number of output parameters";
......
......@@ -1034,7 +1034,8 @@ static void init_apply_symb_function_state_p()
}
#endif
#define cTypeDelimiter ';'
#define cTypeDelimiter ';' /* also in checksupport.h */
#define _ANALYSE_IDENT_ /* also in checksupport.c */
static int compute_length_before_type_delimiter (char *fname)
{
......@@ -1043,11 +1044,30 @@ static int compute_length_before_type_delimiter (char *fname)
p=fname;
#ifdef _ANALYSE_IDENT_
--p;
do {
c=*++p;
} while (c!=cTypeDelimiter && c!='\0');
if (c == cTypeDelimiter && *(p+1) != '\0')
{
p++;
if (isdigit (*p))
{
for (p = p+1; *p != cTypeDelimiter && *p != '\0'; p++)
;
}
}
#else /* ifndef _ANALYSE_IDENT_ */
--p;
do {
c=*++p;
} while (c!='\0');
#endif /* _ANALYSE_IDENT_ */
return p-fname;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment