register_detector applies to each compilation unit
|
def register_detector(self, detector_class: Type[AbstractDetector]) -> None: |
|
""" |
|
:param detector_class: Class inheriting from `AbstractDetector`. |
|
""" |
|
_check_common_things("detector", detector_class, AbstractDetector, self._detectors) |
|
|
|
for compilation_unit in self.compilation_units: |
|
instance = detector_class(compilation_unit, self, logger_detector) |
|
self._detectors.append(instance) |
register_printer does not and needs to be updated
|
def register_printer(self, printer_class: Type[AbstractPrinter]) -> None: |
|
""" |
|
:param printer_class: Class inheriting from `AbstractPrinter`. |
|
""" |
|
_check_common_things("printer", printer_class, AbstractPrinter, self._printers) |
|
|
|
instance = printer_class(self, logger_printer) |
|
self._printers.append(instance) |
register_detectorapplies to each compilation unitslither/slither/slither.py
Lines 181 to 189 in 776dcab
register_printerdoes not and needs to be updatedslither/slither/slither.py
Lines 201 to 208 in 776dcab