@@ -75,18 +75,17 @@ fn sutra_8_4_2() {
7575
7676#[ test]
7777fn sutra_8_4_8 ( ) {
78- let mut rule_choices: Vec < RuleChoice > = vec ! [ ] ;
7978 let vah = d ( "va\\ ha~^" , Bhvadi ) ;
8079
8180 // 8.4.8 has two rules
8281 // Nipatana ufor vAhana always
8382 // 8.4.8.1 : Ahita for vAhanam
84- rule_choices . push ( RuleChoice {
85- rule : Rule :: Ashtadhyayi ( "8.4.8.1" ) ,
86- decision : Decision :: Accept
87- } ) ;
88-
89- let mut t = Tester :: with_rule_choices ( rule_choices ) ;
83+ let mut t = Tester :: with_rule_choices ( vec ! [
84+ RuleChoice {
85+ rule : Rule :: Ashtadhyayi ( "8.4.8.1" ) ,
86+ decision : Decision :: Accept
87+ } ,
88+ ] ) ;
9089
9190 t. assert_has_upapada_krdanta ( "ikzu" , & [ ] , & vah, Krt :: lyuw, & [ "ikzuvAhaRa" ] ) ;
9291 t. assert_has_upapada_krdanta ( "darBa" , & [ ] , & vah, Krt :: lyuw, & [ "darBavAhaRa" ] ) ;
@@ -96,13 +95,12 @@ fn sutra_8_4_8() {
9695 t. assert_has_bahuvrihi ( "darBa" , "vAhana" , & [ "darBavAhaRa" ] ) ;
9796
9897 // Swamitva artha
99- rule_choices = vec ! [ ] ;
100- rule_choices. push ( RuleChoice {
101- rule : Rule :: Ashtadhyayi ( "8.4.8.1" ) ,
102- decision : Decision :: Decline
103- } ) ;
104-
105- t = Tester :: with_rule_choices ( rule_choices) ;
98+ t = Tester :: with_rule_choices ( vec ! [
99+ RuleChoice {
100+ rule: Rule :: Ashtadhyayi ( "8.4.8.1" ) ,
101+ decision: Decision :: Decline
102+ } ,
103+ ] ) ;
106104 t. assert_has_upapada_krdanta ( "dAkzi" , & [ ] , & vah, Krt :: lyuw, & [ "dAkzivAhana" ] ) ;
107105
108106 // As in dAkzi's vAhana .. (sasthi tatpurusha intent so Decline the rule)
@@ -309,15 +307,13 @@ fn sutra_8_4_24() {
309307 assert_has_jhi ( & [ "antar" ] , & han, Lat , & [ "antarGnanti" ] ) ;
310308 assert_has_krdanta ( & [ "antar" ] , & han, Krt :: lyuw, & [ "antarhaRana" , "antarhanana" ] ) ;
311309
312- // Forcing a specific choice to assume "desh" context
313- let mut rule_choices = vec ! [ ] ;
314- rule_choices. push ( RuleChoice {
315- rule : Rule :: Ashtadhyayi ( "8.4.24" ) ,
316- decision : Decision :: Decline
317- } ) ;
318-
319310 // The "desh" case
320- let t = Tester :: with_rule_choices ( rule_choices) ;
311+ let t = Tester :: with_rule_choices ( vec ! [
312+ RuleChoice {
313+ rule: Rule :: Ashtadhyayi ( "8.4.24" ) ,
314+ decision: Decision :: Decline
315+ }
316+ ] ) ;
321317 t. assert_has_ta_k ( & [ "antar" ] , & han, Lat , & [ "antarhanyate" ] ) ;
322318 t. assert_has_ta_k ( & [ "antar" ] , & han, Lun , & [ "antaraGAni" , "antaravaDi" ] ) ; // No change
323319 t. assert_has_jhi ( & [ "antar" ] , & han, Lat , & [ "antarGnanti" ] ) ;
@@ -326,26 +322,22 @@ fn sutra_8_4_24() {
326322
327323#[ test]
328324fn sutra_8_4_25 ( ) {
329- let mut rule_choices: Vec < RuleChoice > = vec ! [ ] ;
330-
331- // 8.4.25 : Accept
332- rule_choices. push ( RuleChoice {
333- rule : Rule :: Ashtadhyayi ( "8.4.25" ) ,
334- decision : Decision :: Accept
335- } ) ;
336-
337- let mut t = Tester :: with_rule_choices ( rule_choices) ;
325+ let mut t = Tester :: with_rule_choices ( vec ! [
326+ RuleChoice {
327+ rule: Rule :: Ashtadhyayi ( "8.4.25" ) ,
328+ decision: Decision :: Accept
329+ }
330+ ] ) ;
338331 // antaH (antarasmin?) ayanam
339332 t. assert_has_saptami_tatpurusha ( "antar" , "ayana" , & [ "antarayaRa" ] ) ;
340333
341334 // 8.4.25: Decline ("Desh" case)
342- rule_choices = vec ! [ ] ;
343- rule_choices. push ( RuleChoice {
344- rule : Rule :: Ashtadhyayi ( "8.4.25" ) ,
345- decision : Decision :: Decline
346- } ) ;
347-
348- t = Tester :: with_rule_choices ( rule_choices) ;
335+ t = Tester :: with_rule_choices ( vec ! [
336+ RuleChoice {
337+ rule: Rule :: Ashtadhyayi ( "8.4.25" ) ,
338+ decision: Decision :: Decline
339+ }
340+ ] ) ;
349341 // antaH Iyate asmin deSe
350342 t. assert_has_bahuvrihi ( "antar" , "ayana" , & [ "antarayana" ] ) ;
351343}
0 commit comments