Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

多了一个‘*’字符,展示时会多一个* #9

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion blogs/javase/java基础巩固笔记(2)-泛型.md
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ Error:(17, 29) java: 不兼容的类型: 推断类型不符合上限

`add(3,5)` -> `static <T> T add(T a,T b)`

- 当某个类型变量在整个参数列表的所有参数和返回值中的***多处被应用**了,如果调用方法时这么多处的实际应用类型 *对应不同的类型,且没有返回值*,则取多个参数中的最大交集类型,即第一个公共父类。
- 当某个类型变量在整个参数列表的所有参数和返回值中的**多处被应用**了,如果调用方法时这么多处的实际应用类型 *对应不同的类型,且没有返回值*,则取多个参数中的最大交集类型,即第一个公共父类。
例如:

`fill(new Integer[3],3.5)` -> `static <T> void fill(T a[],T v)`
Expand Down