code: public static String takeWhile(GString self, @ClosureParams(value=SimpleType.class, options="char") Closure condition) {
          return (String) takeWhile(self.toString(), condition);
      }
docs: A GString variant of the equivalent GString method.
  
  @param self      the original GString
  @param condition the closure that must evaluate to true to continue taking elements
  @return a prefix of elements in the GString where each
  element passed to the given closure evaluates to true
  @since 2.3.7