On Mon, May 14, 2018 at 10:07 PM, Greg Hendershott <greghendersh...@gmail.com> wrote: > David you wrote "both" so I just wanted to point out I read three ways:
Good point; I misspoke. (Mistyped?) > 4. It doesn't sound like this is your case, but: If there are many > function calls where you pass the extra parameter, and that's > annoying? Keep in mind you can use a `make-parameter` parameter. (You > can even do both, e.g. there's an optional argument, the default value > of which is the current parameter value.) Of course, that requires > some new .rkt file where you define and provide the parameter, and the > other files need to require _that_. Whether that's a bug or a > feature, depends. Good thought. I'm using make-parameter is several places already, so expanding it for this could be useful. > Speaking of parameters: Sometimes it can make sense for an app to have > a config.rkt where parameters are defined. Similarly-named environment > variables are read on startup. For example, as one part of a so-called > 12 factor app. But this is orthogonal to what folks were discussing > above. For instance you're not going to read Racket function values > from the environment. :) We have one for our database parameters, so it would be easy enough to expand. Thanks for the idea. -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to racket-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.