Practical TypeProf: Lessons from Analyzing Optcarrot
TypeProf is a static type analyzer designed to analyze Ruby code with minimal type annotations. While TypeProf has steadily evolved, its verification has been largely limited to self-hosting: analyzing its own source code with TypeProf itself.
To prove its utility for the wider ecosystem beyond the tool's own codebase, I conducted an experiment on a "real-world" application. Specifically, I used Optcarrot, an 8-bit machine simulator written in pure Ruby that I developed.
Optcarrot has historically served as a benchmark to drive Ruby interpreter development. Its optimized, complex logic is an ideal, challenging subject for static analysis. I will report on the specific issues encountered during this experiment and the improvements made to TypeProf to resolve them.
Finally, I will share practical lessons learned and workflows derived from this experience. Attendees will gain a realistic understanding of TypeProf’s current capabilities and how to leverage it in their own projects.
-
Yusuke Endoh'A full-time MRI committer at STORES, Inc. He has been interested in testing, analyzing, abusing of Ruby. He is an advocate of "transcendental programming" that creates a useless program like this bio. (
_)'.yield_self{|s|eval(t=%q(puts"'#{s.sub(?_,?_+?_)}'.yield_self{|s|eval(t=%q(#{t}))}"))}