mirror of
https://github.com/erg-lang/erg.git
synced 2025-07-24 05:26:24 +00:00
fix: union types bug & multi-pattern def bug
This commit is contained in:
parent
7c8b8a66a1
commit
fc85265d9f
14 changed files with 299 additions and 88 deletions
|
@ -1024,6 +1024,7 @@ impl LowerWarning {
|
|||
fn_name: &str,
|
||||
typ: &Type,
|
||||
) -> Self {
|
||||
let fn_name = fn_name.with_color(Color::Yellow);
|
||||
let hint = switch_lang!(
|
||||
"japanese" => format!("`{fn_name}(...): {typ} = ...`など明示的に戻り値型を指定してください"),
|
||||
"simplified_chinese" => format!("请明确指定函数{fn_name}的返回类型,例如`{fn_name}(...): {typ} = ...`"),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue