Skip to content

Instantly share code, notes, and snippets.

@jakebromberg
Created September 23, 2014 17:55
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 jakebromberg/cf2dd0c451741915bc54 to your computer and use it in GitHub Desktop.
Save jakebromberg/cf2dd0c451741915bc54 to your computer and use it in GitHub Desktop.
Allows code-time validation of key-value coding. Inspired by Justin Spahr-Summers.
#define keypath(object, keypath) \
((void)(NO && ((void)object.keypath, NO)), @ # keypath )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment