There are two variables named identifier, the inner one shadowing the outer one. So, we generate the identifier twice, and a wrong result is returned from the function.
Created attachment 188718 [details] proposed fix
Committed <http://trac.webkit.org/r143123>.