In reply to dave_59:
speed_port0 is just temporary variable , it is declared as logic [2:0] speed_port0;