Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
tserg committed Dec 5, 2024
1 parent ad01f5a commit 97feac2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions vyper/semantics/types/primitives.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,12 +141,11 @@ def validate_literal(self, node: vy_ast.Constant) -> None:

value = node.value
if isinstance(node, vy_ast.Hex):
# TODO: raise if signed integer
if self.is_signed:
raise InvalidLiteral("Hex integers must be unsigned", node)

if node.value not in (node.value.lower(), node.value.upper()):
raise InvalidLiteral("Cannot mix uppercase and lowercase for hex integers", node)

value = node.int_value

if value < lower:
Expand Down

0 comments on commit 97feac2

Please sign in to comment.