WASHINGTON (AP) -- Moody's Investors Service said late Friday that the United States should be able to keep its triple-A credit rating as long as Washington works out a deal that lets it continue to pay bondholders.The credit rating agency said it thinks that even if the nation's $14.3 trillion borrowing limit isn't raised by Tuesday's deadline, the government would give priority to making interest payments on its debt and thereby avoid a default.Moody's had warned July 13 that the country's credit rating was in danger of being downgraded because of the stalemate in Congress over raising the debt limit.In its statement Friday, however, Moody's said that based on its current review it would likely rate the U.S. debt as triple-A but with a negative outlook. That would mean that there is a possibility of a downgrade in the future."If there were a default on a Treasury debt obligation, a downgrade would likely follow, even if the default were swiftly cured and investors suffered no permanent losses," Moody's said in its new report.Credit rating agencies assess the riskiness of debt issued by companies and governments. The three major agencies -- Moody's, Standard & Poor's and Fitch Ratings -- have all raised warnings in recent months that they might downgrade the U.S. government's triple-A rating.Such a downgrade would send shockwaves through the financial system. The government has had the highest credit rating for nearly a century. That rating has allowed the United States to pay the lowest interest rates possible to finance Treasury debt.Sherry Cooper, chief economist at BMO Financial Group, said the decision by Moody's to back away from its threatened downgrade was "great news" and would probably make a potential downgrade by S&P less of a threat as well."What is really important is that the likelihood of a Treasury default has fallen sharply as the prospects of a debt-ceiling hike in the next few days has increased," Cooper said. "The U.S. is now more likely to retain its Moody's triple-A rating as long as it does not default."In its new report, Moody's said that it would consider the government in default only if it missed an interest or principal payment on its debt, not if the government had to delay payments in such areas as federal employee salaries, Social Security or bills from vendors."If the debt limit is not raised before Aug. 2, we believe that the Treasury would give priority to debt service payments and could thus postpone a potential default for a number of days," Moody's said. "Revenues would be more than adequate for some period of time to meet those payments, although other outlays would be severely reduced as a result."Some private economists have estimated that the government could keep operating without defaulting on its debt payments perhaps as long as Aug. 15.The announcement by Moody's on Friday followed favorable comments Wednesday by Deven Sharma, the president of Standard & Poor's. He told a congressional committee that some of the deficit-cutting plans Congress is considering would lower the U.S. debt burden enough to allow the country to retain its triple-A rating.However, Sharma said that S&P would not make a final determination until it had a much clearer view of what package of deficit-cutting proposals Congress would be adopting as part of a deal to raise the debt limit.However, he said that previous reports indicating that Congress would need to make $4 trillion in deficit cuts over 10 years to retain a triple-A rating were not accurate. He declined during his testimony to be specific about the threshold, although he said the plan would have to make a credible attack on the U.S. deficit problems.