Search code examples
racketscribble

How can I use tech as a contract in defproc?


Is it possible to have

@defproc[(foo) bar]{
  Blah blah
}

where bar is defined via deftech while linking to bar correctly?


Solution

  • Yes! Use #,:

    #lang scribble/manual
    
    @defproc[(foo) #,(tech "bar")]{
      Blah blah
    }
    
    @section{What is bar?}
    
    A @deftech{bar} is a baz.