BUG: to_datetime with decimal number doesn't fail for %Y%m%d
- [x] closes #50051 (Replace xxxx with the GitHub issue number)
- [x] closes #17410
- [x] [Tests added and passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#writing-tests) if fixing a bug or adding a new feature
- [x] All [code checks passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#pre-commit).
- [x] Added [type annotations](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#type-hints) to new arguments/methods/functions.
- [x] Added an entry in the latest `doc/source/whatsnew/vX.X.X.rst` file if fixing a bug or adding a new feature.

Previously, %Y%m%d was excluded from the ISO8601 fast path, and went down its own special path.

This:
- introduced complexity
- introduced bugs (like the one linked)

%Y%m%d is listed as an example of ISO8601 date on Wiki https://en.wikipedia.org/wiki/ISO_8601#Calendar_dates:

> the standard allows both the "YYYY-MM-DD" and YYYYMMDD formats for complete calendar date representations

So, I'd suggest just getting rid of the special %Y%m%d path, and just going down the ISO8601 path

---

Performance degrades, and is now on-par with other non-ISO8601 formats. I think this is fine - if the code is buggy, it doesn't matter how fast it is.

On upstream/main:
```python
In [1]: dates = pd.date_range('1700', '2200').strftime('%Y%m%d')

In [2]: %%timeit
   ...: to_datetime(dates, format='%Y%m%d')
   ...: 
   ...: 
68.6 ms ± 2.18 ms per loop (mean ± std. dev. of 7 runs, 10 loops each)
```

On this branch:
```python
In [1]: dates = pd.date_range('1700', '2200').strftime('%Y%m%d')

In [2]: %%timeit
   ...: to_datetime(dates, format='%Y%m%d')
   ...: 
   ...: 
212 ms ± 6.57 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)
```

Note that this is comparable performance with other non-ISO8601 formats:
```python
In [4]: %%timeit
   ...: to_datetime(dates, format='%Y foo %m bar %d')
   ...: 
   ...: 
235 ms ± 7.99 ms per loop (mean ± std. dev. of 7 runs, 1 loop each)
```

The fastest thing in this example would actually be to not specify a `format`, but then that would fail on 6-digit `%Y%m%d` dates (see https://github.com/pandas-dev/pandas/issues/17410#issuecomment-1337636330)
closing, probably superseded by #50242