* guile and XML (mixp)
@ 2006-11-22 17:26 Paul Emsley
2006-11-22 18:51 ` Neil Jerram
0 siblings, 1 reply; 8+ messages in thread
From: Paul Emsley @ 2006-11-22 17:26 UTC (permalink / raw)
Anyone using mixp and can help out here?
$ [configure/make/make install all clean]
$ cd test
$ guile-expat test-mixp.scm
/xxx/guile/1.6/ice-9/syncase.scm:130:16: In procedure scm-error in expression (scm-error (quote misc-error) who ...):
/xxx/share/guile/1.6/ice-9/syncase.scm:130:16: invalid syntax ()
$ guile --version
Guile 1.6.7
using mixp-0.4
Cheers,
Paul.
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
2006-11-22 17:26 Paul Emsley
@ 2006-11-22 18:51 ` Neil Jerram
2006-11-27 13:30 ` Jon Wilson
[not found] ` <456AE847.5030101@fastmail.fm>
0 siblings, 2 replies; 8+ messages in thread
From: Neil Jerram @ 2006-11-22 18:51 UTC (permalink / raw)
Cc: guile-user
Paul Emsley <emsley@ysbl.york.ac.uk> writes:
> Anyone using mixp and can help out here?
>
>
> $ [configure/make/make install all clean]
> $ cd test
> $ guile-expat test-mixp.scm
> /xxx/guile/1.6/ice-9/syncase.scm:130:16: In procedure scm-error in expression (scm-error (quote misc-error) who ...):
> /xxx/share/guile/1.6/ice-9/syncase.scm:130:16: invalid syntax ()
>
> $ guile --version
> Guile 1.6.7
>
> using mixp-0.4
Whoever is doing (use-modules (ice-9 syncase)) needs to do (use-syntax
(ice-9 syncase)) instead.
Regards,
Neil
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
@ 2006-11-22 20:56 dsmich
0 siblings, 0 replies; 8+ messages in thread
From: dsmich @ 2006-11-22 20:56 UTC (permalink / raw)
Cc: guile-user
---- Paul Emsley <emsley@ysbl.york.ac.uk> wrote:
>
> Anyone using mixp and can help out here?
>
>
> $ [configure/make/make install all clean]
> $ cd test
> $ guile-expat test-mixp.scm
> /xxx/guile/1.6/ice-9/syncase.scm:130:16: In procedure scm-error in expression (scm-error (quote misc-error) who ...):
> /xxx/share/guile/1.6/ice-9/syncase.scm:130:16: invalid syntax ()
The fix for this has been in cvs for about 2 years. I guess it's time for a release!
-Dale
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
2006-11-22 18:51 ` Neil Jerram
@ 2006-11-27 13:30 ` Jon Wilson
[not found] ` <456AE847.5030101@fastmail.fm>
1 sibling, 0 replies; 8+ messages in thread
From: Jon Wilson @ 2006-11-27 13:30 UTC (permalink / raw)
Hi Neil,
> Whoever is doing (use-modules (ice-9 syncase)) needs to do (use-syntax
> (ice-9 syncase)) instead.
>
I see this fairly often. Perhaps there should be some little widget in
(ice-9 syncase) which says "If you try to use=modules me, you will
actually get use-syntax instead.). Or could an argument be made for
combining use-modules and use-syntax? Are there any cases where one
would write a module, and then at some times want to use-modules it, and
at other times want to use-syntax it, so that the user would need to
specify which one was wanted?
Regards,
Jon
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
[not found] ` <456AE847.5030101@fastmail.fm>
@ 2006-11-27 22:05 ` Neil Jerram
2006-11-27 22:44 ` Jon Wilson
2006-11-28 8:43 ` Ludovic Courtès
0 siblings, 2 replies; 8+ messages in thread
From: Neil Jerram @ 2006-11-27 22:05 UTC (permalink / raw)
Cc: Guile Users
Jon Wilson <j85wilson@fastmail.fm> writes:
> Hi Neil,
>> Whoever is doing (use-modules (ice-9 syncase)) needs to do (use-syntax
>> (ice-9 syncase)) instead.
>>
> I see this fairly often. Perhaps there should be some little widget
> in (ice-9 syncase) which says "If you try to use=modules me, you will
> actually get use-syntax instead.). Or could an argument be made for
> combining use-modules and use-syntax? Are there any cases where one
> would write a module, and then at some times want to use-modules it,
> and at other times want to use-syntax it, so that the user would need
> to specify which one was wanted?
It's conceivable, but probably quite unlikely.
I'm not sure I like the idea of a module automagically switching its
user's intent from use-module to use-syntax. That feels too
non-explicit to me.
What seems very reasonable, however, would be a way for a module to
discover whether it is being loaded for use-syntax or use-module, so
that it can emit a warning, or even signal an error, if the use is
inappropriate.
Perhaps something like this...
(define-module (ice-9 syncase)
...
#:use-hook my-use-hook)
(define (my-use-hook usage)
(or (eq? usage #:use-syntax)
(error "The (ice-9 syncase) module should always be used by
calling (use-syntax ...), not (use-modules ...)")))
...
Does that sound reasonable?
Regards,
Neil
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
2006-11-27 22:05 ` Neil Jerram
@ 2006-11-27 22:44 ` Jon Wilson
2006-11-28 8:43 ` Ludovic Courtès
1 sibling, 0 replies; 8+ messages in thread
From: Jon Wilson @ 2006-11-27 22:44 UTC (permalink / raw)
Hi Neil,
> What seems very reasonable, however, would be a way for a module to
> discover whether it is being loaded for use-syntax or use-module, so
> that it can emit a warning, or even signal an error, if the use is
> inappropriate.
>
> Perhaps something like this...
>
> (define-module (ice-9 syncase)
> ...
> #:use-hook my-use-hook)
>
> (define (my-use-hook usage)
> (or (eq? usage #:use-syntax)
> (error "The (ice-9 syncase) module should always be used by
> calling (use-syntax ...), not (use-modules ...)")))
>
> ...
>
> Does that sound reasonable?
>
Sounds great to me.
Regards,
Jon
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
2006-11-27 22:05 ` Neil Jerram
2006-11-27 22:44 ` Jon Wilson
@ 2006-11-28 8:43 ` Ludovic Courtès
2006-11-28 13:36 ` Dale P. Smith
1 sibling, 1 reply; 8+ messages in thread
From: Ludovic Courtès @ 2006-11-28 8:43 UTC (permalink / raw)
Cc: Guile Users
Hi,
Neil Jerram <neil@ossau.uklinux.net> writes:
> What seems very reasonable, however, would be a way for a module to
> discover whether it is being loaded for use-syntax or use-module, so
> that it can emit a warning, or even signal an error, if the use is
> inappropriate.
>
> Perhaps something like this...
>
> (define-module (ice-9 syncase)
> ...
> #:use-hook my-use-hook)
>
> (define (my-use-hook usage)
> (or (eq? usage #:use-syntax)
> (error "The (ice-9 syncase) module should always be used by
> calling (use-syntax ...), not (use-modules ...)")))
>
> ...
>
> Does that sound reasonable?
I'm not sure extending `define-module' just to solve this specific
problem is a good idea. In particular, `use-syntax' itself doesn't seem
too reasonable (see [0]). Thus, in the long-term, it may be preferable
to remove `use-syntax' or replace it with more robust primitives, rather
than working around it.
Thanks,
Ludovic.
[0] http://lists.gnu.org/archive/html/guile-devel/2006-07/msg00019.html
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: guile and XML (mixp)
2006-11-28 8:43 ` Ludovic Courtès
@ 2006-11-28 13:36 ` Dale P. Smith
0 siblings, 0 replies; 8+ messages in thread
From: Dale P. Smith @ 2006-11-28 13:36 UTC (permalink / raw)
Cc: Guile Users
ludovic.courtes@laas.fr (Ludovic Courtès) writes:
> Hi,
>
> Neil Jerram <neil@ossau.uklinux.net> writes:
>
>> What seems very reasonable, however, would be a way for a module to
>> discover whether it is being loaded for use-syntax or use-module, so
>> that it can emit a warning, or even signal an error, if the use is
>> inappropriate.
>>
>
> I'm not sure extending `define-module' just to solve this specific
> problem is a good idea. In particular, `use-syntax' itself doesn't seem
> too reasonable (see [0]). Thus, in the long-term, it may be preferable
> to remove `use-syntax' or replace it with more robust primitives, rather
> than working around it.
I suspect that the sole purpose of use-syntax was to allow the use of
syntax-case macros instead of the non-standard lisp style macros that
are the default. I don't think it was ever intended to be generally
useful.
Long term, Guile should probably have syntax-case macros available
without having to resort to use-syntax.
-Dale
--
Dale P. Smith
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2006-11-28 13:36 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-22 20:56 guile and XML (mixp) dsmich
-- strict thread matches above, loose matches on Subject: below --
2006-11-22 17:26 Paul Emsley
2006-11-22 18:51 ` Neil Jerram
2006-11-27 13:30 ` Jon Wilson
[not found] ` <456AE847.5030101@fastmail.fm>
2006-11-27 22:05 ` Neil Jerram
2006-11-27 22:44 ` Jon Wilson
2006-11-28 8:43 ` Ludovic Courtès
2006-11-28 13:36 ` Dale P. Smith
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).