Skip to content

Commit 48d40a4

Browse files
committed
add lint config
1 parent 0261661 commit 48d40a4

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

.flake8

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[flake8]
2+
max-line-length = 100
3+
extend-ignore = E221,E501

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,10 @@ dependencies = [
6060
]
6161

6262
[tool.hatch.envs.lint.scripts]
63+
lint = [
64+
"- flake8 src/lambda_calculus",
65+
"- pylint src/lambda_calculus"
66+
]
6367
typecheck = "mypy -p lambda_calculus"
6468
release = [
6569
"typecheck"
@@ -79,6 +83,9 @@ warn_unused_ignores = true
7983
warn_return_any = true
8084
warn_unreachable = true
8185

86+
[tool.pylint]
87+
max-line-length = 100
88+
8289
[tool.coverage.run]
8390
source_pkgs = ["lambda_calculus"]
8491
branch = true

src/lambda_calculus/visitors/normalisation.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class BetaNormalisingVisitor(Visitor[Iterator[Step], str]):
4646
def skip_intermediate(self, term: terms.Term[str]) -> terms.Term[str]:
4747
"""
4848
Calculate the beta normal form directly.
49-
49+
5050
:param term: term which should be transformed into ist beta normal form
5151
:return: new term representing the beta normal form if it exists
5252
"""
@@ -77,7 +77,7 @@ def visit_abstraction(self, abstraction: terms.Abstraction[str]) -> Iterator[Ste
7777
def beta_reducation(self, abstraction: terms.Abstraction[str], argument: terms.Term[str]) -> Generator[Step, None, terms.Term[str]]:
7878
"""
7979
Perform beta reduction of an application.
80-
80+
8181
:param abstraction: abstraction of the application
8282
:param argument: argument of the application
8383
:return: Generator yielding steps and returning the reduced term

0 commit comments

Comments
 (0)