RE: Warning - Meaningless statement?

#pragma config(Sensor, in5,    sonarSensor,         sensorSONAR, int1)
#pragma config(Sensor, in6,    bumpSensorLeft,      sensorTouch)
#pragma config(Sensor, in7,    bumpSensorRight,     sensorTouch)
#pragma config(Motor,  port2,  leftMotor,            tmotorNormal)
#pragma config(Motor,  port3,  rightMotor,           tmotorNormal)
#pragma config(Motor,  port4,  leftRearMotor,        tmotorNormal)
#pragma config(Motor,  port5,  rightRearMotor,       tmotorNormal)
//*!!Code automatically generated by 'ROBOTC' configuration wizard               !!*//

//functions-----------------------------------------------------------

void moveForward(){
  motor[leftMotor] = 127;
  motor[rightMotor] = 127;
  //wait1Msec(3000);
}

void allStop(){
	motor[leftMotor] = 0;
	motor[rightMotor] = 0;

}

//main program--------------------------------------------------------

task main()
{

	while (SensorValue[sonarSensor] > 3){
		moveForward();

	if (SensorValue[bumpSensorLeft] == 1 || SensorValue[bumpSensorRight] == 1) {
		allStop;
		break;

		}
	}

}

When you called the function “allstop” you forgot to include the parentheses. Just make it “allstop()” and your code should compile properly.

Lol…duh! That’s what I get for not going over the code.

So It WAS me being stupid =)

Thanks!