Continuous Assignment

LRM §6.1.

A continuous assignment drives a value into a net.

Syntax:

net_data_type [ strength ] [ delay ] [ size ] net_name = expression;     // implicit
assign [ strength ] [ #( delay ) ] net_name = expression;                // explicit

Description:

Continuous assignments model combinational logic. Each time the expression changes on the right-hand side, the right-hand side is re-evaluated, and the result is assigned to the net on the left-hand side.

The implicit continuous assignment combines the net declaration (see Net data type) and continuous assignment into one statement. The explicit assignment require two statements: one to declare the net (see Net data type), and one to continuously assign a value to it.

Continuous assignments are not the same as procedural continuous assignments. Continuous assignments are declared outside of procedural blocks. They automatically become active at time zero, and are evaluated concurrently with procedural blocks, module instances, and primitive instances.

Example:

wire Out;
assign Out = A & B;
assign {COut, Sum} = A + B + CIn;
wire #50 Out = A & B; 

See also:

Net data type, Procedural continuous assignment