Error: member names cannot be the same as their enclosing type
在编译的时候会遇到如下问题:member names cannot be the same as their enclosing type
原因:方法名和类名不能一样,如果一样就是一个构造函数。而构造函数不能有返回值。
构造函数:只写public 没有void
posted on 2013-06-27 16:18 CynthiaHuo 阅读(2334) 评论(0) 编辑 收藏 举报