The law prohibits an inventor from patenting two separate inventions within one patent application. However, sometimes an application is written with more than one invention. What happens after that original application is filed depends on the structure of the description and the claims in the original application.
If the original application includes claims to the second invention, the Examiner should make a restriction requirement. This will force the inventor to pick one of the two inventions to continue with in the original application and select the other for a second application called a divisional application (if the applicant wants to file a second application at all).
If, on the other hand, the application does not include claims to the second invention but merely describes that invention in the application, then there will be no restriction requirement. A good, solid disclosure of the second invention in the original application will, however, allow the inventor to file a continuing application before the original application issues.
In summary, when an inventor invents two similar, but patentably distinct, inventions, a variety of options are available for proceeding with both inventions. The original application can immediately spawn a divisional application in response to an Examiner’s restriction requirement or it can be the subject of a continuing application later on. The ability to do one or the other depends primarily on the decision the attorney and the inventor make and the manner in which the second invention is described and/or claimed in the original application.