Skip to content

Commit 87dfcc9

Browse files
committed
refactor: remove unnessecary parens around types.
1 parent 0d09bc4 commit 87dfcc9

File tree

1 file changed

+28
-28
lines changed

1 file changed

+28
-28
lines changed

src/Node/ReadLine.purs

+28-28
Original file line numberDiff line numberDiff line change
@@ -270,21 +270,21 @@ sigStpH = EventHandle "SIGSTP" identity
270270
close :: Interface -> Effect Unit
271271
close iface = runEffectFn1 closeImpl iface
272272

273-
foreign import closeImpl :: EffectFn1 (Interface) (Unit)
273+
foreign import closeImpl :: EffectFn1 Interface Unit
274274

275275
-- | The rl.pause() method pauses the input stream, allowing it to be resumed later if necessary.
276276
-- |
277277
-- | Calling rl.pause() does not immediately pause other events (including 'line') from being emitted by the readline.Interface instance.
278278
pause :: Interface -> Effect Unit
279279
pause iface = runEffectFn1 pauseImpl iface
280280

281-
foreign import pauseImpl :: EffectFn1 (Interface) (Unit)
281+
foreign import pauseImpl :: EffectFn1 Interface Unit
282282

283283
-- | Prompt the user for input on the specified `Interface`.
284284
prompt :: Interface -> Effect Unit
285285
prompt iface = runEffectFn1 promptImpl iface
286286

287-
foreign import promptImpl :: EffectFn1 (Interface) (Unit)
287+
foreign import promptImpl :: EffectFn1 Interface Unit
288288

289289
-- | - `preserveCursor` <boolean> If true, prevents the cursor placement from being reset to 0.
290290
-- |
@@ -296,7 +296,7 @@ foreign import promptImpl :: EffectFn1 (Interface) (Unit)
296296
prompt' :: Boolean -> Interface -> Effect Unit
297297
prompt' preserveCursor iface = runEffectFn2 promptOptsImpl preserveCursor iface
298298

299-
foreign import promptOptsImpl :: EffectFn2 (Boolean) (Interface) (Unit)
299+
foreign import promptOptsImpl :: EffectFn2 Boolean Interface Unit
300300

301301
-- | Writes a query to the output, waits
302302
-- | for user input to be provided on input, then invokes
@@ -318,7 +318,7 @@ foreign import promptOptsImpl :: EffectFn2 (Boolean) (Interface) (Unit)
318318
question :: String -> (String -> Effect Unit) -> Interface -> Effect Unit
319319
question text cb iface = runEffectFn3 questionImpl iface text $ mkEffectFn1 cb
320320

321-
foreign import questionImpl :: EffectFn3 (Interface) (String) (EffectFn1 String Unit) Unit
321+
foreign import questionImpl :: EffectFn3 Interface String (EffectFn1 String Unit) Unit
322322

