Skip to content

Instantly share code, notes, and snippets.

@lkuper
Created September 22, 2011 00:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lkuper/1233728 to your computer and use it in GitHub Desktop.
Save lkuper/1233728 to your computer and use it in GitHub Desktop.
Stuff ignored by the C311 autograder, circa 2010
;; Load the assignment we're testing
(load input-filename
(lambda (x)
(pmatch x
;; Ignore any (load ___) expressions that might happen
;; to be in the assignment.
[(load ,anything) (void)]
;; Ignore tests they've written themselves
[(test . ,anything) (void)]
[(multi-test . ,anything) (void)]
[(display . ,anything) (void)]
[(printf . ,anything) (void)]
;; Strip out potentially malicious system calls
[(system ,anything) (void)]
;; Strip out macros
[(define-syntax ,anything) (void)]
;; TODO: is there anything else we shouldn't be
;; eval'ing?
[,otherwise (eval x)])))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment