What is `q` here? We definitely need a better name.