List of stop words for Ruby
I am writing a search engine using the Lucene Java framework.
What I want to do is to create an index of Ruby source code files. For that I would like to have the option of using a stop word filter, i.e. I want the stop words of the ruby language be ignored when indexing the files.
--> Does anyone know of a nice comp开发者_如何学JAVAlete list of Ruby stop words? (e.g. def, end, module, ...)
Surprisingly enough, Google did not provide me with an answer... So any help would be appreciated!
alias and BEGIN begin break case class def defined? do else elsif END end ensure false for if in module next nil not or redo rescue retry return self super then true undef unless until when while yield
From Ruby QuickRef.
For what it's worth, these are generally called "reserved words" - and I found this list by Googling for Ruby reserved words.
精彩评论