mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-16 16:50:21 +02:00
Fix C99-style declarations after statements.
* libguile/eval.i.c (ceval): Move declarations before statements. * libguile/read.c (scm_read_extended_symbol): Likewise. * libguile/struct.c (scm_make_struct_layout): Likewise. * libguile/threads.c (fat_mutex_unlock): Likewise. * libguile/vm-i-system.c (br_if_nargs_ne, br_if_nargs_lt): Likewise. * libguile/vm.c (make_vm): Likewise.
This commit is contained in:
parent
6bd210e090
commit
7f991c7d32
6 changed files with 15 additions and 8 deletions
|
@ -883,9 +883,11 @@ dispatch:
|
|||
#ifdef DEVAL
|
||||
if (scm_check_memoize_p && SCM_TRAPS_P)
|
||||
{
|
||||
SCM arg1, retval;
|
||||
|
||||
SCM_CLEAR_TRACED_FRAME (debug);
|
||||
SCM arg1 = scm_make_debugobj (&debug);
|
||||
SCM retval = SCM_BOOL_T;
|
||||
arg1 = scm_make_debugobj (&debug);
|
||||
retval = SCM_BOOL_T;
|
||||
SCM_TRAPS_P = 0;
|
||||
retval = scm_call_4 (SCM_MEMOIZE_HDLR,
|
||||
scm_sym_memoize_symbol,
|
||||
|
|
|
@ -1088,8 +1088,10 @@ scm_read_extended_symbol (scm_t_wchar chr, SCM port)
|
|||
|
||||
if (len >= scm_i_string_length (buf) - 2)
|
||||
{
|
||||
SCM addy;
|
||||
|
||||
scm_i_string_stop_writing ();
|
||||
SCM addy = scm_i_make_string (1024, NULL);
|
||||
addy = scm_i_make_string (1024, NULL);
|
||||
buf = scm_string_append (scm_list_2 (buf, addy));
|
||||
len = 0;
|
||||
buf = scm_i_string_start_writing (buf);
|
||||
|
|
|
@ -63,9 +63,10 @@ SCM_DEFINE (scm_make_struct_layout, "make-struct-layout", 1, 0, 0,
|
|||
#define FUNC_NAME s_scm_make_struct_layout
|
||||
{
|
||||
SCM new_sym;
|
||||
SCM_VALIDATE_STRING (1, fields);
|
||||
scm_t_wchar c;
|
||||
|
||||
SCM_VALIDATE_STRING (1, fields);
|
||||
|
||||
{ /* scope */
|
||||
size_t len;
|
||||
int x;
|
||||
|
|
|
@ -1373,6 +1373,7 @@ static int
|
|||
fat_mutex_unlock (SCM mutex, SCM cond,
|
||||
const scm_t_timespec *waittime, int relock)
|
||||
{
|
||||
SCM owner;
|
||||
fat_mutex *m = SCM_MUTEX_DATA (mutex);
|
||||
fat_cond *c = NULL;
|
||||
scm_i_thread *t = SCM_I_CURRENT_THREAD;
|
||||
|
@ -1380,7 +1381,7 @@ fat_mutex_unlock (SCM mutex, SCM cond,
|
|||
|
||||
scm_i_scm_pthread_mutex_lock (&m->lock);
|
||||
|
||||
SCM owner = m->owner;
|
||||
owner = m->owner;
|
||||
|
||||
if (!scm_is_eq (owner, scm_current_thread ()))
|
||||
{
|
||||
|
|
|
@ -513,9 +513,9 @@ VM_DEFINE_INSTRUCTION (40, br_if_not_null, "br-if-not-null", 3, 0, 0)
|
|||
VM_DEFINE_INSTRUCTION (41, br_if_nargs_ne, "br-if-nargs-ne", 5, 0, 0)
|
||||
{
|
||||
scm_t_ptrdiff n;
|
||||
scm_t_int32 offset;
|
||||
n = FETCH () << 8;
|
||||
n += FETCH ();
|
||||
scm_t_int32 offset;
|
||||
FETCH_OFFSET (offset);
|
||||
if (sp - (fp - 1) != n)
|
||||
ip += offset;
|
||||
|
@ -525,9 +525,9 @@ VM_DEFINE_INSTRUCTION (41, br_if_nargs_ne, "br-if-nargs-ne", 5, 0, 0)
|
|||
VM_DEFINE_INSTRUCTION (42, br_if_nargs_lt, "br-if-nargs-lt", 5, 0, 0)
|
||||
{
|
||||
scm_t_ptrdiff n;
|
||||
scm_t_int32 offset;
|
||||
n = FETCH () << 8;
|
||||
n += FETCH ();
|
||||
scm_t_int32 offset;
|
||||
FETCH_OFFSET (offset);
|
||||
if (sp - (fp - 1) < n)
|
||||
ip += offset;
|
||||
|
|
|
@ -298,11 +298,12 @@ make_vm (void)
|
|||
#define FUNC_NAME "make_vm"
|
||||
{
|
||||
int i;
|
||||
struct scm_vm *vp;
|
||||
|
||||
if (!scm_tc16_vm)
|
||||
return SCM_BOOL_F; /* not booted yet */
|
||||
|
||||
struct scm_vm *vp = scm_gc_malloc (sizeof (struct scm_vm), "vm");
|
||||
vp = scm_gc_malloc (sizeof (struct scm_vm), "vm");
|
||||
|
||||
vp->stack_size = VM_DEFAULT_STACK_SIZE;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue