The history of railroads is inexorably mixed with politics and nation building. Especially but not exclusively in the colonial context. In the past but also today. Ambitions for a trans-Asian railway are to be understood in the light of China wishing to grow its sphere of influence and build a bridge to Europe.
The point is - Wakhan Corridor never had anything to do with any railroad building in its original conception. I understood your original comment to be in the context of the possible relevance of the Wakhan Corridor to the current Iran - Afghanistan Railway.
Actually the reason that the current line proposed goes through Tadjikistan to China is because any line through the Wakhan Corridor would be spectacularly expensive to build and at best will be a vanity project for Afghanistan if they can find money in their vast (not!) coffers, or by hocking themselves thoroughly to China by becoming Satrap, something that Afghans have repeatedly proved to be not too good at. Again straying far off the subject of the thread.
Afghanistan also has a century of history of drawing random Railway Plans on the map and let it stand until some draws the next one, of course with nothing ever built. The Iran - Afghanistan - Tadjikistan line is a departure from that, and interestingly it follows none of Afghanistan's fantasy maps.
Incidentally, there was another railroad that was built in Afghanistan and still exists. It is a Russian Broad Gauge Line built from the Friendship Bridge to the outskirts of Mazar-e-Sharif in the North. It was built during the Soviet occupation of Afghanistan. There was also an active proposal for a while to build another Russian BG line from the North to Herat. I have not kept track of whatever happened to that.
The Iran - Afghanistan line is of course, Standard Gauge.
There is a long standing plan to build an Indian BG Line from Quetta in Pakistan through the Spin Boldak border crossing to Kandahar too.