# Any plan for static type checker?

**URL:** <https://racket.discourse.group/t/any-plan-for-static-type-checker/3669>\
**Category:** General\
**Tags:** rhombus\
**Created:** [April 1, 2025, 2:02pm UTC](https://racket.discourse.group/t/any-plan-for-static-type-checker/3669 "2025-04-01T14:02:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hazematman](https://avatars.discourse-cdn.com/v4/letter/h/977dab/32.png) [@Hazematman](https://racket.discourse.group/u/Hazematman)\
**Post date:** [April 1, 2025, 2:02pm UTC](https://racket.discourse.group/t/any-plan-for-static-type-checker/3669/1 "2025-04-01T14:02:33Z")

</div>

Hey,

I've been playing around with Rhombus for a little while now and I really like the language. One aspect of it that I find really neat is the static information bindings. I'm curious if there is any plan to allow them to work as a fully static type checker. For example in this code

```rhombus
#lang rhombus/static

fun func(a :: Int):
  a + 1

println("hello")
func("hello")

```

it seems that the annotation is not checked until func is being executed with the wrong annotation. It would be really nice if it could catch this before executing any code.

---

<div class="post-metadata">

**Author:** ![mehbark](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/mehbark/32/2274_2.png) [@mehbark](https://racket.discourse.group/u/mehbark)\
**Post date:** [April 1, 2025, 2:36pm UTC](https://racket.discourse.group/t/any-plan-for-static-type-checker/3669/2 "2025-04-01T14:36:30Z")

</div>

You may be interested in the (less mature) [Shplait](https://docs.racket-lang.org/shplait/index.html). It “syntactically resembles the [Rhombus](https://docs.racket-lang.org/rhombus/index.html) language, but the type system is close to that of [ML](http://smlnj.org/).”

---

<div class="post-metadata">

**Author:** ![Hazematman](https://avatars.discourse-cdn.com/v4/letter/h/977dab/32.png) [@Hazematman](https://racket.discourse.group/u/Hazematman)\
**Post date:** [April 1, 2025, 3:00pm UTC](https://racket.discourse.group/t/any-plan-for-static-type-checker/3669/3 "2025-04-01T15:00:42Z")

</div>

This seems super close to what I want. Unfortunately it seems maps have to be access through `map_get` instead of using `#%index`. Also seems like there is no support for classes/interfaces.

I'll play around with it though and see if its more my jam. The lack of static checking in Rhombus for things it should be able to statically check is bothering me a bit 😛

---

<div class="post-metadata">

**Author:** ![mflatt](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/mflatt/32/6_2.png) [@mflatt](https://racket.discourse.group/u/mflatt)\
**Post date:** [April 1, 2025, 3:21pm UTC](https://racket.discourse.group/t/any-plan-for-static-type-checker/3669/4 "2025-04-01T15:21:12Z")

</div>

I would not say that Shplait is on the direct path to a Typed Rhombus. It's an experiment that could inform a future Typed Rhombus in the way that type constraints are gathered for a finishing unification pass. Otherwise, though, it's a domain-specific language that's intentionally limited.

Typed Rhombus is definitely of interest, but I don't know of a specific plan to get there, as yet.
