Skip to content

Instantly share code, notes, and snippets.

@oleganza
Last active December 23, 2015 21:48
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 oleganza/6698433 to your computer and use it in GitHub Desktop.
Save oleganza/6698433 to your computer and use it in GitHub Desktop.
// I'd like Clang to compile this:
self.view.frame.origin.x = 0;
// Into this:
{
UIView* v = self.view;
CGRect f = [v frame];
f.origin.x = 0;
[v setFrame:f];
}
// If -frame or -setFrame: is not defined, it should be a compile error.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment