From 31b695bac3d2900d2348ec9e1e8468c30516407b Mon Sep 17 00:00:00 2001 From: Aaron Zuspan Date: Tue, 20 Aug 2024 00:02:01 -0700 Subject: [PATCH] Fix 3.8 typing incompatibility --- src/spinasm_lsp/tokens.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/spinasm_lsp/tokens.py b/src/spinasm_lsp/tokens.py index 89ce7a8..34340c0 100644 --- a/src/spinasm_lsp/tokens.py +++ b/src/spinasm_lsp/tokens.py @@ -5,7 +5,7 @@ import bisect import copy from dataclasses import dataclass -from typing import Generator, Generic, Literal, TypeVar, cast, overload +from typing import Generator, Generic, Literal, TypeVar, overload import lsprotocol.types as lsp @@ -223,7 +223,7 @@ def semantic_encoding(self, prev_token_start: lsp.Position) -> list[int]: return [] # The index of each modifier is encoded into a bitmask - modifier_bitmask = sum(1 << i for i in cast(list[int], token_modifiers)) + modifier_bitmask = sum(1 << i for i in token_modifiers) # type: ignore return [ delta_line,