10 Cooperating with Background Check Syntax🔗ℹ

DrRacket’s continuous, background check syntax runs each time an edit to the definitions text happens. In some cases, that expansion process fails, but there is still a well-formed syntax object that check syntax can use to display information to the user. In order to communicate that syntax object to check syntax, send a log message with the name 'online-check-syntax, e.g.
(define-logger online-check-syntax)
(log-message online-check-syntax-logger
             'info
             "ignored message"
             list-of-syntax-objects)
The fourth argument to log-message should be a list of syntax objects; these are processed as if they were the result of expansion.

The syntax objects whose syntax-source field does not match the source of the file that is currently being expanded are ignored. That is, sometimes a macro may log a syntax object to be used by DrRacket in this fashion, but the macro may not be from the file that DrRacket’s expanding, but one from one that is required by it; hence this check is in place to skip them.

Note: the identifiers in these objects should be syntax-original? or else they will be ignored by check syntax.