On Mon, 28 Sep 2020 00:47:30 +0300
Dmitry Kozlyuk <dmitry.kozl...@gmail.com> wrote:

> Using a high-level, interpreted language simplifies maintenance and
> build process. Furthermore, ELF handling is delegated to pyelftools
> package. Original logic is kept, the copyright recognizes that.
> 
> Signed-off-by: Dmitry Kozlyuk <dmitry.kozl...@gmail.com>

Looks good, a couple little nits.

Yapf flags this as unnecessary spacing:


+    @property
+    def value(self):
+        data = self._image._image.get_section(self._symbol["st_shndx"]).data()
+        base = self._symbol["st_value"]
+        return data[base : base + self.size]
                         ^^^

Python lint complains about missing docstrings, which doesn't matter but it 
also shows:

$ pylint3 buildtools/pmdinfogen.py  | grep -v docstring
************* Module pmdinfogen
buildtools/pmdinfogen.py:27:15: W0212: Access to a protected member _image of a 
client class (protected-access)
buildtools/pmdinfogen.py:34:11: C1801: Do not use `len(SEQUENCE)` to determine 
if a sequence is empty (len-as-condition)
buildtools/pmdinfogen.py:50:4: R1710: Either all return statements in a 
function should return an expression, or none of them should. 
(inconsistent-return-statements)
buildtools/pmdinfogen.py:107:12: W0212: Access to a protected member 
_load_pci_ids of a client class (protected-access)

------------------------------------------------------------------
Your code has been rated at 7.93/10 (previous run: 7.93/10, +0.00)

Reply via email to