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

Duplicate declaration of TYPEDEF error when typedef in a generate for #2205

Closed
hdzhangdoc opened this issue Mar 26, 2020 · 2 comments
Closed

Duplicate declaration of TYPEDEF error when typedef in a generate for #2205

hdzhangdoc opened this issue Mar 26, 2020 · 2 comments

Comments

@hdzhangdoc
Copy link

@hdzhangdoc hdzhangdoc commented Mar 26, 2020

If I moved the typedef statement out of the for loop,the error diappeared,is it a bug?The source code can be compiled pass under VCS.

image

image

314 for (genvar t = 0; t < AxiMaxReads; t++) begin: gen_read_upsizer
315 r_state_t r_state_d;
316 r_state_t r_state_q;
317
318 // Are we idle?
319 assign idle_read_upsizer[t] = (r_state_q == R_IDLE);
320
321 struct packed {
322 ar_chan_t ar ;
323 logic ar_valid ;
324 logic ar_throw_error ;
325 slv_r_chan_t r ;
326 logic r_valid ;
327 burst_len_t burst_len;
328 size_t orig_ar_size ;
329 } r_req_d, r_req_q;

@wsnyder

This comment has been minimized.

Copy link
Member

@wsnyder wsnyder commented Mar 26, 2020

Confirmed.

@wsnyder wsnyder changed the title ” Duplicate declaration of TYPEDEF“ reported error,when typedef in a for statement Duplicate declaration of TYPEDEF error when typedef in a generate for Mar 26, 2020
wsnyder added a commit that referenced this issue Mar 26, 2020
@wsnyder

This comment has been minimized.

Copy link
Member

@wsnyder wsnyder commented Mar 26, 2020

Thanks for your report. Fixed in git towards 4.032.

@wsnyder wsnyder closed this Mar 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.