diff --git a/lab1/grammar/korean/MicroLangKor.gf b/lab1/grammar/korean/MicroLangKor.gf index 356e8b8..532b67f 100644 --- a/lab1/grammar/korean/MicroLangKor.gf +++ b/lab1/grammar/korean/MicroLangKor.gf @@ -105,7 +105,7 @@ lin music_N = mkN "음악" ; -- lin now_Adv = mkAdv "지금" ; -- lin old_A = mkA "낡안" ; -- lin paris_PN = mkPN "Paris" ; -lin play_V = mkV "놀" ; +-- lin play_V = mkV "놀" ; -- lin read_V2 = mkV2 (mkV "read" "read" "read") ; -- lin ready_A = mkA "ready" ; -- lin red_A = mkA "red" ; @@ -114,7 +114,7 @@ lin river_N = mkN "river" ; lin sea_N = mkN "바다" ; -- lin see_V2 = mkV2 (mkV "see" "saw" "seen") ; lin ship_N = mkN "ship" ; -lin sleep_V = mkV "자" ; +-- lin sleep_V = mkV "자" ; -- lin small_A = mkA "작은" ; lin star_N = mkN "별" ; -- lin swim_V = mkV "swim" "swam" "swum" ; @@ -149,13 +149,4 @@ oper mkPrep : Str -> Prep = \s -> lin Prep {s = s} ; - - mkV = overload { - mkV : Str -> V = \stem -> lin V { - s = table { - VPresent => stem + "어요" ; - VPast => stem + "었어요" - } - } - } ; } diff --git a/lab1/grammar/korean/MicroResKor.gf b/lab1/grammar/korean/MicroResKor.gf index 1921938..a1fd20e 100644 --- a/lab1/grammar/korean/MicroResKor.gf +++ b/lab1/grammar/korean/MicroResKor.gf @@ -1,10 +1,19 @@ resource MicroResKor = open Prelude in { param - VForm = VPresent | VPast ; + VForm = Lemma | VPresent | VPast ; oper Noun : Type = {s : Str} ; Verb : Type = {s : VForm => Str} ; Verb2 : Type = Verb ; Adjective : Type = Verb ; + + lemmaToStem : (lemma : Str) -> Str + = \lemma -> case lemma of { + stem + "다" => stem ; + _ => Predef.error ("lemmaToStem was applied to a non-lemma, " ++ lemma) + } ; + + -- regVerb_eo : (lemma : Str) -> Verb + }