Page MenuHomePhabricator

Simplify LZMA decoding by using ArrayRef::take_back
ClosedPublic

Authored by kwk on Oct 8 2019, 7:48 AM.

Diff Detail

Event Timeline

kwk created this revision.Oct 8 2019, 7:48 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 8 2019, 7:48 AM
labath added inline comments.Oct 8 2019, 7:51 AM
lldb/source/Host/common/LZMA.cpp
99

I think this should be + to preserve semantics, though I am not sure why no tests fail because of that. I guess none of the lzma streams we have have non-zero backward_size..

kwk updated this revision to Diff 223865.Oct 8 2019, 7:54 AM
kwk marked an inline comment as done.

Fixup

kwk marked an inline comment as done.Oct 8 2019, 7:54 AM
kwk added inline comments.
lldb/source/Host/common/LZMA.cpp
99

Sorry, tests are still running... and you're right.

labath accepted this revision.Oct 8 2019, 8:02 AM

LGTM. I don't know if there's a reasonable way to add a test with a non-zero backward_size, but if you can think of something, please add one.

This revision is now accepted and ready to land.Oct 8 2019, 8:02 AM
This revision was automatically updated to reflect the committed changes.
kwk marked an inline comment as done.