code: def days_and_sids_for_frames(frames):
      
      if not frames:
          days = np.array([], dtype='datetime64[ns]')
          sids = np.array([], dtype='int64')
          return days, sids
  
      # Ensure the indices and columns all match.
      check_indexes_all_same(
          [frame.index for frame in frames],
          message='Frames have mistmatched days.',
      )
      check_indexes_all_same(
          [frame.columns for frame in frames],
          message='Frames have mismatched sids.',
      )
  
      return frames[0].index.values, frames[0].columns.values
docs: Returns the date index and sid columns shared by a list of dataframes,
      ensuring they all match.
  
      Parameters
      ----------
      frames : list[pd.DataFrame]
          A list of dataframes indexed by day, with a column per sid.
  
      Returns
      -------
      days : np.array[datetime64[ns]]
          The days in these dataframes.
      sids : np.array[int64]
          The sids in these dataframes.
  
      Raises
      ------
      ValueError
          If the dataframes passed are not all indexed by the same days
          and sids.