I was investigating curses.rb
of the curses
gem, I found this everywhere:
def attrset(attrs)
#This is a stub, used for indexing
end
# bkgdset(ch)
#
# Manipulate the background of the current window
# with character Integer +ch+
#
# see also Curses.bkgdset
def bkgdset(ch)
#This is a stub, used for indexing
end
# bkgd(ch)
#
# Set the background of the current window
# and apply character Integer +ch+ to every character.
#
# see also Curses.bkgd
def bkgd(ch)
#This is a stub, used for indexing
end
# Returns an Interer (+ch+) for the character property in the current window.
def getbkgd()
#This is a stub, used for indexing
end
I don't understand the stub part. Where's the code that actually does all the work?
Are you, by any chance, viewing this with RubyMine's "Go to definition" (or what's it called there)?
If so, then the likely reason is that those methods are implemented in C, and IDE can't show you the ruby code, because there's none. But it knows method signatures and it generates those fake bodies to aid its intellisense (method name completion and stuff).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With