Skip to content

Commit 14a3a7d

Browse files
committed
Fix error Model not defined
1 parent d3ff242 commit 14a3a7d

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/compiler.jl

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -444,10 +444,10 @@ function build_output(model_info)
444444
@gensym(evaluator, generator)
445445
generator_kw_form = isempty(args) ? () : (:($generator(;$(args...)) = $generator($(arg_syms...))),)
446446
model_gen_constructor = :(DynamicPPL.ModelGen{$(Tuple(arg_syms))}($generator, $defaults_nt))
447-
447+
448448
ex = quote
449449
function $evaluator(
450-
$model::Model,
450+
$model::DynamicPPL.Model,
451451
$vi::DynamicPPL.VarInfo,
452452
$sampler::DynamicPPL.AbstractSampler,
453453
$ctx::DynamicPPL.AbstractContext,
@@ -456,11 +456,10 @@ function build_output(model_info)
456456
DynamicPPL.resetlogp!($vi)
457457
$main_body
458458
end
459-
460459

461460
$generator($(args...)) = DynamicPPL.Model($evaluator, $args_nt, $model_gen_constructor)
462461
$(generator_kw_form...)
463-
462+
464463
$model_gen = $model_gen_constructor
465464
end
466465

0 commit comments

Comments
 (0)