struct msg_location *loc = lex_ofs_location (ctx->lexer, start_ofs,
lex_ofs (ctx->lexer) - 1);
- add_summary_spec (sub, function, weighting, area, percentile, label,
- formatp, is_ctables_format, loc, sv);
+ bool ok = add_summary_spec (sub, function, weighting, area, percentile,
+ label, formatp, is_ctables_format, loc, sv);
free (label);
msg_location_destroy (loc);
+ if (!ok)
+ goto error;
+
lex_match (ctx->lexer, T_COMMA);
if (sv == CSV_CELL && lex_match_id (ctx->lexer, "TOTALS"))
{
15 | CTABLES /TABLE qn1 [MEAN TOTALS].
| ^~~
-ctables.sps:15.32: error: CTABLES: Syntax error expecting `@<:@'.
- 15 | CTABLES /TABLE qn1 [MEAN TOTALS].
- | ^
-
ctables.sps:16.21-16.24: error: CTABLES: Summary function MEAN applies only to
scale variables.
16 | CTABLES /TABLE qn1 [MEAN TOTALS[STDDEV]%].
16 | CTABLES /TABLE qn1 [MEAN TOTALS[STDDEV]%].
| ^~~
-ctables.sps:16.40: error: CTABLES: Syntax error expecting `@:>@'.
- 16 | CTABLES /TABLE qn1 [MEAN TOTALS[STDDEV]%].
- | ^
-
ctables.sps:17.56: error: CTABLES: Syntax error expecting string.
17 | CTABLES /TABLE qn1 /CATEGORIES VARIABLES=qn1 [SUBTOTAL=x].
| ^