323323
-- | Writes a query to the output, waits
324324
-- | for user input to be provided on input, then invokes
@@ -340,24 +340,24 @@ foreign import questionImpl :: EffectFn3 (Interface) (String) (EffectFn1 String
340340
question' :: String -> { signal :: AbortSignal } -> (String -> Effect Unit) -> Interface -> Effect Unit
341341
question' text opts cb iface = runEffectFn4 questionOptsCbImpl iface text opts $ mkEffectFn1 cb
342342

343-
foreign import questionOptsCbImpl :: EffectFn4 (Interface) (String) { signal :: AbortSignal } (EffectFn1 String Unit) Unit
343+
foreign import questionOptsCbImpl :: EffectFn4 Interface String { signal :: AbortSignal } (EffectFn1 String Unit) Unit
344344

345345
-- | The rl.resume() method resumes the input stream if it has been paused.
346346
resume :: Interface -> Effect Unit
347347
resume iface = runEffectFn1 resumeImpl iface
348348

349-
foreign import resumeImpl :: EffectFn1 (Interface) (Unit)
349+
foreign import resumeImpl :: EffectFn1 Interface Unit
350350

351351
-- | The rl.setPrompt() method sets the prompt that will be written to output whenever rl.prompt() is called.
352352
setPrompt :: String -> Interface -> Effect Unit
353353
setPrompt newPrompt iface = runEffectFn2 setPromptImpl iface newPrompt
354354

355-
foreign import setPromptImpl :: EffectFn2 (Interface) (String) (Unit)
355+
foreign import setPromptImpl :: EffectFn2 Interface String Unit
356356

357357
getPrompt :: Interface -> Effect String
358358
getPrompt iface = runEffectFn1 getPromptImpl iface
359359

360-
foreign import getPromptImpl :: EffectFn1 (Interface) (String)
360+
foreign import getPromptImpl :: EffectFn1 Interface String
361361

362362
writeData :: String -> Interface -> Effect Unit
363363
writeData dataStr iface = runEffectFn2 writeDataImpl iface dataStr
@@ -383,12 +383,12 @@ foreign import writeKeyImpl :: EffectFn2 Interface KeySequenceObj Unit
383383
line :: Interface -> Effect String
384384
line iface = runEffectFn1 lineImpl iface
385385

386-
foreign import lineImpl :: EffectFn1 (Interface) (String)
386+
foreign import lineImpl :: EffectFn1 Interface String
387387

388388
cursor :: Interface -> Effect Int
389389
cursor iface = runEffectFn1 cursorImpl iface
390390

391-
foreign import cursorImpl :: EffectFn1 (Interface) (Int)
391+
foreign import cursorImpl :: EffectFn1 Interface Int
392392

393393
type CursorPos =
394394
{ rows :: Int
@@ -398,84 +398,84 @@ type CursorPos =
398398
getCursorPos :: Interface -> Effect CursorPos
399399
getCursorPos iface = runEffectFn1 getCursorPosImpl iface
400400

401-
foreign import getCursorPosImpl :: EffectFn1 (Interface) (CursorPos)
401+
foreign import getCursorPosImpl :: EffectFn1 Interface CursorPos
402402

403403
clearLineLeft :: forall r. Writable r -> Effect Boolean
404404
clearLineLeft stream = runEffectFn1 clearLineLeftImpl stream
405405

406-
foreign import clearLineLeftImpl :: forall r. EffectFn1 (Writable r) (Boolean)
406+
foreign import clearLineLeftImpl :: forall r. EffectFn1 (Writable r) Boolean
407407

408408
clearLineLeft' :: forall r. Writable r -> Effect Unit -> Effect Boolean
409409
clearLineLeft' stream cb = runEffectFn2 clearLineLeftCbImpl stream cb
410410

411-
foreign import clearLineLeftCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) (Boolean)
411+
foreign import clearLineLeftCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) Boolean
412412

413413
clearLineRight :: forall r. Writable r -> Effect Boolean
414414
clearLineRight stream = runEffectFn1 clearLineRightImpl stream
415415

416-
foreign import clearLineRightImpl :: forall r. EffectFn1 (Writable r) (Boolean)
416+
foreign import clearLineRightImpl :: forall r. EffectFn1 (Writable r) Boolean
417417

418418
clearLineRight' :: forall r. Writable r -> Effect Unit -> Effect Boolean
419419
clearLineRight' stream cb = runEffectFn2 clearLineRightCbImpl stream cb
420420

421-
foreign import clearLineRightCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) (Boolean)
421+
foreign import clearLineRightCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) Boolean
422422

423423
clearEntireLine :: forall r. Writable r -> Effect Boolean
424424
clearEntireLine stream = runEffectFn1 clearEntireLineImpl stream
425425

426-
foreign import clearEntireLineImpl :: forall r. EffectFn1 (Writable r) (Boolean)
426+
foreign import clearEntireLineImpl :: forall r. EffectFn1 (Writable r) Boolean
427427

428428
clearEntireLine' :: forall r. Writable r -> Effect Unit -> Effect Boolean
429429
clearEntireLine' stream cb = runEffectFn2 clearEntireLineCbImpl stream cb
430430

431-
foreign import clearEntireLineCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) (Boolean)
431+
foreign import clearEntireLineCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) Boolean
432432

433433
clearScreenDown :: forall r. Writable r -> Effect Boolean
434434
clearScreenDown stream = runEffectFn1 clearScreenDownImpl stream
435435

436-
foreign import clearScreenDownImpl :: forall r. EffectFn1 (Writable r) (Boolean)
436+
foreign import clearScreenDownImpl :: forall r. EffectFn1 (Writable r) Boolean
437437

