Static Procedure Renaming
define/  renamed
6.3.90.900

Static Procedure Renaming

 (require static-rename) package: static-rename

syntax

(define/renamed name-id (head args) body ...+)

 
head = id
  | (head args)
     
args = arg ...
  | arg ... . rest-id
     
arg = arg-id
  | [arg-id default-expr]
  | keyword arg-id
  | keyword [arg-id default-expr]
Defines a procedure, just like define, but the name of the procedure as produced by object-name is name-id. This adjustment is done statically, unlike procedure-rename, which changes the name of a procedure at runtime. Therefore, this has a potential performance benefit.

Examples:
> (define/renamed bar (foo x)
    (* 2 x))
> (foo 3)

6

> foo

#<procedure:bar>

> (object-name foo)

'bar