Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support enum type checking lint checks #726

Closed
veripoolbot opened this issue Mar 22, 2014 · 1 comment
Closed

Support enum type checking lint checks #726

veripoolbot opened this issue Mar 22, 2014 · 1 comment
Labels
area: data-types Issue involves data-types area: lint Issue involves SystemVerilog lint checking effort: days Expect this issue to require roughly days of invested effort to resolve resolution: fixed Closed; fixed type: feature-IEEE Request to add new feature, described in IEEE 1800

Comments

@veripoolbot
Copy link
Contributor


Author Name: Jeff Bush (@jbush001)
Original Redmine Issue: 726 from https://www.veripool.org
Original Date: 2014-03-22


Pretty much any signal with the proper width can be assigned to an enum.

	typedef enum logic[1:0] {
		FOO_A,
		FOO_B,
		FOO_C,
		FOO_D
	} foo_t;
	
	foo_t foo;
	
	always_comb
	begin
		foo = 2'd2;
	end

There should be an error if it is assigned without an explicit cast.

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2014-03-25T00:27:28Z


Yes, Verilator is weak to almost non-existent in type checks. Needs work.

@veripoolbot veripoolbot added area: data-types Issue involves data-types area: lint Issue involves SystemVerilog lint checking effort: days Expect this issue to require roughly days of invested effort to resolve type: feature-IEEE Request to add new feature, described in IEEE 1800 labels Dec 22, 2019
@wsnyder wsnyder added the resolution: fixed Closed; fixed label Nov 13, 2022
@wsnyder wsnyder closed this as completed Nov 13, 2022
mglb pushed a commit to antmicro/verilator that referenced this issue Dec 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: data-types Issue involves data-types area: lint Issue involves SystemVerilog lint checking effort: days Expect this issue to require roughly days of invested effort to resolve resolution: fixed Closed; fixed type: feature-IEEE Request to add new feature, described in IEEE 1800
Projects
None yet
Development

No branches or pull requests

2 participants