This kind of reminds me of when "old-earth" "creationists" tell me the 6 days of Creation couldn't be 24-hour periods "because" the sun wasn't created until Day 4; I always point out to them that if you cannot have 24-hour periods prior to the creation of the sun, then, all the more, you cannot have 1,000,000-year or 1,000,000,000-year periods prior to the creation of the sun.
Absolutely. If the standard for time doesn't exist, how can you measure by that standard. But we do have days from day one (pun intended). And there weren't millions of years on the earth before the sun, only a few days.
But days were measured against earth rotations (presumably) compared to a light source from day one.
"24 hours" is a more recent term than Genesis 1, but it is relative to the day length. Saying that the days were 24 hours long is meaningless, therefore. It is expressly saying that a day is 24 1/24ths.
So, by what other standard can one measure time in Gen 1? There is none other prior to plants being created, I don't think. Plants might be used to say that the days were close to what they are today, because night appears to be necessary fairly often or the sun would roast the olants, and day is necessary fairly often to keep them from freezing. Maybe a similar argument could be made for how quickly the earth's water would evaporate or freeze. But there are numerous ways to counter such an argument (with water, maybe with plants), such as an internal, underground source of heat before the sun appeared.