From 0a1f207ab5447bb94aaa4bdfeb2d5c39a320879b Mon Sep 17 00:00:00 2001 From: Clifford Wolf Date: Tue, 31 Jan 2017 09:12:31 +0100 Subject: [PATCH] Fix bug in /examples/quickstart/prove.v --- docs/examples/quickstart/prove.v | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/examples/quickstart/prove.v b/docs/examples/quickstart/prove.v index d9a55da..4535368 100644 --- a/docs/examples/quickstart/prove.v +++ b/docs/examples/quickstart/prove.v @@ -22,7 +22,7 @@ module demo ( output reg [7:0] dout ); reg [7:0] buffer; - reg [2:0] state; + reg [1:0] state; always @(posedge clk) begin if (reset) begin @@ -30,17 +30,17 @@ module demo ( state <= 0; end else case (state) - 3'b 001: begin + 0: begin buffer <= din; state <= 1; end - 3'b 010: begin + 1: begin if (buffer[1:0]) buffer <= buffer + 1; else state <= 2; end - 3'b 100: begin + 2: begin dout <= dout + buffer; state <= 0; end -- 2.30.2