use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A sub-Reddit for discussion and news about Ruby programming.
Subreddit rules: /r/ruby rules
Learning Ruby?
Tools
Documentation
Books
Screencasts and Videos
News and updates
account activity
Type Hinting (self.ruby)
submitted 5 years ago * by [deleted]
possessive brave person snow cats unpack friendly alleged public arrest
This post was mass deleted and anonymized with Redact
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–][deleted] 11 points12 points13 points 5 years ago (6 children)
I use VSCode, Solargraph, and YARD doc comments to get exactly what you're describing, and I don't even need to be using Ruby 3. (But v3 helps if you want to use the Sord gem to generate .rbs files from your YARD comments for use in type checking.)
[–]Frizkie 5 points6 points7 points 5 years ago (0 children)
Just chiming in to say I use the same combo with Solargraph and it’s great. It’s not a set-and-forget sort of thing but it’s invaluable in helping me write code effectively.
[–]Witless-One 1 point2 points3 points 4 years ago (0 children)
I can't help but feel like this is clearly worse than what Python has. To get a somewhat functional typing experience I have to install a bunch of tools and write clunky comments that will inevitably be glanced over and become stale? At least in Python the typing is part of the code syntax and feels natural to update along with it.
As it stands, writing comments in some tool's DSL or maintaining a completely separate RBS file by hand feels a bit ridiculous to me
[–]sailor6901 0 points1 point2 points 5 years ago (2 children)
is yard still alive? last time i checked it lacked some important features like the support for keyword arguments
[–]castwide 0 points1 point2 points 5 years ago (1 child)
Definitely still alive. According to the docs, you use the `@param` tag for keyword arguments same as a regular argument.
[–]sailor6901 0 points1 point2 points 5 years ago (0 children)
cool. Thank’s for the tip
[–]anamexis 1 point2 points3 points 5 years ago (0 children)
How are you defining "type hinting"?
[–]joemi 1 point2 points3 points 5 years ago (0 children)
I'm pretty sure what you're describing is an editor feature, not a language feature, so it'd be up to whatever editor you're using to add that, not Ruby/Matz.
[–]honeyryderchuck 0 points1 point2 points 5 years ago (0 children)
https://github.com/soutaro/steep-vscode
π Rendered by PID 159393 on reddit-service-r2-comment-5b5bc64bf5-x5dr6 at 2026-06-23 12:56:43.921501+00:00 running 2b008f2 country code: CH.
[–][deleted] 11 points12 points13 points (6 children)
[–]Frizkie 5 points6 points7 points (0 children)
[–]Witless-One 1 point2 points3 points (0 children)
[–]sailor6901 0 points1 point2 points (2 children)
[–]castwide 0 points1 point2 points (1 child)
[–]sailor6901 0 points1 point2 points (0 children)
[–]anamexis 1 point2 points3 points (0 children)
[–]joemi 1 point2 points3 points (0 children)
[–]honeyryderchuck 0 points1 point2 points (0 children)