Skip to content

Local define-macro #718

@jpellegrini

Description

@jpellegrini

@egallesio

STklos (like Gauche) only allows define-macro in top-level. Is there a strong reason why this is so in STklos?

For example, in Bigloo, Ypsilon, Kawa, Guile and Gambit it's OK:

(let ((x 10))
  (define-macro (a) 2)
  (+ (a) x))                         => 12

(In this case, Bigloo and Kawa create a global macro; the others don't)

Why don't we translate internal define-macro to %let-syntax?

(I'm asking because SRFI-247 for example would necessarily have to expand certain forms info internal defines)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions