rescript-lang / reanalyze

Experimental analyses for ReScript and OCaml: globally dead values/types, exception analysis, and termination analysis.
MIT License
276 stars 20 forks source link

Add a watch mode? #27

Closed johnhaley81 closed 4 years ago

johnhaley81 commented 4 years ago

Thanks for this awesome tool!

While going through a repo and resolving things that are brough up, it would be nice to get a stream of remaining dead code left.

cristianoc commented 4 years ago

@johnhaley81 is that for bucklescript/JS or dune/native?

cristianoc commented 4 years ago

It will probably be possible to integrate with bsb in future. Though it will take some time. No plan to have a dedicated watch mode which is not integrated with the build system.

johnhaley81 commented 4 years ago

I'm currently using it with Bucklescript

cristianoc commented 4 years ago

@johnhaley81 if you run the bs watcher, all you need is to call reanalyze from time to time.

Later on, special support will be added to bsb, but it takes a little time to get there.

How does that sound?

johnhaley81 commented 4 years ago

That's what I'm doing right now and it is definitely manageable. The special support sounds great whenever that's able to be built. Certainly no rush 😊

cristianoc commented 4 years ago

Great!