Skip to content

Commit 5885b12

Browse files
committed
[FIX] Fix issue with simplified constructors
1 parent 219780a commit 5885b12

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/SDPoptimize.jl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,6 @@ function sdp_optimize(model::SPModel,
141141
param::SDPparameters,
142142
display=true::Bool)
143143

144-
function true_fun(t,x,u,w)
145-
return true
146-
end
147144
function zero_fun(x)
148145
return 0
149146
end

src/objects.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ type StochDynProgModel <: SPModel
103103
noises::Vector{NoiseLaw}
104104

105105
function StochDynProgModel(model::LinearDynamicLinearCostSPmodel, final, cons)
106-
return new(model.stageNumber, model.xlim, model.ulim, model.initialState,
106+
return StochDynProgModel(model.stageNumber, model.xlim, model.ulim, model.initialState,
107107
model.costFunctions, final, model.dynamics, cons,
108108
model.noises)
109109
end
@@ -121,7 +121,7 @@ type StochDynProgModel <: SPModel
121121
return saved_cost
122122
end
123123

124-
return new(model.stageNumber, model.xlim, model.ulim, model.initialState,
124+
return StochDynProgModel(model.stageNumber, model.xlim, model.ulim, model.initialState,
125125
cost, final, model.dynamics, cons, model.noises)
126126
end
127127

0 commit comments

Comments
 (0)