projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed dependent/independent variable separation
[pspp]
/
src
/
q2c.c
diff --git
a/src/q2c.c
b/src/q2c.c
index 6318edd395fe1a53a057d01aee289bc9b91b60a0..3bba239035f7120ed1ac264ce42f3f156c1db809 100644
(file)
--- a/
src/q2c.c
+++ b/
src/q2c.c
@@
-14,8
+14,8
@@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
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., 5
9 Temple Place - Suite 330
, Boston, MA
- 0211
1-1307
, USA. */
+ Foundation, Inc., 5
1 Franklin Street, Fifth Floor
, Boston, MA
+ 0211
0-1301
, USA. */
#include <config.h>
#include <assert.h>
#include <config.h>
#include <assert.h>
@@
-284,7
+284,7
@@
add_symbol (const char *name, int unique, int value)
symbol *iter, *sym;
int x;
symbol *iter, *sym;
int x;
- sym = xmalloc (sizeof
(symbol)
);
+ sym = xmalloc (sizeof
*sym
);
sym->name = xstrdup (name);
sym->unique = unique;
sym->value = value;
sym->name = xstrdup (name);
sym->unique = unique;
sym->value = value;
@@
-724,7
+724,7
@@
parse_specifier (specifier *spec, subcommand *sbc)
for (;;)
{
for (;;)
{
- *s = xmalloc (sizeof
(setting)
);
+ *s = xmalloc (sizeof
**s
);
parse_setting (*s, spec);
if (token == ',' || token == ';' || token == '.')
break;
parse_setting (*s, spec);
if (token == ',' || token == ';' || token == '.')
break;
@@
-749,7
+749,7
@@
parse_specifiers (subcommand *sbc)
for (;;)
{
for (;;)
{
- *spec = xmalloc (sizeof
(specifier)
);
+ *spec = xmalloc (sizeof
**spec
);
parse_specifier (*spec, sbc);
if (token == ';' || token == '.')
break;
parse_specifier (*spec, sbc);
if (token == ';' || token == '.')
break;
@@
-893,7
+893,7
@@
parse_subcommands (void)
for (;;)
{
for (;;)
{
- *sbc = xmalloc (sizeof
(subcommand)
);
+ *sbc = xmalloc (sizeof
**sbc
);
(*sbc)->next = NULL;
parse_subcommand (*sbc);
(*sbc)->next = NULL;
parse_subcommand (*sbc);
@@
-1143,7
+1143,7
@@
dump_declarations (void)
break;
case SBC_VARLIST:
break;
case SBC_VARLIST:
- dump (0, "
in
t %sn_%s;", st_lower (sbc->prefix),
+ dump (0, "
size_
t %sn_%s;", st_lower (sbc->prefix),
st_lower (sbc->name));
dump (0, "struct variable **%sv_%s;", st_lower (sbc->prefix),
st_lower (sbc->name));
st_lower (sbc->name));
dump (0, "struct variable **%sv_%s;", st_lower (sbc->prefix),
st_lower (sbc->name));
@@
-2206,7
+2206,10
@@
main (int argc, char *argv[])
dump (0, "#include \"str.h\"");
dump (0, "#include \"subclist.h\"");
dump (0, "#include \"var.h\"");
dump (0, "#include \"str.h\"");
dump (0, "#include \"subclist.h\"");
dump (0, "#include \"var.h\"");
+ dump (0, nullstr);
+ dump (0, "#include \"gettext.h\"");
+ dump (0, "#define _(msgid) gettext (msgid)");
dump (0, nullstr);
}
else if (!strcmp (directive, "declarations"))
dump (0, nullstr);
}
else if (!strcmp (directive, "declarations"))
@@
-2248,7
+2251,7
@@
aux_parse (void)
for (;;)
{
for (;;)
{
- sbc = xmalloc
(sizeof(aux_subcommand)
);
+ sbc = xmalloc
(sizeof *sbc
);
sbc->next = prevsbc;
sbc->name = xstrdup (tokstr);
lex_get();
sbc->next = prevsbc;
sbc->name = xstrdup (tokstr);
lex_get();