lib/rouge/lexers/r.rb in rouge-2.2.1 vs lib/rouge/lexers/r.rb in rouge-3.0.0
- old
+ new
@@ -41,11 +41,11 @@
seq_along seq_len seq.int sign signif sin sinh sinpi sqrt
standardGeneric substitute sum switch tan tanh tanpi tracemem
trigamma trunc unclass untracemem UseMethod xtfrm
)
- def self.analyze_text(text)
- return 1 if text.shebang? 'Rscript'
+ def self.detect?(text)
+ return true if text.shebang? 'Rscript'
end
state :root do
rule /#'.*?$/, Comment::Doc
rule /#.*?$/, Comment::Single