[08:19:34] early bird doodle for GF seminar: https://doodle.com/poll/qisap3f4yfxrtnce [08:29:42] *** Joins: wmacmil (~wmacmil@2600:1700:cd90:8f10:340c:b145:c6ee:fdbd) [08:30:29] so when I try to turn an arbitray number into a determiner, I'm getting a really confusing run time error [08:30:30] -- MkNum : Int -> Number ; [08:30:30] -- MkNum i = mkDet (mkDigits i.s) ; [08:30:57] Drive> - compiling DriveEng.gf... [08:30:57] DriveEng.gf: [08:30:57] Warning: no linearization of Person [08:30:57] Internal error in Compute.ConcreteNew: [08:30:58] Applying Predef.error: Expected a value of type String, got VC (VC (VString "s2d:") (VC (VString "not") (VC (VString "a") (VC (VString "valid") (VString "digit"))))) (VGen 1 []) [08:31:01] CallStack (from HasCallStack): [08:31:03] error, called at src/compiler/GF/Compile/Compute/ConcreteNew.hs:588:13 in gf-3.10.4-BNI84g7Cbh1LvYlghrRUOG:GF.Compile.Compute.ConcreteNew [08:31:20] am I doing something completely nonsensical, or?.. [08:36:32] also, why when I use the following : Person = mkN "person" "people" ; [08:36:33] [08:36:55] does it not parse [08:36:55] p -cat=Thing "people" [08:36:56] The parser failed at token 1: "people" [08:37:09] but it parses with person [08:37:26] p -cat=Thing "person" [08:37:26] Person [09:09:30] there are some weird things with the GF shell wrt parsing [09:10:10] if you have a lincat that contains a table, then when you parse a wordform, it just recognises the form that is the RHS of the first parameter you specified in param [09:10:18] example coming [09:12:08] abstract Foo = { [09:12:08] cat [09:12:08] S ; [09:12:08] fun [09:12:08] test : S ; [09:12:08] } [09:12:16] concrete FooEng of Foo = { [09:12:16] lincat [09:12:16] S = {s : Number => Str} ; [09:12:16] lin [09:12:16] test = {s = table {Sg => "test" ; Pl => "tests"}} ; [09:12:17] param [09:12:17] Number = Sg | Pl ; [09:12:18] } [09:12:42] now I can parse "test" in the GF shell, but not "tests" [09:13:05] but if I change the line in the concrete syntax, where I define the param Number, like this: [09:13:11] param [09:13:12] Number = Pl | Sg ; [09:13:15] [09:13:22] then I can only parse "tests", but not "test" [09:14:07] [09:14:19] now if I keep the line Number = Pl | Sg ; but add a linref like this: [09:14:21] [09:14:22] linref [09:14:23] S = \s -> s.s ! Sg ; [09:14:24] [09:14:31] then I can again only parse "test", not "tests" [09:16:16] [09:16:32] I can make the linref anything I want, I can even add new strings: [09:16:34] linref [09:16:34] S = \s -> "the Sg is" ++ s.s ! Sg ++ "and the Pl is" ++ s.s ! Pl; [09:16:41] [09:17:06] and now the GF shell recognises that string as the linearisation for the category S [09:17:12] works also for linearisation [09:17:13] Foo> l test [09:17:15] the Sg is test and the Pl is tests [09:18:03] [09:18:52] as for your first question, in mkDet (mkDigits i.s), you aren't allowed to do that, because mkDet ultimately calls an oper that pattern matches the string in i.s [09:18:58] the same situation as in this post https://inariksit.github.io/gf/2019/01/26/literals-2.html#arbitrary-strings-as-modifiers [09:19:53] if you want to make an Int literal into a Det, you need this rather awkward chain of 3 opers from the API: https://inariksit.github.io/gf/2019/01/26/literals-2.html#english-concrete-syntax [09:20:13] let sym : Symb = mkSymb int.s ; -- mkSymb : Str -> Symb ; [09:20:13] card : Card = symb sym ; -- symb : Symb -> Card ; [09:20:14] det : Det = mkDet card ; [13:25:51] *** Quits: wmacmil (~wmacmil@2600:1700:cd90:8f10:340c:b145:c6ee:fdbd) (Remote host closed the connection) [13:26:08] *** Joins: wmacmil (~wmacmil@2600:1700:cd90:8f10:340c:b145:c6ee:fdbd) [17:06:46] *** Quits: wmacmil (~wmacmil@2600:1700:cd90:8f10:340c:b145:c6ee:fdbd) (Ping timeout: 245 seconds) [17:14:37] *** Joins: wmacmil (~wmacmil@2600:1700:cd90:8f10:340c:b145:c6ee:fdbd) [17:15:46] tack, inari