code: def consume_until(self, c):
      if callable(c):
          i = 0
          while i < len(self.s) and not c(self.s[i]):
              i = i + 1
          return self.advance(i)
      else:
          i = self.s.index(c)
          res = self.advance(i)
          self.advance(len(c))
          return res
  
imports: from __future__ import division, absolute_import, print_function
  import re
  import sys
  import platform
  from numpy.compat import unicode
  from numpy.core.overrides import set_module
  from .multiarray import dtype, array, ndarray
label_desc: Use image node_id 4 for calling the _Stream obj's underlying member method code with example usage: obj.consume_until(c) and returns: self, res