chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] segfault is not enough


From: Joerg F. Wittenberger
Subject: Re: [Chicken-users] segfault is not enough
Date: 15 Apr 2003 16:40:30 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Hi Felix,

I do have a problem to isolate the problem.  I just have been able to
fix one instance of the segfault problem by rearranging the
definitions in the source code.

Now I have:

(define rfc-822-time-string-format "~a, ~d ~b ~Y ~H:~M:~S ~z")

(define (rfc-822-timestring t)
  (srfi19:date->string t rfc-822-time-string-format))

(define (logerr . args)
  (display (rfc-822-timestring (current-date (timezone-offset)))
           (current-error-port))
  (apply format (current-error-port) args)
  (flush-output-port (current-error-port)))


Before the `rfc-822-timestring' was defined in the same file a few
more lines after `logerr'.  A test use of logerr appeared immedately
after it's definition.

Does this info already help?

/Jörg

Felix Winkelmann <address@hidden> writes:

> Joerg F. Wittenberger wrote:
> > Hi all,
> > I just compiled a program with these flags
> > CSCFLAGS=-case-sensitive -keyword-style suffix -extend extend.scm
> > -optimize-level 2 -debug-level 0 and wondered why it segfaulted.  I
> > forgot to implement a certain
> > function.  :-/
> > I feel that a segfault is not exactly what a Scheme system should do,
> > at least not when not compiled unsafe.
> >
> 
> If you forget to define a function and didn't get an error message,
> then there is a bug in the compiler or runtime-system. Normally
> unbound variables *always* signal an error.
> 
> Would you care to send me the exact code that caused the problem?

-- 
The worst of harm may often result from the best of intentions.




reply via email to

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