It's not only the calories - it's how you eat it as well. If you're eating pasta, you're also likely to be eating it in a rich sauce - this may be calorific if it has a lot of fat in it, and its sodium content may make you eat more than you should. Also, it depends on the type of carbohydrates. If you're eating whole-grain pasta, this should help with keeping slim as its more filling and has more complex carbohydrates that are less likely to be stored as fat in the body.
Brown rice is generally considered not very tasty, so you're more likely to eat white-rice instead. If you're an average American who enjoys eating Chinese-takeout or the like, it's going to be more fattening as it's likely to have copious amounts of fat and sodium ladled into it to give it a better flavour (it goes especially for dishes such as chicken fried-rice).
I wouldn't know too much about bread, but I would think it's easier to have a filling sandwich that isn't too calorific over a rice or pasta based meal. As I've said before, it does depend on how you're eating it. If, like myself, you enjoy eating a foot-long subway with a large dollop of mayonnaise - the 'bread' would be more fattening.
Side-note: If you're asking this question as to base a personal diet plan - I wouldn't think it should matter too much as long as you balance out your carbohydrate/protein/fat intake properly. It's all about the math of whether you're burning more calories than you're actually taking in for weight control.