[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-25 Thread Michał Górny via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL285076: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older (authored by mgorny). Changed prior to commit: https://reviews.llvm.org/D24954?vs=75704=75713#toc Repository: rL LLVM

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-25 Thread Bruno Cardoso Lopes via cfe-commits
bruno accepted this revision. bruno added a comment. This revision is now accepted and ready to land. LGTM! https://reviews.llvm.org/D24954 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-25 Thread Michał Górny via cfe-commits
mgorny updated this revision to Diff 75704. mgorny added a comment. Updated to perform `.startswith()` check before splitting. https://reviews.llvm.org/D24954 Files: lib/Driver/ToolChains.cpp Index: lib/Driver/ToolChains.cpp

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-24 Thread Bruno Cardoso Lopes via cfe-commits
bruno added inline comments. Comment at: lib/Driver/ToolChains.cpp:3942 + int Version; + if (SplitLine.first.trim() != "VERSION") +continue; mgorny wrote: > bruno wrote: > > You can check `Line.trim() != VERSION` before the `split` as to do not

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-24 Thread Michał Górny via cfe-commits
mgorny added inline comments. Comment at: lib/Driver/ToolChains.cpp:3942 + int Version; + if (SplitLine.first.trim() != "VERSION") +continue; bruno wrote: > You can check `Line.trim() != VERSION` before the `split` as to do not try to > split

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-24 Thread Bruno Cardoso Lopes via cfe-commits
bruno added inline comments. Comment at: lib/Driver/ToolChains.cpp:3942 + int Version; + if (SplitLine.first.trim() != "VERSION") +continue; You can check `Line.trim() != VERSION` before the `split` as to do not try to split unnecessary lines.

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-24 Thread Michał Górny via cfe-commits
mgorny updated this revision to Diff 75615. mgorny added a comment. Refactored the code as requested. Also I've noticed that if VERSION had invalid value, the code continued reading the file — now it immediately returns UnknownDistro in that case. https://reviews.llvm.org/D24954 Files:

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-24 Thread Bruno Cardoso Lopes via cfe-commits
bruno added inline comments. Comment at: lib/Driver/ToolChains.cpp:3937 +StringRef Data = File.get()->getBuffer(); +SmallVector Lines; +Data.split(Lines, "\n"); This file usually has 5-6 lines, can you use 8 instead?

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-20 Thread Michał Górny via cfe-commits
mgorny marked 3 inline comments as done. mgorny added a comment. I think I've addressed all your concerns now. https://reviews.llvm.org/D24954 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D24954: [Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older

2016-10-20 Thread Michał Górny via cfe-commits
mgorny retitled this revision from "[ToolChains] Disable OpenSUSE rules for SLES10" to "[Driver] Disable OpenSUSE rules for OpenSUSE/SLES 10 and older". mgorny updated the summary for this revision. mgorny updated this revision to Diff 75357. https://reviews.llvm.org/D24954 Files: