compilers/elbrus: wrap get_default_include_dirs with lru_cache

This commit is contained in:
Denis Drakhnia 2023-12-23 06:57:11 +02:00 committed by Dylan Baker
parent 6ccd708f30
commit 360d81e4aa
1 changed files with 2 additions and 0 deletions

View File

@ -5,6 +5,7 @@ from __future__ import annotations
"""Abstractions for the Elbrus family of compilers."""
import functools
import os
import typing as T
import subprocess
@ -59,6 +60,7 @@ class ElbrusCompiler(GnuLikeCompiler):
return [os.path.realpath(p) for p in libstr.split(':')]
return []
@functools.lru_cache(maxsize=None)
def get_default_include_dirs(self) -> T.List[str]:
os_env = os.environ.copy()
os_env['LC_ALL'] = 'C'