I was just casually playing Pokemon Black and then this happened. I guess they didn't find this when bug testing. That's the only stairs of the last gym (and by extension of the entire game) you can do this on as well if my memory's corret. Also you can do this on both sides of the stairs. Fortunately it doesn't softlock you.