-
Notifications
You must be signed in to change notification settings - Fork 643
Fix UInt unary negation ScalaDoc #4829
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Deprecate invalid unary operator unary_-%.
chiselbot
pushed a commit
that referenced
this pull request
Mar 25, 2025
Deprecate invalid unary operator unary_-%. (cherry picked from commit 477900b) # Conflicts: # core/src/main/scala-2/chisel3/BitsIntf.scala # core/src/main/scala-3/chisel3/BitsIntf.scala
14 tasks
Contributor
✅ Backports have been createdDetails
|
kammoh
pushed a commit
to kammoh/chisel
that referenced
this pull request
Mar 26, 2025
Deprecate invalid unary operator unary_-%.
tymcauley
added a commit
to tymcauley/fixedpoint
that referenced
this pull request
Apr 2, 2025
`UnknownWidth` became a `case object` in this Chisel PR: chipsalliance/chisel#4242 The `connectFromBits` method was removed in this Chisel PR: chipsalliance/chisel#4168 The `connectFromBits` API was replaced with the `_fromUInt` API in this Chisel PR: chipsalliance/chisel#4782 The `NumObject` trait was replaced by the `Num` object in this PR: chipsalliance/chisel#4768 Wrapping unary negation (`unary_-%`) was deprecated in this PR: chipsalliance/chisel#4829 The sbt update is necessary to maintain compatibility with the latest Scala compiler version.
tymcauley
added a commit
to tymcauley/fixedpoint
that referenced
this pull request
Apr 2, 2025
`UnknownWidth` became a `case object` in this Chisel PR: chipsalliance/chisel#4242 The `connectFromBits` method was removed in this Chisel PR: chipsalliance/chisel#4168 The `connectFromBits` API was replaced with the `_fromUInt` API in this Chisel PR: chipsalliance/chisel#4782 Wrapping unary negation (`unary_-%`) was deprecated in this PR: chipsalliance/chisel#4829 The sbt update is necessary to maintain compatibility with the latest Scala compiler version.
milovanovic
pushed a commit
to ucb-bar/fixedpoint
that referenced
this pull request
Dec 15, 2025
* Update Chisel from 6.5.0 to 7.0.0 `UnknownWidth` became a `case object` in this Chisel PR: chipsalliance/chisel#4242 The `connectFromBits` method was removed in this Chisel PR: chipsalliance/chisel#4168 The `connectFromBits` API was replaced with the `_fromUInt` API in this Chisel PR: chipsalliance/chisel#4782 Wrapping unary negation (`unary_-%`) was deprecated in this PR: chipsalliance/chisel#4829 The sbt update is necessary to maintain compatibility with the latest Scala compiler version. * Migrate from Chisel testers to ChiselSim The `chisel3.testers` package was removed here: chipsalliance/chisel#4746 It doesn't look like ChiselSim has the same `Boolean` result from `simulate`, so we must check for simulation errors by catching exceptions. * Replace ChiselRunners trait with direct use of ChiselSim * Update to latest scalafmt * lint: Apply latest scalafmt settings * Update to latest scalatest version * Fix missing sbt command in GitHub CI For background: actions/setup-java#712 Also updated JDK to 21 (latest LTS), updated some GitHub actions to their latest versions, and using install-circt GitHub action to get firtool. * Fix out-of-range literals in tests An 8-bit signed integer with a binary point at 2 effectively has a 6-bit signed number for the value to the left of the decimal point. That means it can represent values in the range [-2^5, 2^5-1], or [-32, 31]. After chipsalliance/chisel#4786 was merged, the `55` and `56` literals are now correctly flagged as being out-of-range for this type. I've subtracted 32 from these out-of-range values (changing the MSB from 1 to 0), and the tests now pass. * Update Chisel 7 snapshot from 639-5df5515f to 678-dca5fc11 This update includes this Chisel PR, which deprecated everything in the `firrtl` package: chipsalliance/chisel#4878 Bump `firtool` version to latest as well. * Update Chisel version to 7.0.0-RC1 Also update CI versions of firtool and verilator to latest. * Update Chisel version to 7.5.0
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Backported
This PR has been backported
Deprecation
Deprecates an API, will be included in release notes
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixing a ScalaDoc inconsistency noted on Element.
Note that unary operators are only allowed to be single characters,
-,!,~and+, sounary_-%has always been invalid to call as a unary operator, you have to call it asmyUInt.unary_-%which is just pointless and silly.Contributor Checklist
docs/src?Type of Improvement
Desired Merge Strategy
Release Notes
Deprecate invalid unary operator unary_-%.
Reviewer Checklist (only modified by reviewer)
3.6.x,5.x, or6.xdepending on impact, API modification or big change:7.0)?Enable auto-merge (squash)and clean up the commit message.Create a merge commit.