added iSimple to Swedish as well

This commit is contained in:
Krasimir Angelov
2018-05-31 09:34:50 +02:00
parent 9558094911
commit 2668e58ab6
4 changed files with 24 additions and 11 deletions

View File

@@ -42,16 +42,17 @@ incomplete concrete CatScand of Cat =
s : Voice => VPForm => { s : Voice => VPForm => {
fin : Str ; -- V1 har ---s1 fin : Str ; -- V1 har ---s1
inf : Str ; -- V2 sagt ---s4 inf : Str ; -- V2 sagt ---s4
a1 : Polarity => Agr => Str * Str ; -- A1 inte ---s3 själv/själva/självt a1 : Polarity => Agr => Str * Str -- A1 inte ---s3 själv/själva/självt
-- p1: with infinite "jag har inte älskat dig", -- p1: with infinite "jag har inte älskat dig",
-- p2: without infinite "jag älskar dig inte" -- p2: without infinite "jag älskar dig inte"
} ; } ;
sp : PartForm => Str ; sp : PartForm => Str ;
n1 : Agr => Str ; -- N2 dig ---s5 n1 : Agr => Str ; -- N2 dig ---s5
n2 : Agr => Str ; -- N2 den där mannen ---s5 n2 : Agr => Str ; -- N2 den där mannen ---s5
a2 : Str ; -- A2 idag ---s6 a2 : Str ; -- A2 idag ---s6
ext : Str ; -- S-Ext att hon går ---s7 ext : Str ; -- S-Ext att hon går ---s7
en2,ea2,eext : Bool -- indicate if the field exists en2,ea2,eext : Bool ; -- indicate if the field exists
isSimple : Bool
} ; } ;
VPSlash = CommonScand.VP ** { VPSlash = CommonScand.VP ** {
n3 : Agr => Str ; -- object-control complement n3 : Agr => Str ; -- object-control complement

View File

@@ -297,7 +297,8 @@ oper
a2 : Str ; -- A2 idag ---s6 a2 : Str ; -- A2 idag ---s6
ext : Str ; -- S-Ext att hon går ---s7 ext : Str ; -- S-Ext att hon går ---s7
--- ea1,ev2, --- these depend on params of v and a1 --- ea1,ev2, --- these depend on params of v and a1
en2,ea2,eext : Bool -- indicate if the field exists en2,ea2,eext : Bool ; -- indicate if the field exists
isSimple : Bool
} ; } ;
@@ -305,6 +306,7 @@ oper
n1 = \\a => vp.n1 ! a ++ if_then_Str isPron (obj ! a) [] ; n1 = \\a => vp.n1 ! a ++ if_then_Str isPron (obj ! a) [] ;
n2 = \\a => vp.n2 ! a ++ if_then_Str isPron [] (obj ! a) ; n2 = \\a => vp.n2 ! a ++ if_then_Str isPron [] (obj ! a) ;
en2 = notB isPron ; en2 = notB isPron ;
isSimple = False
} ; } ;
insertObj : (Agr => Str) -> VP -> VP = insertObjPron False ; insertObj : (Agr => Str) -> VP -> VP = insertObjPron False ;
@@ -312,16 +314,19 @@ oper
insertObjPost : (Agr => Str) -> VP -> VP = \obj,vp -> vp ** { insertObjPost : (Agr => Str) -> VP -> VP = \obj,vp -> vp ** {
n2 = \\a => vp.n2 ! a ++ obj ! a ; n2 = \\a => vp.n2 ! a ++ obj ! a ;
en2 = True ; en2 = True ;
isSimple = False
} ; } ;
insertAdv : Str -> VP -> VP = \adv,vp -> vp ** { insertAdv : Str -> VP -> VP = \adv,vp -> vp ** {
a2 = vp.a2 ++ adv ; a2 = vp.a2 ++ adv ;
ea2 = True ; ea2 = True ;
isSimple = False
} ; } ;
insertExt : Str -> VP -> VP = \ext,vp -> vp ** { insertExt : Str -> VP -> VP = \ext,vp -> vp ** {
ext = vp.ext ++ ext ; ext = vp.ext ++ ext ;
eext = True ; eext = True ;
isSimple = False
} ; } ;
insertAdV : Str -> VP -> VP = \adv -> insertAdVAgr (\\_ => adv) ; insertAdV : Str -> VP -> VP = \adv -> insertAdVAgr (\\_ => adv) ;

View File

@@ -82,7 +82,8 @@ interface ResScand = DiffScand ** open CommonScand, Prelude in {
n2 : Agr => Str = \\a => verb.part ; ---- check: hon ser (inte) vacker ut ; spotta (inte) ut snusen n2 : Agr => Str = \\a => verb.part ; ---- check: hon ser (inte) vacker ut ; spotta (inte) ut snusen
a2 : Str = [] ; a2 : Str = [] ;
ext : Str = [] ; ext : Str = [] ;
en2,ea2,eext : Bool = False -- indicate if the field exists en2,ea2,eext : Bool = False ; -- indicate if the field exists
isSimple = True
} ; } ;
comma : Str = SOFT_BIND ++ "," ; comma : Str = SOFT_BIND ++ "," ;

View File

@@ -157,17 +157,23 @@ concrete ExtendSwe of Extend = CatSwe **
PositAdVAdj a = {s = a.s ! AAdv} ; PositAdVAdj a = {s = a.s ! AAdv} ;
PresPartAP vp = { PresPartAP vp = {
s = \\af => partVPPlus vp (PartPres Sg Indef Nom) (aformpos2agr af) Pos ; s = \\af => case vp.isSimple of {
isPre = True True => partVPPlus vp (PartPres Sg Indef Nom) (aformpos2agr af) Pos ;
False => partVPPlusPost vp (PartPres Sg Indef Nom) (aformpos2agr af) Pos
} ;
isPre = vp.isSimple
} ; } ;
PastPartAP vp = { PastPartAP vp = {
s = \\af => partVPPlus vp (PartPret af Nom) (aformpos2agr af) Pos ; s = \\af => case vp.isSimple of {
isPre = True True => partVPPlus vp (PartPret af Nom) (aformpos2agr af) Pos ;
False => partVPPlusPost vp (PartPret af Nom) (aformpos2agr af) Pos
} ;
isPre = vp.isSimple
} ; } ;
PastPartAgentAP vp np = { PastPartAgentAP vp np = {
s = \\af => partVPPlus vp (PartPret af Nom) (aformpos2agr af) Pos ++ "av" ++ np.s ! accusative ; s = \\af => partVPPlusPost vp (PartPret af Nom) (aformpos2agr af) Pos ++ "av" ++ np.s ! accusative ;
isPre = False isPre = False
} ; } ;