Skip to content
This repository has been archived by the owner on Aug 20, 2024. It is now read-only.

0-bit literals #2544

Merged
merged 3 commits into from
Dec 15, 2022
Merged

0-bit literals #2544

merged 3 commits into from
Dec 15, 2022

Conversation

ekiwi
Copy link
Contributor

@ekiwi ekiwi commented Aug 23, 2022

This implements the 0-bit literals specified in chipsalliance/firrtl-spec#40

Contributor Checklist

  • Did you add Scaladoc to every public function/method?
  • Did you update the FIRRTL spec to include every new feature/behavior?
  • Did you add at least one test demonstrating the PR?
  • Did you delete any extraneous printlns/debugging code?
  • Did you specify the type of improvement?
  • Did you state the API impact?
  • Did you specify the code generation impact?
  • Did you request a desired merge strategy?
  • Did you add text to be included in the Release Notes for this change?

Type of Improvement

  • new feature

API Impact

  • allows certain firrtl constructs that were previously rejected

Backend Code Generation Impact

  • none

Desired Merge Strategy

  • squash

Release Notes

0-bit literals UInt<0>(0) and SInt<0>(0) are now allowed for convenience reasons.
0-bit wires and ports do not need to be connected to since they do not carry any information.

Reviewer Checklist (only modified by reviewer)

  • Did you add the appropriate labels?
  • Did you mark the proper milestone (1.2.x, 1.3.0, 1.4.0) ?
  • Did you review?
  • Did you check whether all relevant Contributor checkboxes have been checked?
  • Did you mark as Please Merge?

@ekiwi ekiwi modified the milestones: 1.6.0, 1.5.x Aug 23, 2022
@ekiwi ekiwi changed the title 0-bit literals and exemption from connection check 0-bit literals Aug 29, 2022
@ekiwi ekiwi requested a review from jackkoenig August 29, 2022 20:01
@jackkoenig jackkoenig merged commit 135739f into chipsalliance:master Dec 15, 2022
mergify bot pushed a commit that referenced this pull request Dec 15, 2022
* allow for zero-width integer literals
* CheckWidths: ensure that width is non-negative

(cherry picked from commit 135739f)
@mergify mergify bot added the Backported This PR has been backported to marked stable branch label Dec 15, 2022
mergify bot added a commit that referenced this pull request Dec 15, 2022
* allow for zero-width integer literals
* CheckWidths: ensure that width is non-negative

(cherry picked from commit 135739f)

Co-authored-by: Kevin Laeufer <laeufer@cs.berkeley.edu>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Backported This PR has been backported to marked stable branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants