Skip to content

Commit 49fc78b

Browse files
committed
Add link to enum type. Put the signal number -> Signal section on its own paragraph to keep it from getting lost in the preceding text
1 parent 8ca1c63 commit 49fc78b

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

doc/Type/Supply.pod6

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -599,12 +599,16 @@ the supply. For example:
599599
600600
signal(SIGINT).tap( { say "Thank you for your attention"; exit 0 } );
601601
602-
would catch Control-C, thank you, and then exit. The list of supported
603-
signals can be found by checking Signal::.keys (as you would any enum).
604-
To go from a signal number to Signal, you can do something like this:
602+
would catch Control-C, thank you, and then exit.
603+
604+
To go from a signal number to a Signal, you can do something like this:
605605
606606
signal(Signal(2)).tap( -> $sig { say "Received signal: $sig" } );
607607
608+
The list of supported signals can be found by checking Signal::.keys (as
609+
you would any enum). For more details on how enums work see
610+
L<enum|/language/typesystem#enum>.
611+
608612
=head2 method IO::Notification.watch-path
609613
610614
=for code :skip-test

0 commit comments

Comments
 (0)