projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Autorecode: use locale independent printf function
[pspp]
/
src
/
language
/
lexer
/
variable-parser.c
diff --git
a/src/language/lexer/variable-parser.c
b/src/language/lexer/variable-parser.c
index c1e1c28cdf404441cd701edd1ef62fdbaee2d6a8..5c19b81e2f5bd8c477f80742464416b8a58f8fb2 100644
(file)
--- a/
src/language/lexer/variable-parser.c
+++ b/
src/language/lexer/variable-parser.c
@@
-893,8
+893,8
@@
lex_match_variable (struct lexer *lexer, const struct dictionary *dict, const st
}
/* An interaction is a variable followed by {*, BY} followed by an interaction */
}
/* An interaction is a variable followed by {*, BY} followed by an interaction */
-bool
-parse_
design_interaction (struct lexer *lexer, const struct dictionary *dict, struct interaction **iac
t)
+
static
bool
+parse_
internal_interaction (struct lexer *lexer, const struct dictionary *dict, struct interaction **iact, struct interaction **i
t)
{
const struct variable *v = NULL;
assert (iact);
{
const struct variable *v = NULL;
assert (iact);
@@
-915,7
+915,8
@@
parse_design_interaction (struct lexer *lexer, const struct dictionary *dict, st
if (! lex_match_variable (lexer, dict, &v))
{
if (! lex_match_variable (lexer, dict, &v))
{
- interaction_destroy (*iact);
+ if (it)
+ interaction_destroy (*it);
*iact = NULL;
return false;
}
*iact = NULL;
return false;
}
@@
-929,9
+930,15
@@
parse_design_interaction (struct lexer *lexer, const struct dictionary *dict, st
if ( lex_match (lexer, T_ASTERISK) || lex_match (lexer, T_BY))
{
if ( lex_match (lexer, T_ASTERISK) || lex_match (lexer, T_BY))
{
- return parse_
design_interaction (lexer, di
ct, iact);
+ return parse_
internal_interaction (lexer, dict, ia
ct, iact);
}
return true;
}
}
return true;
}
+bool
+parse_design_interaction (struct lexer *lexer, const struct dictionary *dict, struct interaction **iact)
+{
+ return parse_internal_interaction (lexer, dict, iact, NULL);
+}
+