mirror of
				https://github.com/janet-lang/janet
				synced 2025-10-31 15:43:01 +00:00 
			
		
		
		
	changed some error messages 'x|y' -> 'x or y'
This commit is contained in:
		| @@ -458,7 +458,7 @@ JANET_CORE_FN(janet_core_getproto, | |||||||
|                ? janet_wrap_struct(janet_struct_proto(st)) |                ? janet_wrap_struct(janet_struct_proto(st)) | ||||||
|                : janet_wrap_nil(); |                : janet_wrap_nil(); | ||||||
|     } |     } | ||||||
|     janet_panicf("expected struct|table, got %v", argv[0]); |     janet_panicf("expected struct or table, got %v", argv[0]); | ||||||
| } | } | ||||||
|  |  | ||||||
| JANET_CORE_FN(janet_core_struct, | JANET_CORE_FN(janet_core_struct, | ||||||
|   | |||||||
| @@ -2911,7 +2911,7 @@ static JanetEVGenericMessage janet_go_thread_subr(JanetEVGenericMessage args) { | |||||||
|         JanetFiber *fiber; |         JanetFiber *fiber; | ||||||
|         if (!janet_checktype(fiberv, JANET_FIBER)) { |         if (!janet_checktype(fiberv, JANET_FIBER)) { | ||||||
|             if (!janet_checktype(fiberv, JANET_FUNCTION)) { |             if (!janet_checktype(fiberv, JANET_FUNCTION)) { | ||||||
|                 janet_panicf("expected function|fiber, got %v", fiberv); |                 janet_panicf("expected function or fiber, got %v", fiberv); | ||||||
|             } |             } | ||||||
|             JanetFunction *func = janet_unwrap_function(fiberv); |             JanetFunction *func = janet_unwrap_function(fiberv); | ||||||
|             if (func->def->min_arity > 1) { |             if (func->def->min_arity > 1) { | ||||||
|   | |||||||
| @@ -1100,7 +1100,7 @@ static void spec_matchtime(Builder *b, int32_t argc, const Janet *argv) { | |||||||
|     Janet fun = argv[1]; |     Janet fun = argv[1]; | ||||||
|     if (!janet_checktype(fun, JANET_FUNCTION) && |     if (!janet_checktype(fun, JANET_FUNCTION) && | ||||||
|             !janet_checktype(fun, JANET_CFUNCTION)) { |             !janet_checktype(fun, JANET_CFUNCTION)) { | ||||||
|         peg_panicf(b, "expected function|cfunction, got %v", fun); |         peg_panicf(b, "expected function or cfunction, got %v", fun); | ||||||
|     } |     } | ||||||
|     uint32_t tag = (argc == 3) ? emit_tag(b, argv[2]) : 0; |     uint32_t tag = (argc == 3) ? emit_tag(b, argv[2]) : 0; | ||||||
|     uint32_t cindex = emit_constant(b, fun); |     uint32_t cindex = emit_constant(b, fun); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Ico Doornekamp
					Ico Doornekamp