Esempio n. 1
0
 @Specialization
 public RubyString reverse(RubyString string) {
   string.set(new StringBuilder(string.toString()).reverse().toString());
   return string;
 }
Esempio n. 2
0
 @Specialization
 public RubyString downcase(RubyString string) {
   string.set(string.toString().toLowerCase());
   return string;
 }
Esempio n. 3
0
 @Specialization
 public RubyString initialize(RubyString self, RubyString from) {
   self.set(from);
   return self;
 }
Esempio n. 4
0
 @Specialization
 public RubyString chompBang(RubyString string) {
   string.set(string.toString().trim());
   return string;
 }