A taxpayer may carry over any unused net operating losses from Business allocated and apportioned to income effectively connected with the conduct of Business in the United States while he is taxed as a nonresident alien, and may apply such losses against gross income from Business after he reacquires U.S. resident status.
A taxpayer may carry over any unused net operating losses from Business generated while he was taxed as a U.S. resident, if still available, against his gross income after he reacquires U.S. resident status.
The years in which Taxpayer is a nonresident alien will be taken into account in determining whether any such unused net operating losses from Business are still available under section 172(b)(1).
Section 172(b) generally allows for net operating loss carrybacks and carryovers, without regard to the resident status of a taxpayer. According to the legislative history of section 172(b), a nonresident alien’s net operating loss may be carried, in accordance with section 172(b), to other taxable years for which the tax is imposed pursuant to section 871(b).
If any of the NOL was shown on his 2012 as a NR from business sources in the US, and the NOL has not been used up it would still carryforward even after he became a resident alien.
He cannot carry a loss form a foreign country over to the US return.
I sincerely ***** ***** is helpful.
You can look to IRC Section 873 for further information.