和c里的type有点像。
scala里的类型,除了在定义class,trait,object时会产生类型,还可以通过type关键字来声明类型。
class
trait
object
type
type相当于声明一个类型别名:
scala> type S = String
defined type alias S
http://hongjiang.info/scala-type-system-type-keyword/