[plt-scheme] provide/contract and inferred-name

From: Doug Orleans (dougorleans at gmail.com)
Date: Mon Apr 14 20:34:00 EDT 2008

Robby Findler writes:
 > Unfortunately, not. Function contracts create wrappers. And the
 > wrapper is created as part of the ->, only once, before the actual
 > function shows up. So, the contract library does its best and uses the
 > name in the contract (but even this is not possible if you start
 > abstracting over the contract constructors).

If I use `rename', could it use the external name as the inferred name?

  #lang scheme

  (define (foo) 0)
  (provide/contract (rename foo bar (-> number?)))

  > bar

--dougorleans at gmail.com

Posted on the users mailing list.