438438
clearScreenDown' :: forall r. Writable r -> Effect Unit -> Effect Boolean
439439
clearScreenDown' stream cb = runEffectFn2 clearScreenDownCbImpl stream cb
440440

441-
foreign import clearScreenDownCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) (Boolean)
441+
foreign import clearScreenDownCbImpl :: forall r. EffectFn2 (Writable r) (Effect Unit) Boolean
442442

443443
cursorToX :: forall r. Writable r -> Int -> Effect Boolean
444444
cursorToX stream x = runEffectFn2 cursorToXImpl stream x
445445

446-
foreign import cursorToXImpl :: forall r. EffectFn2 (Writable r) (Int) (Boolean)
446+
foreign import cursorToXImpl :: forall r. EffectFn2 (Writable r) Int Boolean
447447

448448
cursorToX' :: forall r. Writable r -> Int -> Effect Unit -> Effect Boolean
449449
cursorToX' stream x cb = runEffectFn3 cursorToXCbImpl stream x cb
450450

451-
foreign import cursorToXCbImpl :: forall r. EffectFn3 (Writable r) (Int) (Effect Unit) (Boolean)
451+
foreign import cursorToXCbImpl :: forall r. EffectFn3 (Writable r) Int (Effect Unit) Boolean
452452

453453
cursorToXY :: forall r. Writable r -> Int -> Int -> Effect Boolean
454454
cursorToXY stream x y = runEffectFn3 cursorToXYImpl stream x y
455455

456-
foreign import cursorToXYImpl :: forall r. EffectFn3 (Writable r) (Int) (Int) (Boolean)
456+
foreign import cursorToXYImpl :: forall r. EffectFn3 (Writable r) Int Int Boolean
457457

458458
cursorToXY' :: forall r. Writable r -> Int -> Int -> Effect Unit -> Effect Boolean
459459
cursorToXY' stream x y cb = runEffectFn4 cursorToXYCbImpl stream x y cb
460460

461-
foreign import cursorToXYCbImpl :: forall r. EffectFn4 (Writable r) (Int) (Int) (Effect Unit) (Boolean)
461+
foreign import cursorToXYCbImpl :: forall r. EffectFn4 (Writable r) Int Int (Effect Unit) Boolean
462462

463463
emitKeyPressEvents :: forall w. Readable w -> Effect Unit
464464
emitKeyPressEvents stream = runEffectFn1 emitKeyPressEventsImpl stream
465465

466-
foreign import emitKeyPressEventsImpl :: forall w. EffectFn1 (Readable w) (Unit)
466+
foreign import emitKeyPressEventsImpl :: forall w. EffectFn1 (Readable w) Unit
467467

468468
emitKeyPressEvents' :: forall w. Readable w -> Interface -> Effect Unit
469469
emitKeyPressEvents' stream iface = runEffectFn2 emitKeyPressEventsIfaceImpl stream iface
470470

471-
foreign import emitKeyPressEventsIfaceImpl :: forall w. EffectFn2 (Readable w) (Interface) (Unit)
471+
foreign import emitKeyPressEventsIfaceImpl :: forall w. EffectFn2 (Readable w) Interface Unit
472472

473473
moveCursorXY :: forall r. Writable r -> Int -> Int -> Effect Boolean
474474
moveCursorXY stream x y = runEffectFn3 moveCursorXYImpl stream x y
475475

476-
foreign import moveCursorXYImpl :: forall r. EffectFn3 (Writable r) (Int) (Int) (Boolean)
476+
foreign import moveCursorXYImpl :: forall r. EffectFn3 (Writable r) Int Int Boolean
477477

478478
moveCursorXY' :: forall r. Writable r -> Int -> Int -> Effect Unit -> Effect Boolean
479479
moveCursorXY' stream x y cb = runEffectFn4 moveCursorXYCbImpl stream x y cb
480480

481-
foreign import moveCursorXYCbImpl :: forall r. EffectFn4 (Writable r) (Int) (Int) (Effect Unit) (Boolean)
481+
foreign import moveCursorXYCbImpl :: forall r. EffectFn4 (Writable r) Int Int (Effect Unit) Boolean

0 commit comments

Comments
 (0)