File tree Expand file tree Collapse file tree 2 files changed +15
-6
lines changed Expand file tree Collapse file tree 2 files changed +15
-6
lines changed Original file line number Diff line number Diff line change 1
1
name = " DynamicPPL"
2
2
uuid = " 366bfd00-2699-11ea-058f-f148b4cae6d8"
3
3
authors = [
" mohamed82008 <[email protected] >" ]
4
- version = " 0.4.1 "
4
+ version = " 0.4.2 "
5
5
6
6
[deps ]
7
7
AbstractMCMC = " 80f14c24-f653-4e6a-9b94-39d6b0f70001"
@@ -11,7 +11,7 @@ MacroTools = "1914dd2f-81c6-5fcd-8719-6d5c9610ff09"
11
11
12
12
[compat ]
13
13
AbstractMCMC = " 0.4, 0.5"
14
- Bijectors = " 0.5.2"
14
+ Bijectors = " 0.5.2, 0.6 "
15
15
Distributions = " 0.22"
16
16
MacroTools = " 0.5.1"
17
17
julia = " 1"
Original file line number Diff line number Diff line change @@ -479,9 +479,8 @@ function build_output(model_info)
479
479
end
480
480
end )
481
481
end
482
- return esc (quote
483
- # Allows passing arguments as kwargs
484
- $ outer_function (;$ (args... )) = $ outer_function ($ (arg_syms... ))
482
+
483
+ ex = quote
485
484
function $outer_function ($ (args... ))
486
485
function $inner_function (
487
486
$ vi:: DynamicPPL.VarInfo ,
@@ -496,7 +495,17 @@ function build_output(model_info)
496
495
return DynamicPPL. Model ($ inner_function, $ args_nt, $ model_gen_constructor)
497
496
end
498
497
$ model_gen = $ model_gen_constructor
499
- end )
498
+ end
499
+
500
+ if ! isempty (args)
501
+ ex = quote
502
+ $ ex
503
+ # Allows passing arguments as kwargs
504
+ $ outer_function (;$ (args... )) = $ outer_function ($ (arg_syms... ))
505
+ end
506
+ end
507
+
508
+ return esc (ex)
500
509
end
501
510
502
511
# A hack for NamedTuple type specialization
You can’t perform that action at this time.
0 commit comments