Disclaimer
In this question I suspect some of the used words are not precise so there is a possibility for misunderstanding here. If you know how to say more correctly or precisely - EDIT! Sorry in advance.
Preliminaries
Consider a particle in the following 1D potential well $$ U(x) = \begin{cases} 0, & x\in[0,b]\\ V, &\text{otherwise} \end{cases} \tag{*} \label{pot} $$ (1st problem) If $V<\infty$ then there are both discrete and continuum spectra. So Hilbert space corresponding to this problem is non-countably-infinite-dimensional.
(2nd problem) But in the case of an infinite well potential there is only discrete spectrum, so Hilbert space is countably-infinite-dimensional. So these Hilbert spaces are different, not even isomorphic.
Question
On the one hand, if one increases $V$ continuously (e.g. in time) in eq.\eqref{pot} the first problem becomes "closer", in some sence, to the second one. And we should (shouldn't we?) conclude that the second one is a limit for the first one. But, on the other hand, two problems are the same implies their Hilbert spaces are equal (maybe isomorphic). I am wondering
How is it possible that a continuum transformed into a countable set (sorry again) "continuously"?
Update
What about the energy values? Considering the first problem there are both discrete and continuum spectra: $$ E^{(1)} = \{E_i|i\in \mathbb{N}\}\cup\{E_\alpha|\alpha\in\mathbb{R}\} $$ so $\mathrm{card}(E^{(1)})=\aleph_1$. The energy spectrum in the second problem consists only of discrete values so $\mathrm{card}(E^{(2)})=\aleph_0$. So how and where the continuum disappears when $V$ approaches to infinity?