Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #16326: use typesof in code_* for all :call expressions #17096

Merged
merged 1 commit into from
Jul 2, 2016

Conversation

ihnorton
Copy link
Member

Not sure about The tricky cases [...] like ref for getindex, vcat, etc., but this fixes #16326 and #16487.

@JeffBezanson
Copy link
Sponsor Member

+1 This is much needed. I wonder what's causing the failure?

Update docs/utils.jl to pass test (h/t MichaelHatherly).
@ihnorton ihnorton merged commit eb05662 into JuliaLang:master Jul 2, 2016
@ihnorton ihnorton deleted the fix16326 branch July 2, 2016 14:34
@tkelman
Copy link
Contributor

tkelman commented Jul 2, 2016

test?

@tkelman tkelman added the needs tests Unit tests are required for this change label Jul 2, 2016
ihnorton added a commit that referenced this pull request Jul 2, 2016
@ihnorton
Copy link
Member Author

ihnorton commented Jul 2, 2016

767ddc7

@ihnorton ihnorton removed the needs tests Unit tests are required for this change label Jul 2, 2016
@@ -278,7 +278,8 @@ typesof(args...) = Tuple{map(a->(isa(a,Type) ? Type{a} : typeof(a)), args)...}
gen_call_with_extracted_types(fcn, ex0::Symbol) = Expr(:call, fcn, Meta.quot(ex0))
function gen_call_with_extracted_types(fcn, ex0)
if isa(ex0, Expr) &&
any(a->(Meta.isexpr(a, :kw) || Meta.isexpr(a, :parameters)), ex0.args)
(any(a->(Meta.isexpr(a, :kw) || Meta.isexpr(a, :parameters)), ex0.args) ||
ex0.head == :call)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this kills the branch in 296 completely. The main requirement for fixing #17469 is that the expression goes through the expand step in line 290. However, it's hard to predict the consequences of changes to this function.

mfasi pushed a commit to mfasi/julia that referenced this pull request Sep 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

@code_* can't handle anonymous function arguments
4 participants