Put singleinflght impl. in its own file