-/* PSPP - computes sample statistics.
+/* PSPP - a program for statistical analysis.
Copyright (C) 1997-9, 2000, 2006, 2007 Free Software Foundation, Inc.
- This program is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2 of the
- License, or (at your option) any later version.
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
- This program is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
- 02110-1301, USA. */
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include <config.h>
#include "private.h"
#include <ctype.h>
-#include <libpspp/alloc.h>
+#include <gsl/gsl_math.h>
#include <libpspp/assertion.h>
#include <libpspp/message.h>
#include "helpers.h"
#include "evaluate.h"
#include <libpspp/pool.h>
+#include "xalloc.h"
+
static void
expr_evaluate (struct expression *e, const struct ccase *c, int case_idx,
void *result)
break;
case OP_return_number:
- *(double *) result = finite (ns[-1]) ? ns[-1] : SYSMIS;
+ *(double *) result = gsl_finite (ns[-1]) ? ns[-1] : SYSMIS;
return;
case OP_return_string:
dump_postfix = 1;
else if (lex_match (lexer, '('))
{
- char name[LONG_NAME_LEN + 1];
+ char name[VAR_NAME_LEN + 1];
struct variable *v;
size_t old_value_cnt;
int width;
if ( ds == NULL )
{
- ds = create_dataset (NULL, NULL);
+ ds = create_dataset ();
d = dataset_dict (ds);
}