[racket-dev] Feature request - contract form that splits provide/contract into two parts

From: Harry Spier (vasishtha.spier at gmail.com)
Date: Fri Dec 14 01:02:32 EST 2012

If you place provide/contract at the beginning of a module it makes
the interface clear but it is separated from its function.  If you
place it right before its function and not at the top of the module,
it makes the function clearer but the module interface is not so
clear.

Is it possible (would it be a good idea?) to provide a new form that
splits the provide/contract form into two parts.  One part the
contract definition which you could place immediately before the
function definition and the second part a provide spec for inclusion
in a provide statement that included the function name but not the
contract spec.) .  That way the contract definition can be by the
function definition and the function name can be in a provide
statement at the beginning of the module.

Harry Spier

Posted on the dev mailing list.