1. Some cases RobotC is a little bit
more restrictive, compared to standard C. For such cases I suggest using a more simple structure e.g. introducing a new temporary variable.
2. switch statement allows you branching between discrete values. resoution of motor encoder is too fine for such purpose -- the encoder value steps 360 during one rotation of the motor axle and can be anywhere in the range of -32768 .. +32767. You might want to try an "if-else" ladder:
In such a structure you can slow down the motor when you are close to the target and thus avoid "overshoot." If it is the intended operation of course.