"Congress has always restricted federal debt. The Second Liberty Bond Act of 1917 included an aggregate limit on federal debt as well as limits on specific debt issues. Through the 1920s and 1930s, Congress altered the form of those restrictions to give the U.S. Treasury more flexibility in debt management and to allow modernization of federal financing. In 1939, a general limit was placed on federal debt. Federal debt accumulates when the government sells debt to the public to finance budget deficits and to meet federal obligations or when it issues debt to government accounts, such as the Social Security, Medicare, and Transportation trust funds. Total federal debt is the sum of debt held by the public and debt held by government accounts. Surpluses reduce debt held by the public, while deficits raise it."
CRS Report for Congress, RL31967
Federation of American Scientists: http://www.fas.org/sgp/crs/index.html