-
Notifications
You must be signed in to change notification settings - Fork 603
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
Improve source locators for switch statements. #1669
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome!
This will definitely help traceability when using switch
. Nice first patch!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
@jackkoenig: Can this be backported and how far? This is adding a second parameter group which I think will break backwards compatibility? |
* Build ArrayBuffers in Block.mapStmt * Have empty Block serialize as "skip" The FIRRTL parser requires at least one indented line in each module. Sometimes tests emit and parse modules with no contents; this ensures there's always at least a "skip" in empty modules. Also fix tests that expected certain skips * Use var List as stack in Block.mapStmt impl This replaces Iterator concatenation. In Scala 2.11, RHS recursion on Iterators is not stack safe. This seems to have been fixed in 2.12 by Scala PR 5033. Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This fixes #1648.
Contributor Checklist
Did you add Scaladoc to every public function/method?Did you add appropriate documentation indocs/src
?Did you add text to be included in the Release Notes for this change?Type of Improvement
API Impact
No impact.
Backend Code Generation Impact
The source locators in the code generated from the
switch
statements will no longer referenceConditional.scala
. They will now reference the source line of theis
statement.Desired Merge Strategy
Release Notes
N/A
Reviewer Checklist (only modified by reviewer)
Please Merge
?