@@ -9,10 +9,11 @@ import { ExhaustedError, FilteredError } from "./error.ts";
99import { CONJUNCTION } from "./misc.ts" ;
1010import {
1111 adjectivalIsNone ,
12- AdjectivalModifier , adverbialIsNone ,
12+ AdjectivalModifier ,
13+ adverbialIsNone ,
1314 AdverbialModifier ,
1415 multipleModifiers ,
15- } from ' ./modifier.ts'
16+ } from " ./modifier.ts" ;
1617import { nounAsPreposition , preposition } from "./preposition.ts" ;
1718import { wordUnit } from "./word_unit.ts" ;
1819
@@ -148,12 +149,8 @@ function verbPhrase(
148149 } ;
149150}
150151function defaultPhrase (
151- options : Readonly < {
152- phrase : TokiPona . Phrase & { type : "simple" } ;
153- includeGerund : boolean ;
154- } > ,
152+ phrase : TokiPona . Phrase & { type : "simple" } ,
155153) {
156- const { phrase } = options ;
157154 const emphasis = phrase . emphasis != null ;
158155 return IterableResult . combine (
159156 wordUnit ( phrase . headWord ) ,
@@ -248,10 +245,7 @@ function preverb(
248245 ) ;
249246 return IterableResult . combine (
250247 verb ,
251- translatePhrase ( {
252- phrase : preverb . phrase ,
253- includeGerund : false ,
254- } ) ,
248+ translatePhrase ( preverb . phrase ) ,
255249 )
256250 . filterMap ( ( [ verb , predicate ] ) : null | English . SimpleVerbPhrase => {
257251 if (
@@ -301,15 +295,11 @@ function preverb(
301295}
302296const translatePhrase = phrase ;
303297export function phrase (
304- options : Readonly < {
305- phrase : TokiPona . Phrase ;
306- includeGerund : boolean ;
307- } > ,
298+ phrase : TokiPona . Phrase ,
308299) : IterableResult < PhraseTranslation > {
309- const { phrase } = options ;
310300 switch ( phrase . type ) {
311301 case "simple" :
312- return defaultPhrase ( { ... options , phrase } ) ;
302+ return defaultPhrase ( phrase ) ;
313303 case "preposition" :
314304 return preposition ( phrase )
315305 . map ( prepositionAsVerb )
@@ -394,14 +384,13 @@ export function phraseAsVerb(
394384export function multiplePhrases (
395385 options : Readonly < {
396386 phrases : TokiPona . MultiplePhrases ;
397- includeGerund : boolean ;
398387 andParticle : null | string ;
399388 } > ,
400389) : IterableResult < PhraseTranslation > {
401390 const { phrases, andParticle } = options ;
402391 switch ( phrases . type ) {
403392 case "simple" :
404- return phrase ( { ... options , phrase : phrases . phrase } ) ;
393+ return phrase ( phrases . phrase ) ;
405394 case "and" :
406395 case "anu" : {
407396 const conjunction = CONJUNCTION [ phrases . type ] ;
0 commit comments