def setSyntax(self, syntax):
        """Choose smart indentation algorithm according to syntax"""
        self._smartIndenter = self._chooseSmartIndenter(syntax)
def local_rank(self) -> int:
        return 0 if self._local_rank is None else self._local_rank