Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
JuanCoRo committed Jan 21, 2025
1 parent 6c969da commit 9074215
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pyk/src/pyk/k2lean4/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from collections.abc import Iterable
from typing import Final

_LEAN_KEYWORDS: Final = {'ite', 'end', 'where'} # Words that cannot be a the name of a declaration
_LEAN_WORDS: Final = {'ite', 'end', 'where'} # Words that cannot be a the name of a declaration


def indent(text: str, n: int) -> str:
Expand All @@ -24,10 +24,10 @@ def mask_name(name: str, mask: str | None) -> str:
"""Append `mask` to `name` if `name` is in `_LEAN_KEYWORDS`."""
if name == '':
return ''
elif name not in _LEAN_KEYWORDS:
elif name not in _LEAN_WORDS:
return name
else:
return f'{name}{mask}' if mask is not None and is not '' else f'{name}Mask'
return f'{name}{mask}' if mask is not None and mask != '' else f'{name}Mask'


@final
Expand Down

0 comments on commit 9074215

Please sign in to comment.