mirror of
				https://github.com/janet-lang/janet
				synced 2025-10-31 15:43:01 +00:00 
			
		
		
		
	Add some detail to signal docstring
This commit is contained in:
		| @@ -700,7 +700,15 @@ JANET_CORE_FN(janet_core_is_lengthable, | ||||
|  | ||||
| JANET_CORE_FN(janet_core_signal, | ||||
|               "(signal what x)", | ||||
|               "Raise a signal with payload x. ") { | ||||
|               "Raise a signal with payload x. `what` can be an integer\n" | ||||
|               "from 0 through 7 indicating user(0-7), or one of:\n\n" | ||||
|               "* :ok\n" | ||||
|               "* :error\n" | ||||
|               "* :debug\n" | ||||
|               "* :yield\n" | ||||
|               "* :user(0-7)\n" | ||||
|               "* :interrupt\n" | ||||
|               "* :await") { | ||||
|     janet_arity(argc, 1, 2); | ||||
|     Janet payload = argc == 2 ? argv[1] : janet_wrap_nil(); | ||||
|     if (janet_checkint(argv[0])) { | ||||
|   | ||||
| @@ -79,6 +79,7 @@ const char *const janet_type_names[16] = { | ||||
|     "pointer" | ||||
| }; | ||||
|  | ||||
| /* Docstring for signal lists these */ | ||||
| const char *const janet_signal_names[14] = { | ||||
|     "ok", | ||||
|     "error", | ||||
| @@ -96,6 +97,7 @@ const char *const janet_signal_names[14] = { | ||||
|     "await" | ||||
| }; | ||||
|  | ||||
| /* Docstring for fiber/status lists these */ | ||||
| const char *const janet_status_names[16] = { | ||||
|     "dead", | ||||
|     "error", | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 sogaiu
					sogaiu