mirror of
				https://github.com/janet-lang/janet
				synced 2025-11-04 09:33:02 +00:00 
			
		
		
		
	Add mod function to core.
The `mod` function is a pair function with `%`, or te remainder function and is distinct from it. This is taken from common lisp.
This commit is contained in:
		@@ -108,6 +108,7 @@ static const JanetInstructionDef janet_ops[] = {
 | 
			
		||||
    {"mkstu", JOP_MAKE_STRUCT},
 | 
			
		||||
    {"mktab", JOP_MAKE_TABLE},
 | 
			
		||||
    {"mktup", JOP_MAKE_TUPLE},
 | 
			
		||||
    {"mod", JOP_MODULO},
 | 
			
		||||
    {"movf", JOP_MOVE_FAR},
 | 
			
		||||
    {"movn", JOP_MOVE_NEAR},
 | 
			
		||||
    {"mul", JOP_MULTIPLY},
 | 
			
		||||
@@ -121,6 +122,7 @@ static const JanetInstructionDef janet_ops[] = {
 | 
			
		||||
    {"pusha", JOP_PUSH_ARRAY},
 | 
			
		||||
    {"put", JOP_PUT},
 | 
			
		||||
    {"puti", JOP_PUT_INDEX},
 | 
			
		||||
    {"rem", JOP_REMAINDER},
 | 
			
		||||
    {"res", JOP_RESUME},
 | 
			
		||||
    {"ret", JOP_RETURN},
 | 
			
		||||
    {"retn", JOP_RETURN_NIL},
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user