# Julia, detecting errors at compile time

**URL:** https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762
**Category:** General Usage
**Created:** [February 17, 2023, 1:36am UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762 "2023-02-17T01:36:41Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![zeroexcuses](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/zeroexcuses/32/46846_2.png) [@zeroexcuses](https://discourse.julialang.org/u/zeroexcuses)
#### Post date: [February 17, 2023, 1:36am UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/1 "2023-02-17T01:36:41Z")

</div>

Setting aside Julia’s JIT runtime (even Java has a JIT, but javac, which does \*.java → jvm bytecode catches lots of errors):

What is the most advanced tool for catching “no method/impl found for dispatch” errors “ahead of time” ?

I.e. I want to feed it a bunch of \*.jl files, and catch as many as possible 'no method/impl found for dispatch" errors as possible without actually running the code.

Thanks!

---

<div class="post-metadata">

### Author: ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)
#### Post date: [February 17, 2023, 12:00pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/2 "2023-02-17T12:00:59Z")

</div>

Try JET.jl

---

<div class="post-metadata">

### Author: ![jling](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jling/32/212909_2.png) [@jling](https://discourse.julialang.org/u/jling)
#### Post date: [February 17, 2023, 1:11pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/3 "2023-02-17T13:11:24Z")

</div>

duplicate of this thread? [Compile time: we can't find any impls for this multi dispatch fn? - #21 by jling](https://discourse.julialang.org/t/compile-time-we-cant-find-any-impls-for-this-multi-dispatch-fn/94736/21)

---

<div class="post-metadata">

### Author: ![zeroexcuses](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/zeroexcuses/32/46846_2.png) [@zeroexcuses](https://discourse.julialang.org/u/zeroexcuses)
#### Post date: [February 17, 2023, 10:58pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/4 "2023-02-17T22:58:26Z")

</div>

I’d prefer to keep these two separate. The other thread goes all over the place, and I’d like this one to just focus purely on detecting more errors at compile time.

---

<div class="post-metadata">

### Author: ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)
#### Post date: [February 19, 2023, 12:46pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/5 "2023-02-19T12:46:42Z")

</div>

I don’t think there’s a lot more to say. You’ve gotten the suggestion to use JET a couple of times, but you’ve never engaged with it, which makes it seem like you’re ignoring the advice you’ve been asking for.

What you’re asking for may not be possible in quite the way that you envision it: in code like `add_first_last(list) = first(list) + last(list)` there are an infinite number of types that could be supplied for `list`, and whether all the requisite methods are defined is type-dependent. So I have trouble envisioning anything that behaves radically differently from JET. So the answer is: just use JET.

---

<div class="post-metadata">

### Author: ![zeroexcuses](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/zeroexcuses/32/46846_2.png) [@zeroexcuses](https://discourse.julialang.org/u/zeroexcuses)
#### Post date: [February 19, 2023, 8:12pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/6 "2023-02-19T20:12:33Z")

</div>

> [@tim.holy](#):
>
> You’ve gotten the suggestion to use JET a couple of times, but you’ve never engaged with it, which makes it seem like you’re ignoring the advice you’ve been asking for.

This is false and unnecessarily antagonizing.

---

<div class="post-metadata">

### Author: ![tim.holy](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tim.holy/32/52_2.png) [@tim.holy](https://discourse.julialang.org/u/tim.holy)
#### Post date: [February 19, 2023, 11:52pm UTC](https://discourse.julialang.org/t/julia-detecting-errors-at-compile-time/94762/7 "2023-02-19T23:52:40Z")

</div>

I’m glad to hear it’s false. Let us know how your experiments with JET work out!
