Skip to content

Commit

Permalink
Fix deprecations due to JuliaLang/julia#23812
Browse files Browse the repository at this point in the history
  • Loading branch information
martinholters committed Sep 29, 2017
1 parent 17818b4 commit c68bcbe
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ACME.jl
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ function connect!(c::Circuit, pins::Union{Pin,Symbol}...)
nets = unique([netfor!(c, pin) for pin in pins])
for net in nets[2:end]
append!(nets[1], net)
deleteat!(c.nets, findfirst(c.nets, net))
deleteat!(c.nets, findfirst(n -> n == net, c.nets))
for (name, named_net) in c.net_names
if named_net == net
c.net_names[name] = nets[1]
Expand All @@ -309,7 +309,7 @@ end

row = 1;
for col = 1:size(incidence)[2]
rows = filter(r -> r row, find(incidence[:, col]))
rows = filter(r -> r row, find(!iszero, incidence[:, col]))
@assert length(rows) 2

isempty(rows) && continue
Expand All @@ -323,7 +323,7 @@ end
incidence[rows[2],:] = incidence[rows[2],:] + incidence[row,:]
end
if incidence[row, col] < 0
cols = find(incidence[row, :])
cols = find(!iszero, incidence[row, :])
incidence[row,cols] = -incidence[row,cols]
end
rows = find(incidence[1:row-1, col] .== 1)
Expand Down

0 comments on commit c68bcbe

Please sign in to comment.