Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
439 views
in Technique[技术] by (71.8m points)

java - 如何解决“无法将var解析为类型”错误?(How to solve the error “var cannot be resolved to a type”?)

I am getting the error for the following line:

(我收到以下行的错误:)

var playerAmt = player.stream().filter(Card::isTrue).count();

Error:

(错误:)

var cannot be resolved to a type

(var无法解析为类型)

I am not writing the whole code here because it's quite long and I think it won't help much.

(我不会在此处编写整个代码,因为它很长,我认为它不会有太大帮助。)

The same error exists at different places in the code.

(在代码的不同位置存在相同的错误。)

I am using Eclipse IDE.

(我正在使用Eclipse IDE。)

I also searched this on the internet but didn't help.

(我也在互联网上进行了搜索,但没有帮助。)

  ask by Ricky translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

56.9k users

...