/* GDB interface for Guile
- * Copyright (C) 1996,1997,1999,2000,2001,2002,2004
+ * Copyright (C) 1996,1997,1999,2000,2001,2002,2004,2009,2011,2012
* Free Software Foundation, Inc.
*
* This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
*
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
*/
#ifdef HAVE_CONFIG_H
}
}
gdb_result = ans;
- /* Protect answer from future GC */
+ /* Protect answer from future GC (FIXME: still needed with BDW-GC?) */
if (SCM_NIMP (ans))
scm_permanent_object (ans);
exit:
}
SCM_BEGIN_FOREIGN_BLOCK;
{
- SCM env = scm_top_level_env (SCM_TOP_LEVEL_LOOKUP_CLOSURE);
- gdb_result = scm_permanent_object (scm_i_eval_x (exp, env));
+ gdb_result = scm_permanent_object (scm_primitive_eval (exp));
}
SCM_END_FOREIGN_BLOCK;
return 0;
}
SCM_BEGIN_FOREIGN_BLOCK;
{
- SCM var = scm_sym2var (name, SCM_TOP_LEVEL_LOOKUP_CLOSURE, SCM_BOOL_T);
- SCM_VARIABLE_SET (var, value);
+ scm_define (name, value);
}
SCM_END_FOREIGN_BLOCK;
return 0;
SCM port;
scm_print_carefully_p = 0;
-
- port = scm_mkstrport (SCM_INUM0,
- scm_c_make_string (0, SCM_UNDEFINED),
+
+ port = scm_mkstrport (SCM_INUM0, SCM_BOOL_F,
SCM_OPN | SCM_WRTNG,
s);
gdb_output_port = scm_permanent_object (port);
-
- port = scm_mkstrport (SCM_INUM0,
- scm_c_make_string (0, SCM_UNDEFINED),
+
+ port = scm_mkstrport (SCM_INUM0, SCM_BOOL_F,
SCM_OPN | SCM_RDNG | SCM_WRTNG,
s);
gdb_input_port = scm_permanent_object (port);