Also consider a Japanese firm that wants to expand in the US and needs to finance this with a bank loan. This firm is not well known in the US and is therefore forced to pay higher interest rates. If the two firms can come together, they could possibly achieve a lower interest rate for their respective loans. The two companies would then swap the currencies and service each other's loans. Each company will now have the same loan that they would have otherwise achieved own their own, but with lower interest rates.
Companies can also hedge financial assets or liabilities denominated in foreign currency.
For instance, if a US company were to take a loan denominated in Yen, they would be exposed to the risk of having the Yen appreciate such that it will cost more US Dollars to repay the principal of the loan in the future. They can guard against this by buying financial assets for the same amount denominated in Yen. Thus, if the Yen were to appreciate, both financial assets and liabilities will appreciate by the same amount and therefore each will offset the other. The same can be done for companies that have financial assets denominated in a foreign currency. In this case, the company would want to take out a loan denominated in the same foreign currency for the same amount as the financial asset.