def upcast_char(*args):
 t = _upcast_memo.get(args)
 if (t is not None):
  return t
 t = upcast(*map(np.dtype, args))
 _upcast_memo[args] = t
 return t

def upcast_char ( * args ) : t = _upcast_memo . get ( args ) if ( t is not None ) : return t t = upcast ( * map ( np . dtype , args ) ) _upcast_memo [ args ] = t return t
same as upcast but taking dtype .