Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
DomainIR fix and remove checksquare
Browse files Browse the repository at this point in the history
  • Loading branch information
Ehsan Totoni committed Jan 6, 2017
1 parent 94d1966 commit ddb20a6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/domain-ir.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1637,6 +1637,11 @@ function translate_call_symbol(state, env, typ, head, oldfun::ANY, oldargs, fun:
dprintln(env, "UpperTriangular replaced with ", new_type)
return args[1]
end
# fix checksquare (lasso example)
if args[1]==GlobalRef(Base,:LinAlg) && args[2]==QuoteNode(:checksquare)
dprintln(env, "fixing checksquare")
return GlobalRef(Base,:checksquare)
end
# Shortcut range object access
range_out::Union{RHSVar,Expr,Int} = translate_call_rangeshortcut(state, args[1],args[2])
if range_out!=Expr(:null)
Expand Down Expand Up @@ -2586,6 +2591,9 @@ function translate_call_globalref(state, env, typ, head, oldfun::ANY, oldargs, f
new_args = normalize_args(state, env, args)
dprintln(env, "ctranspose replaced with transpose ")
expr = mk_expr(typ, head, new_fun, new_args...)
elseif fun.name==:checksquare
# remove checksquare (lasso example)
return Expr(:meta)
end
elseif is(fun.mod, Base.Broadcast)
if is(fun.name, :broadcast_shape)
Expand Down

0 comments on commit ddb20a6

Please sign in to comment.