mirror of
https://github.com/nonebot/nonebot2.git
synced 2026-02-26 20:54:44 +00:00
💥 Remove: 移除 Python 3.9 支持 (#3860)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from typing import Any, TypeVar, Union
|
||||
from typing import Any, TypeVar
|
||||
|
||||
from nonebot.adapters import Event
|
||||
from nonebot.matcher import Matcher
|
||||
@@ -36,8 +36,8 @@ class BarMatcher(Matcher): ...
|
||||
|
||||
|
||||
async def union_matcher(
|
||||
m: Union[FooMatcher, BarMatcher],
|
||||
) -> Union[FooMatcher, BarMatcher]:
|
||||
m: FooMatcher | BarMatcher,
|
||||
) -> FooMatcher | BarMatcher:
|
||||
return m
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ async def generic_matcher_none(m: CM) -> CM:
|
||||
return m
|
||||
|
||||
|
||||
async def not_matcher(m: Union[int, Matcher]): ...
|
||||
async def not_matcher(m: int | Matcher): ...
|
||||
|
||||
|
||||
async def receive(e: Event = Received("test")) -> Event:
|
||||
|
||||
Reference in New Issue
Block a user