guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] GNU Guile branch, master, updated. release_1-9-12-101-g9


From: Andy Wingo
Subject: [Guile-commits] GNU Guile branch, master, updated. release_1-9-12-101-g97b18a6
Date: Tue, 28 Sep 2010 07:19:37 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".

http://git.savannah.gnu.org/cgit/guile.git/commit/?id=97b18a66403aee100021485d85009b975ecb1614

The branch, master has been updated
       via  97b18a66403aee100021485d85009b975ecb1614 (commit)
      from  f2ee6341baa31d75f9734a93545eb2608dd5653c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 97b18a66403aee100021485d85009b975ecb1614
Author: Andy Wingo <address@hidden>
Date:   Tue Sep 28 09:22:38 2010 +0200

    default to regular vm for noninteractive use
    
    * libguile/script.c (scm_compile_shell_switches): Select the debugging
      VM in the cases that we previously would select deval -- when running
      interactively without --no-debug, or otherwise with --debug.
    
    * libguile/vm.c: Default to the regular engine.
      (scm_c_set_vm_engine_x): Remove requirement for the VM to have no
      pending computations.

-----------------------------------------------------------------------

Summary of changes:
 libguile/script.c |    4 ++++
 libguile/vm.c     |   14 +-------------
 2 files changed, 5 insertions(+), 13 deletions(-)

diff --git a/libguile/script.c b/libguile/script.c
index 03d5de1..088c06b 100644
--- a/libguile/script.c
+++ b/libguile/script.c
@@ -40,6 +40,7 @@
 #include "libguile/strports.h"
 #include "libguile/validate.h"
 #include "libguile/version.h"
+#include "libguile/vm.h"
 
 #ifdef HAVE_STRING_H
 #include <string.h>
@@ -718,7 +719,10 @@ scm_compile_shell_switches (int argc, char **argv)
      was not explicitly turned off, turn on debugging. */
   if (turn_on_debugging || (interactive && !dont_turn_on_debugging))
     {
+      /* FIXME: backtraces and positions should always be on (?) */
       tail = scm_cons (scm_cons (sym_turn_on_debugging, SCM_EOL), tail);
+      scm_c_set_default_vm_engine_x (SCM_VM_DEBUG_ENGINE);
+      scm_c_set_vm_engine_x (scm_the_vm (), SCM_VM_DEBUG_ENGINE);
     }
 
   {
diff --git a/libguile/vm.c b/libguile/vm.c
index 05e1f71..29d6862 100644
--- a/libguile/vm.c
+++ b/libguile/vm.c
@@ -36,7 +36,7 @@
 #include "programs.h"
 #include "vm.h"
 
-static int vm_default_engine = SCM_VM_DEBUG_ENGINE;
+static int vm_default_engine = SCM_VM_REGULAR_ENGINE;
 
 /* Unfortunately we can't snarf these: snarfed things are only loaded up from
    (system vm vm), which might not be loaded before an error happens. */
@@ -745,13 +745,6 @@ vm_engine_to_symbol (int engine, const char *FUNC_NAME)
     }
 }
   
-static int
-vm_has_pending_computation (SCM vm)
-{
-  struct scm_vm *vp = SCM_VM_DATA (vm);
-  return vp->sp >= vp->stack_base;
-}
-
 SCM_DEFINE (scm_vm_engine, "vm-engine", 1, 0, 0,
            (SCM vm),
            "")
@@ -768,11 +761,6 @@ scm_c_set_vm_engine_x (SCM vm, int engine)
 {
   SCM_VALIDATE_VM (1, vm);
 
-  if (vm_has_pending_computation (vm))
-    SCM_MISC_ERROR ("VM engine may only be changed while there are no "
-                    "pending computations.",
-                    SCM_EOL);
-
   if (engine < 0 || engine >= SCM_VM_NUM_ENGINES)
     SCM_MISC_ERROR ("Unknown VM engine: ~a",
                     scm_list_1 (scm_from_int (engine)));


hooks/post-receive
-- 
GNU Guile



reply via email to

[Prev in Thread] Current Thread [Next in Thread]