projects
/
pspp-builds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use macros from cast.h instead of literal casts
[pspp-builds.git]
/
src
/
language
/
data-io
/
data-reader.c
diff --git
a/src/language/data-io/data-reader.c
b/src/language/data-io/data-reader.c
index e9bcbfa9dc38d6a77aaffc9ee0b7a06476d28bb9..061505f889075cf2ea66d5709c1bc1e5563ad344 100644
(file)
--- a/
src/language/data-io/data-reader.c
+++ b/
src/language/data-io/data-reader.c
@@
-1,5
+1,5
@@
/* PSPP - a program for statistical analysis.
/* PSPP - a program for statistical analysis.
- Copyright (C) 1997-2004, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1997-2004, 2006
, 2010
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
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
@@
-677,20
+677,16
@@
dfm_get_column (const struct dfm_reader *r, const char *p)
return ds_pointer_to_position (&r->line, p) + 1;
}
return ds_pointer_to_position (&r->line, p) + 1;
}
-/* Pushes the file name and line number on the fn/ln stack. */
-void
-dfm_push (struct dfm_reader *r)
+const char *
+dfm_get_file_name (const struct dfm_reader *r)
{
{
- if (r->fh != fh_inline_file ())
- msg_push_msg_locator (&r->where);
+ return fh_get_referent (r->fh) == FH_REF_FILE ? r->where.file_name : NULL;
}
}
-/* Pops the file name and line number from the fn/ln stack. */
-void
-dfm_pop (struct dfm_reader *r)
+int
+dfm_get_line_number (const struct dfm_reader *r)
{
{
- if (r->fh != fh_inline_file ())
- msg_pop_msg_locator (&r->where);
+ return fh_get_referent (r->fh) == FH_REF_FILE ? r->where.line_number : -1;
}
\f
/* BEGIN DATA...END DATA procedure. */
}
\f
/* BEGIN DATA...END DATA procedure. */