Open jackfirth opened 5 years ago
Style rules inspired by #292:
Scribble style rules related to DrRacket's auto-indentation:
examples
, e.g. @(examples (foo) (bar) (baz))
instead of @examples[(foo) (bar) (baz)]
.deftogether
, e.g. @deftogether[[@defproc[...] @defform[...] @defthing[...]]]
.
Now that Rebellion has received a few pull requests from others, I should write down the style rules I follow inside Rebellion's codebase. A separate Scribble document (as in, not the
"rebellion"
document defined in theinfo.rkt
file'sscribblings
field) seems appropriate. This would be distinct from #196 in two ways:To start, here's some things I'll probably add to the rulebook:
#lang
to specify the module language, not top-level(module ...)
formsprovide
goes at the top of each module, before anyrequire
forms (unless they import forms necessary for expandingprovide
, likecontract-out
)require
form are in sorted order#lang racket/base
should never be immediately followed by whitespace( like this)
#lang racket/base
should never be immediately preceded by whitespace(like this )
Hopefully I can automate finding and fixing code that breaks these rules. They're not worth devoting manual attention to in reviews.