# Build\_function returning an Expr, which is not callable. How do I make it callable?

**URL:** <https://discourse.julialang.org/t/build-function-returning-an-expr-which-is-not-callable-how-do-i-make-it-callable/102333>\
**Category:** New to Julia\
**Tags:** modelingtoolkit\
**Created:** [July 31, 2023, 7:35pm UTC](https://discourse.julialang.org/t/build-function-returning-an-expr-which-is-not-callable-how-do-i-make-it-callable/102333 "2023-07-31T19:35:45Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)\
**Post date:** [August 1, 2023, 3:31am UTC](https://discourse.julialang.org/t/build-function-returning-an-expr-which-is-not-callable-how-do-i-make-it-callable/102333/6 "2023-08-01T03:31:50Z")

</div>

> [@algunion](#):
>
> ```julia
> f = eval(f_expr)
> typeof(f) # should be Function
> f(d)
> 
> ```

No, please use the recommended keyword arguments in `build_function`. There’s `expression = Val{true}`, change it to `expression = Val{false}` and you’ll get a RuntimeGeneratedFunction that won’t have world-age issues. I.e.:

```julia
f_expr = build_function(loss, lossvars, expression = Val{false})

```

---

_[View the full topic](https://discourse.julialang.org/t/build-function-returning-an-expr-which-is-not-callable-how-do-i-make-it-callable/102333)._
