Remove @function and make @contractor do that job instead, e.g.
const C = @contractor f(x) = 4x
will automatically define the const function f, such that f(X) just applies the forward function for standard function evaluation, but
does the forward-backward contractor.