Skip to content

[BUG] js_of_ocaml hangs on mutually recursive functions #1042

@robz

Description

@robz

Describe the bug
js_of_ocaml seems to hang when compiling this:

let rec f1 = () => f1()
and f2 = () => f1();

Expected behavior
I would expect it to compile successfully since it successfully compiles these cases:

let rec f1 = () => f2()
and f2 = () => f1();

let rec g = () => g();

Versions
Run "esy" in this repo: https://github.com/robz/js_of_ocaml-recursion-bug-repro
See the esy.lock file for package versions

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions