Skip to content

Instantly share code, notes, and snippets.

@vtjnash
Created October 24, 2012 05:30
Show Gist options
  • Save vtjnash/3944204 to your computer and use it in GitHub Desktop.
Save vtjnash/3944204 to your computer and use it in GitHub Desktop.
julia macro local variable expression
macro foo(ex)
quote
$(esc(ex))
end
end
function f(x,y)
@foo x+y
end
@assert f(1,2) == 3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment