2012 International Residential Code
Detached one- and two-family dwellings and townhomes of not more than three stories, apartment buildings, dormitories, adult/child care facilities and assisted living facilities which contain a fuel-burning appliance or an attached garage are required to have CO alarms outside of each separate sleeping area in the immediate vicinity of bedrooms.