-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
drake_proto: Simplify ubsan fix implementation. #7782
drake_proto: Simplify ubsan fix implementation. #7782
Conversation
72a859c
to
22cf925
Compare
+@clalancette for feature review, please. Review status: 0 of 3 files reviewed at latest revision, all discussions resolved. Comments from Reviewable |
Yeah, my original prototype for this used |
Reviewed 3 of 3 files at r1. tools/skylark/drake_proto_ubsan_fix.py, line 31 at r1 (raw file):
This will misbehave silently if Comments from Reviewable |
I like the approach overall. Some comments inline. Review status: all files reviewed at latest revision, 3 unresolved discussions, some commit checks failed. tools/skylark/drake_proto_ubsan_fix.py, line 13 at r1 (raw file):
Thinking about this more, I don't think we actually need this, do we? The generated code coming out of the Comments from Reviewable |
22cf925
to
d1ffd84
Compare
Review status: 1 of 3 files reviewed at latest revision, 2 unresolved discussions. tools/skylark/drake_proto_ubsan_fix.py, line 13 at r1 (raw file): Previously, clalancette (Chris Lalancette) wrote…
I tried removing this, but compilation fails with: From what I gather
An alternative solution would be to patch the third party stuff, but I'd prefer to leave this code as-is since our fix is relatively simple for the time being. tools/skylark/drake_proto_ubsan_fix.py, line 31 at r1 (raw file): Previously, ggould-tri wrote…
Done. Comments from Reviewable |
Review status: 1 of 3 files reviewed at latest revision, 2 unresolved discussions. tools/skylark/drake_proto_ubsan_fix.py, line 13 at r1 (raw file): Previously, EricCousineau-TRI (Eric Cousineau) wrote…
OK, that makes sense to me. I agree that this is simpler than patching the third-party stuff, so this is fine with me. Comments from Reviewable |
Review status: 1 of 3 files reviewed at latest revision, 1 unresolved discussion. Comments from Reviewable |
Reviewed 2 of 2 files at r2. Comments from Reviewable |
Ran into this when prototyping on #7616.
This simplifies the
ubsan
fixups by ensuring that local includes are prefixed withdrake
, such that we can usedrake_cc_library
rather than duplicate the code.I'm not terribly familiar with
awk
, and tried usingsed
with multiple scripts, but Mac'ssed -E
has awkward line escaping shenanigans.This change is