reorganized the compiler code by moving the method data into the cunit_class

This commit is contained in:
hyunghwan.chung
2018-10-05 16:25:17 +00:00
parent e6fca77adf
commit 079f2d3f4a
4 changed files with 506 additions and 595 deletions

View File

@ -168,6 +168,21 @@ difficulty: how to ensure that the class implements the defined interface?
method shoutWith: number {}
}
<<swift>>
protocol StringConvertible {
func toString() -> String
}
extension String: StringConvertible {
func toString() -> String {
return self
}
}
<<end swift>>
4) other methods???
Let me think about it..