docs/reference.json

Summary

Maintainability
Test Coverage
[{"name":"-","doc":"(- n1 n2 ...)\n(- n)\n\nSubtracts n2 and subsequent numbers from n1. If only one argument is passed\nit will negate the value."},{"name":"-->","doc":"Helper macro that simplifies calling methods on objects. It works with chaining\nusage: (--> ($ \"body\")\n            (css \"color\" \"red\")\n            (on \"click\" (lambda () (display \"click\"))))\n\n       (--> document (querySelectorAll \"div\"))\n\n       (--> (fetch \"https://jcubic.pl\")\n            (text)\n            (match #/<title>([^<]+)<\\/title>/)\n            1)\n\n       (--> document\n            (querySelectorAll \".cmd-prompt\")\n            0\n            'innerHTML\n            (replace #/<(\"[^\"]+\"|[^>])+>/g \"\"))\n\n       (--> document.body\n            (style.setProperty \"--color\" \"red\"))"},{"name":".","doc":"(. obj . args)\n(get obj . args)\n\nThis function uses an object as a base and keeps using arguments to get the\nproperty of JavaScript object. Arguments need to be a strings.\ne.g. `(. console \"log\")` if you use any function inside LIPS it\nwill be weakly bound (can be rebound), so you can call this log function\nwithout problem unlike in JavaScript when you use\n`var log = console.log`.\n`get` is an alias because . doesn't work everywhere, e.g. you can't\npass it as an argument."},{"name":"..","doc":"(.. foo.bar.baz)\n\nGets the value from a nested object where the argument is a period separated symbol."},{"name":"*","doc":"(* . numbers)\n\nMultiplies all numbers passed as arguments. If single value is passed\nit will return that value."},{"name":"**","doc":"(** a b)\n\nFunction that calculates number a to to the power of b."},{"name":"/","doc":"(/ n1 n2 ...)\n(/ n)\n\nDivides n1 by n2 and subsequent arguments one by one. If single argument\nis passed it will calculate (/ 1 n)."},{"name":"&","doc":"(& a b)\n\nFunction that calculates the bitwise and operation."},{"name":"+","doc":"(+ . numbers)\n\nSums all numbers passed as arguments. If single value is passed it will\nreturn that value."},{"name":"<","doc":"(< x1 x2 ...)\n\nFunction that compares its numerical arguments and checks if they are\nmonotonically increasing, i.e. x1 < x2 and x2 < x3 and so on."},{"name":"<<","doc":"(<< a b)\n\nFunction that left shifts the value a by value b bits."},{"name":"<=","doc":"(<= x1 x2 ...)\n\nFunction that compares its numerical arguments and checks if they are\nmonotonically nondecreasing, i.e. x1 <= x2 and x2 <= x3 and so on."},{"name":"=","doc":"(== x1 x2 ...)\n\nFunction that compares its numerical arguments and checks if they are\nall equal."},{"name":"==","doc":"(== x1 x2 ...)\n\nFunction that compares its numerical arguments and checks if they are\nall equal."},{"name":">","doc":"(> x1 x2 x3 ...)\n\nFunction that compares its numerical arguments and checks if they are\nmonotonically decreasing, i.e. x1 > x2 and x2 > x3 and so on."},{"name":">=","doc":"(>= x1 x2 ...)\n\nFunction that compares its numerical arguments and checks if they are\nmonotonically nonincreasing, i.e. x1 >= x2 and x2 >= x3 and so on."},{"name":">>","doc":"(>> a b)\n\nFunction that right shifts the value a by value b bits."},{"name":"|","doc":"(| a b)\n\nFunction that calculates the bitwise or operation."},{"name":"~","doc":"(~ number)\n\nFunction that calculates the bitwise inverse (flip all the bits)."},{"name":"1-","doc":"(1- number)\n\nFunction that subtracts 1 from the number and return result."},{"name":"1+","doc":"(1+ number)\n\nFunction that adds 1 to the number and return result."},{"name":"abs","doc":"(abs number)\n\nFunction that returns the absolute value (magnitude) of number."},{"name":"alist->assign","doc":"(alist->assign alist . list-of-alists)\n\nFunction that works like Object.assign but for LIPS alists."},{"name":"alist->object","doc":"(alist->object alist)\n\nFunction that converts alist pairs to a JavaScript object."},{"name":"always","doc":"(always constant)\n\nHigher-order function that returns a new thunk that always returns\nthe given constant when called."},{"name":"and","doc":"(and . expressions)\n\nMacro that evaluates each expression in sequence and if any value returns false\nit will stop and return false. If each value returns true it will return the\nlast value. If it's called without arguments it will return true."},{"name":"angle","doc":"(angle x)\n\nReturns angle of the complex number in polar coordinate system."},{"name":"append","doc":"(append item ...)\n\nFunction that creates a new list with each argument appended end-to-end.\nIt will always return a new list and not modify its arguments."},{"name":"append!","doc":"(append! arg1 ...)\n\nDestructive version of append, it can modify the lists in place. It returns\na new list where each argument is appended to the end. It may modify\nlists added as arguments."},{"name":"apply","doc":"(apply fn list)\n\nFunction that calls fn with the list of arguments."},{"name":"apropos","doc":"(apropos name)\n\nSearch the current environment and display names that match the given name.\nname can be regex, string or symbol."},{"name":"array->list","doc":"(array->list array)\n\nFunction that converts a JavaScript array to a LIPS cons list."},{"name":"array?","doc":"(array? expression)\n\nPredicate that tests if value is an array."},{"name":"assoc","doc":"(assoc obj alist)\n\nReturns pair from alist that match given key using equal? check."},{"name":"assq","doc":"(assq obj alist)\n\nReturns pair from a list that matches given key using eq? check."},{"name":"assv","doc":"(assv obj alist)\n\nReturns pair from alist that match given key using eqv? check."},{"name":"atan","doc":"(atan z)\n(atan x y)\n\nFunction calculates arcus tangent of a complex number.\nIf two arguments are passed and they are not complex numbers\nit calculate Math.atan2 on those arguments."},{"name":"await","doc":"(await value)\n\nUnquotes a quoted promise so it can be automagically evaluated (resolved\nto its value)."},{"name":"begin","doc":"(begin . args)\n\nMacro that runs a list of expressions in order and returns the value\nof the last one. It can be used in places where you can only have a\nsingle expression, like (if)."},{"name":"begin*","doc":"(begin* . body)\n\nThis macro is a parallel version of begin. It evaluates each expression\nin the body and if it's a promise it will await it in parallel and return\nthe value of the last expression (i.e. it uses Promise.all())."},{"name":"binary","doc":"(binary fn)\n\nReturns a new function with arguments limited to two."},{"name":"binary-port?","doc":"(binary-port? port)\n\nFunction that tests if argument is binary port."},{"name":"boolean?","doc":"(boolean? x)\n\nReturns true if value is boolean."},{"name":"boolean=?","doc":"(boolean=? b1 b2 ...)\n\nChecks if all arguments are boolean and if they are the same."},{"name":"bound?","doc":"(bound? x [env])\n\nFunction that check if the variable is defined in the given environment,\nor interaction-environment if not specified."},{"name":"buffer->u8vector","doc":"(buffer->u8vector bin)\n\nCross platform function that can be used in both Node and browser.\nIt can be used together with %read-file or %read-binary-file to convert\nthe result ArrayBuffer or Buffer to u8vector."},{"name":"bytevector","doc":"(u8vector v1 v2 ...)\n\nCreate unsigned 8-bit integer vector (C unsigned char) from give arguments."},{"name":"bytevector-append","doc":"(bytevector-append v1 ...)\n\nCreate new bytevector u8vector that is created from joining each argument."},{"name":"bytevector-copy","doc":"(bytevector-copy v)\n(bytevector-copy v start)\n(bytevector-copy v start end)\n\nReturns a new vector from start to end. If no start and end is provided\nwhole vector is copied and returned."},{"name":"bytevector-copy!","doc":"(bytevector-copy! to at from)\n(bytevector-copy! to at from start)\n(bytevector-copy! to at from start end)\n\nCopies the bytes of bytevector from between start and end to bytevector to,\nstarting at at."},{"name":"bytevector-length","doc":"(u8vector-length v)\n\nreturn length of unsigned 8-bit integer vector (C unsigned char)."},{"name":"bytevector-u8-ref","doc":"(u8vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"bytevector-u8-set!","doc":"(u8vector-set! vector k)\n\nFunction set value of unsigned 8-bit integer vector (C unsigned char) at index k.\nIf index is out of range it throw exception."},{"name":"bytevector?","doc":"(u8vector? x)\n\nReturns #t of argument is unsigned 8-bit integer vector (C unsigned char),\notherwise it return #f."},{"name":"caaaaar","doc":"(caaaaar arg)\n\nFunction that calculates (car (car (car (car (car arg)))))"},{"name":"caaaadr","doc":"(caaaadr arg)\n\nFunction that calculates (car (car (car (car (cdr arg)))))"},{"name":"caaaar","doc":"(caaaar arg)\n\nFunction that calculates (car (car (car (car arg))))"},{"name":"caaadar","doc":"(caaadar arg)\n\nFunction that calculates (car (car (car (cdr (car arg)))))"},{"name":"caaaddr","doc":"(caaaddr arg)\n\nFunction that calculates (car (car (car (cdr (cdr arg)))))"},{"name":"caaadr","doc":"(caaadr arg)\n\nFunction that calculates (car (car (car (cdr arg))))"},{"name":"caaar","doc":"(caaar arg)\n\nFunction that calculates (car (car (car arg)))"},{"name":"caadaar","doc":"(caadaar arg)\n\nFunction that calculates (car (car (cdr (car (car arg)))))"},{"name":"caadadr","doc":"(caadadr arg)\n\nFunction that calculates (car (car (cdr (car (cdr arg)))))"},{"name":"caadar","doc":"(caadar arg)\n\nFunction that calculates (car (car (cdr (car arg))))"},{"name":"caaddar","doc":"(caaddar arg)\n\nFunction that calculates (car (car (cdr (cdr (car arg)))))"},{"name":"caadddr","doc":"(caadddr arg)\n\nFunction that calculates (car (car (cdr (cdr (cdr arg)))))"},{"name":"caaddr","doc":"(caaddr arg)\n\nFunction that calculates (car (car (cdr (cdr arg))))"},{"name":"caadr","doc":"(caadr arg)\n\nFunction that calculates (car (car (cdr arg)))"},{"name":"caar","doc":"(caar arg)\n\nFunction that calculates (car (car arg))"},{"name":"cadaaar","doc":"(cadaaar arg)\n\nFunction that calculates (car (cdr (car (car (car arg)))))"},{"name":"cadaadr","doc":"(cadaadr arg)\n\nFunction that calculates (car (cdr (car (car (cdr arg)))))"},{"name":"cadaar","doc":"(cadaar arg)\n\nFunction that calculates (car (cdr (car (car arg))))"},{"name":"cadadar","doc":"(cadadar arg)\n\nFunction that calculates (car (cdr (car (cdr (car arg)))))"},{"name":"cadaddr","doc":"(cadaddr arg)\n\nFunction that calculates (car (cdr (car (cdr (cdr arg)))))"},{"name":"cadadr","doc":"(cadadr arg)\n\nFunction that calculates (car (cdr (car (cdr arg))))"},{"name":"cadar","doc":"(cadar arg)\n\nFunction that calculates (car (cdr (car arg)))"},{"name":"caddaar","doc":"(caddaar arg)\n\nFunction that calculates (car (cdr (cdr (car (car arg)))))"},{"name":"caddadr","doc":"(caddadr arg)\n\nFunction that calculates (car (cdr (cdr (car (cdr arg)))))"},{"name":"caddar","doc":"(caddar arg)\n\nFunction that calculates (car (cdr (cdr (car arg))))"},{"name":"cadddar","doc":"(cadddar arg)\n\nFunction that calculates (car (cdr (cdr (cdr (car arg)))))"},{"name":"caddddr","doc":"(caddddr arg)\n\nFunction that calculates (car (cdr (cdr (cdr (cdr arg)))))"},{"name":"cadddr","doc":"(cadddr arg)\n\nFunction that calculates (car (cdr (cdr (cdr arg))))"},{"name":"caddr","doc":"(caddr arg)\n\nFunction that calculates (car (cdr (cdr arg)))"},{"name":"cadr","doc":"(cadr arg)\n\nFunction that calculates (car (cdr arg))"},{"name":"call-with-current-continuation","doc":"(call/cc proc)\n\nCall-with-current-continuation.\n\nNOT SUPPORTED BY LIPS RIGHT NOW"},{"name":"call-with-input-file","doc":"(call-with-input-file filename proc)\n\nProcedure open file for reading, call user defined procedure with given port\nand then close the port. It return value that was returned by user proc\nand it close the port even if user proc throw exception."},{"name":"call-with-output-file","doc":"(call-with-output-file filename proc)\n\nProcedure open file for writing, call user defined procedure with port\nand then close the port. It return value that was returned by user proc\nand it close the port even if user proc throw exception."},{"name":"call-with-port","doc":"(call-with-port port proc)\n\nProc is executed with given port and after it returns, the port is closed."},{"name":"call-with-values","doc":"(call-with-values producer consumer)\n\nCalls the producer procedure with no arguments, then calls the\nconsumer procedure with the returned value as an argument -- unless\nthe returned value is a special Values object created by (values), if it is\nthe values are unpacked and the consumer is called with multiple arguments."},{"name":"call/cc","doc":"(call/cc proc)\n\nCall-with-current-continuation.\n\nNOT SUPPORTED BY LIPS RIGHT NOW"},{"name":"car","doc":"(car pair)\n\nThis function returns the car (item 1) of the list."},{"name":"cdaaaar","doc":"(cdaaaar arg)\n\nFunction that calculates (cdr (car (car (car (car arg)))))"},{"name":"cdaaadr","doc":"(cdaaadr arg)\n\nFunction that calculates (cdr (car (car (car (cdr arg)))))"},{"name":"cdaaar","doc":"(cdaaar arg)\n\nFunction that calculates (cdr (car (car (car arg))))"},{"name":"cdaadar","doc":"(cdaadar arg)\n\nFunction that calculates (cdr (car (car (cdr (car arg)))))"},{"name":"cdaaddr","doc":"(cdaaddr arg)\n\nFunction that calculates (cdr (car (car (cdr (cdr arg)))))"},{"name":"cdaadr","doc":"(cdaadr arg)\n\nFunction that calculates (cdr (car (car (cdr arg))))"},{"name":"cdaar","doc":"(cdaar arg)\n\nFunction that calculates (cdr (car (car arg)))"},{"name":"cdadaar","doc":"(cdadaar arg)\n\nFunction that calculates (cdr (car (cdr (car (car arg)))))"},{"name":"cdadadr","doc":"(cdadadr arg)\n\nFunction that calculates (cdr (car (cdr (car (cdr arg)))))"},{"name":"cdadar","doc":"(cdadar arg)\n\nFunction that calculates (cdr (car (cdr (car arg))))"},{"name":"cdaddar","doc":"(cdaddar arg)\n\nFunction that calculates (cdr (car (cdr (cdr (car arg)))))"},{"name":"cdadddr","doc":"(cdadddr arg)\n\nFunction that calculates (cdr (car (cdr (cdr (cdr arg)))))"},{"name":"cdaddr","doc":"(cdaddr arg)\n\nFunction that calculates (cdr (car (cdr (cdr arg))))"},{"name":"cdadr","doc":"(cdadr arg)\n\nFunction that calculates (cdr (car (cdr arg)))"},{"name":"cdar","doc":"(cdar arg)\n\nFunction that calculates (cdr (car arg))"},{"name":"cddaaar","doc":"(cddaaar arg)\n\nFunction that calculates (cdr (cdr (car (car (car arg)))))"},{"name":"cddaadr","doc":"(cddaadr arg)\n\nFunction that calculates (cdr (cdr (car (car (cdr arg)))))"},{"name":"cddaar","doc":"(cddaar arg)\n\nFunction that calculates (cdr (cdr (car (car arg))))"},{"name":"cddadar","doc":"(cddadar arg)\n\nFunction that calculates (cdr (cdr (car (cdr (car arg)))))"},{"name":"cddaddr","doc":"(cddaddr arg)\n\nFunction that calculates (cdr (cdr (car (cdr (cdr arg)))))"},{"name":"cddadr","doc":"(cddadr arg)\n\nFunction that calculates (cdr (cdr (car (cdr arg))))"},{"name":"cddar","doc":"(cddar arg)\n\nFunction that calculates (cdr (cdr (car arg)))"},{"name":"cdddaar","doc":"(cdddaar arg)\n\nFunction that calculates (cdr (cdr (cdr (car (car arg)))))"},{"name":"cdddadr","doc":"(cdddadr arg)\n\nFunction that calculates (cdr (cdr (cdr (car (cdr arg)))))"},{"name":"cdddar","doc":"(cdddar arg)\n\nFunction that calculates (cdr (cdr (cdr (car arg))))"},{"name":"cddddar","doc":"(cddddar arg)\n\nFunction that calculates (cdr (cdr (cdr (cdr (car arg)))))"},{"name":"cdddddr","doc":"(cdddddr arg)\n\nFunction that calculates (cdr (cdr (cdr (cdr (cdr arg)))))"},{"name":"cddddr","doc":"(cddddr arg)\n\nFunction that calculates (cdr (cdr (cdr (cdr arg))))"},{"name":"cdddr","doc":"(cdddr arg)\n\nFunction that calculates (cdr (cdr (cdr arg)))"},{"name":"cddr","doc":"(cddr arg)\n\nFunction that calculates (cdr (cdr arg))"},{"name":"cdr","doc":"(cdr pair)\n\nThis function returns the cdr (all but first) of the list."},{"name":"ceiling","doc":"(ceiling number)\n\nFunction that calculates the ceiling of a number."},{"name":"char->integer","doc":"(char->integer chr)\n\nReturns the codepoint of Unicode character."},{"name":"char-alphabetic?","doc":"(char-alphabetic? chr)\n\nReturns true if character is leter of the ASCII alphabet."},{"name":"char-ci<?","doc":"(char-ci<? chr1 chr2)\n\nReturns true if characters are monotonically increasing case insensitive."},{"name":"char-ci<=?","doc":"(char-ci<? chr1 chr2 ...)\n\nReturns true if characters are monotonically non-decreasing, case insensitive."},{"name":"char-ci=?","doc":"(char-ci=? chr1 chr2 ...)\n\nChecks if all characters are equal, case insensitive."},{"name":"char-ci>?","doc":"(char-ci<? chr1 chr2 ...)\n\nReturns true if characters are monotonically decreasing case insensitive."},{"name":"char-ci>=?","doc":"(char-ci<? chr1 chr2 ...)\n\nReturns true if characters are monotonically non-increasing, case insensitive."},{"name":"char-downcase","doc":"(char-downcase chr)\n\nCreate lowercase version of the character."},{"name":"char-foldcase","doc":"(char-foldcase char)\n\nReturns lowercase character using the Unicode simple case-folding algorithm."},{"name":"char-lower-case?","doc":"(char-upper-case? char)\n\nChecks if character is lower case."},{"name":"char-numeric?","doc":"(char-numeric? chr)\n\nReturns true if character is number."},{"name":"char-ready?","doc":"(char-ready?)\n(char-ready? port)\n\nChecks if characters is ready in input port. This is useful mostly\nfor interactive ports that return false if it would wait for user input.\nIt return false if port is closed."},{"name":"char-upcase","doc":"(char-upcase char)\n\nCreate uppercase version of the character."},{"name":"char-upper-case?","doc":"(char-upper-case? char)\n\nChecks if character is upper case."},{"name":"char-whitespace?","doc":"(char-whitespace? chr)\n\nReturns true if character is whitespace."},{"name":"char?","doc":"(char? obj)\n\nChecks if the object is a character."},{"name":"char<?","doc":"(char<? chr1 chr2 ...)\n\nReturns true if characters are monotonically increasing."},{"name":"char<=?","doc":"(char<? chr1 chr2 ...)\n\nReturns true if characters are monotonically non-decreasing."},{"name":"char=?","doc":"(char=? chr1 chr2 ...)\n\nChecks if all characters are equal."},{"name":"char>?","doc":"(char<? chr1 chr2 ...)\n\nReturns true if characters are monotonically decreasing."},{"name":"char>=?","doc":"(char<? chr1 chr2 ...)\n\nReturns true if characters are monotonically non-increasing."},{"name":"clone","doc":"(clone list)\n\nFunction that returns a clone of the list, that does not share any pairs with the\noriginal, so the clone can be safely mutated without affecting the original."},{"name":"close-input-port","doc":"(close-input-port port)\n\nProcedure close port that was opened with open-input-file. After that\nit no longer accept reading from that port."},{"name":"close-output-port","doc":"(close-output-port port)\n\nProcedure close port that was opened with open-output-file. After that\nit no longer accept write to that port."},{"name":"close-port","doc":"(close-port port)\n\nClose input or output port."},{"name":"command-line","doc":"(command-line)\n\nReturns the command line arguments, or an empty list if not running under Node.js."},{"name":"complement","doc":"(complement fn)\n\nHigher order function that returns the Boolean complement of the given function.\nIf the function fn for a given arguments return true the result function\nwill return false, if it would return false, the result function will return true."},{"name":"complex?","doc":"(complex? x)\n\nChecks if argument x is complex."},{"name":"compose","doc":"(compose . fns)\n\nHigher-order function that creates a new function that applies all functions\nfrom right to left and returns the last value. Reverse of pipe.\ne.g.:\n((compose (curry + 2) (curry * 3)) 10) ==> (+ 2 (* 3 10)) ==> 32"},{"name":"concat","doc":"(concat . strings)\n\nFunction that creates a new string by joining its arguments."},{"name":"cond","doc":"(cond (predicate? . body)\n      (predicate? . body))\n\n(cond (predicate? => procedure)\n      (predicate? => procedure))\n\nMacro for condition checks. For usage instead of nested ifs.\nYou can use predicate and any number of expressions. Or symbol =>\nFollowed by procedure that will be invoked with result\nof the predicate."},{"name":"cons","doc":"(cons left right)\n\nThis function returns a new list with the first appended\nbefore the second. If the second is not a list cons will\nreturn a dotted pair."},{"name":"constructor","doc":"(constructor)\n\nFunction that is present in JavaScript environment. We define it in Scheme\nto fix an issue with define-class. This function throw an error."},{"name":"continuation?","doc":"(continuation? expression)\n\nPredicate that tests if value is a callable continuation."},{"name":"cos","doc":"(cos n)\n\nFunction that calculates cosine of a number."},{"name":"current-directory","doc":"(current-directory)\n\nReturns the current working directory, default is the path from where\nthe script was executed."},{"name":"current-environment","doc":"(current-environment)\n\nFunction that returns the current environment (they're first-class objects!)"},{"name":"current-error-port","doc":"(current-output-port)\n\nReturns the default stderr port."},{"name":"current-input-port","doc":"(current-input-port)\n\nReturns the default stdin port."},{"name":"current-jiffy","doc":"(current-jiffy)\n\nReturn current jiffy. In LIPS is jiffy since start of the process.\nYou can divide this value by (jiffies-per-second) to get seconds since\nstart of the process. And you can add %%start-jiffy to get jiffy since\nJanuary 1, 1970."},{"name":"current-output-port","doc":"(current-output-port)\n\nReturns the default stdout port."},{"name":"current-second","doc":"(current-second)\n\nFunctionn return exact integer of the seconds since January 1, 1970"},{"name":"curry","doc":"(curry fn . args)\n\nHigher-order function that creates a curried version of the function.\nThe result function will have partially applied arguments and it\nwill keep returning one-argument functions until all arguments are provided,\nthen it calls the original function with the accumulated arguments.\n\ne.g.:\n(define (add a b c d) (+ a b c d))\n(define add1 (curry add 1))\n(define add12 (add 2))\n(display (add12 3 4))"},{"name":"debugger","doc":"(debugger)\n\nFunction that triggers the JavaScript debugger (e.g. the browser devtools)\nusing the \"debugger;\" statement. If a debugger is not running this\nfunction does nothing."},{"name":"define","doc":"(define name expression)\n(define name expression \"doc string\")\n(define (function-name . args) . body)\n\nMacro for defining values. It can be used to define variables,\nor functions. If the first argument is list it will create a function\nwith name being first element of the list. This form expands to\n`(define function-name (lambda args body))`"},{"name":"define-class","doc":"(define-class name parent . body)\n\nDefines a class - JavaScript function constructor with prototype.\n\nusage:\n\n  (define-class Person Object\n      (constructor (lambda (self name)\n                     (set-obj! self '_name name)))\n      (hi (lambda (self)\n            (display (string-append self._name \" says hi\"))\n            (newline))))\n  (define jack (new Person \"Jack\"))\n  (jack.hi) ; prints \"Jack says hi\""},{"name":"define-formatter-rule","doc":"(rule-pattern pattern)\n\nAnaphoric macro for defining patterns for the formatter.\nWith Ahead, Pattern and * defined values."},{"name":"define-global","doc":"(define-global var value)\n(define-global (name . args) body)\n\nDefines functions or variables in the global context, so they can be used\ninside let and get let variables in a closure. Useful for universal macros."},{"name":"define-library","doc":"(define-library (library (name namespace) . body)\n\nMacro for defining modules inside you can use define to create functions.\nAnd use export name to add that name to defined environment."},{"name":"define-macro","doc":"(define-macro (name . args) body)\n\nThe meta-macro, that creates new macros. If the return value is a list structure\nit will be evaluated where the macro is invoked from. You can use quasiquote `\nand unquote , and unquote-splicing ,@ inside to create an expression that will be\nevaluated at runtime. Macros works like this: if you pass any expression to a\nmacro the arguments will not be evaluated unless the macro's body explicitly\ncalls (eval) on it. Because of this a macro can manipulate the expression\n(arguments) as lists."},{"name":"define-record-type","doc":"(define-record-type name constructor pred . fields)\n\nMacro for defining records. Example of usage:\n\n(define-record-type <pare>\n  (kons x y)\n  pare?\n  (x kar set-kar!)\n  (y kdr set-kdr!))\n\n(define p (kons 1 2))\n(print (kar p))\n;; ==> 1\n(set-kdr! p 3)\n(print (kdr p))\n;; ==> 3"},{"name":"define-symbol-macro","doc":"(define-symbol-macro type (name . args) . body)\n\nCreates syntax extensions for evaluator similar to built-in , or `.\nIt's like an alias for a real macro. Similar to CL reader macros\nbut it receives already parsed code like normal macros. Type can be SPLICE\nor LITERAL symbols (see set-special!). ALL default symbol macros are literal."},{"name":"define-syntax","doc":"(define-syntax name expression [__doc__])\n\nDefines a new hygienic macro using syntax-rules with optional documentation."},{"name":"define-syntax-parameter","doc":"(define-syntax-parameter name syntax [__doc__])\n\nBinds <keyword> to the transformer obtained by evaluating <transformer spec>.\nThe transformer provides the default expansion for the syntax parameter,\nand in the absence of syntax-parameterize, is functionally equivalent to\ndefine-syntax."},{"name":"defmacro?","doc":"(defmacro? expression)\n\nChecks if object is a macro and it's expandable."},{"name":"degree->radians","doc":"(degree->radians x)\n\nConvert degrees to radians."},{"name":"delay","doc":"(delay expression)\n\nWill create a promise from expression that can be forced with (force)."},{"name":"delete-file","doc":"(delete-file filename)\n\nDeletes the file of given name."},{"name":"denominator","doc":"(denominator n)\n\nReturn denominator of rational or same number if one is not rational."},{"name":"digit-value","doc":"(digit-value chr)\n\nReturn digit number if character is numeral (as per char-numeric?)\nor #f otherwise."},{"name":"dir","doc":"(dir obj)\n\nReturns all props on the object including those in prototype chain."},{"name":"display","doc":"(display string [port])\n\nThis function outputs the string to the standard output or\nthe port if given. No newline."},{"name":"display-error","doc":"(display-error . args)\n\nDisplay an error message on stderr."},{"name":"do","doc":"(do ((<var> <init> <next>)) (test return) . body)\n\nIteration macro that evaluates the expression body in scope of the variables.\nOn each loop it changes the variables according to the <next> expression and runs\ntest to check if the loop should continue. If test is a single value, the macro\nwill return undefined. If the test is a pair of expressions the macro will\nevaluate and return the second expression after the loop exits."},{"name":"do-iterator","doc":"(do-iterator (var expr) (test result) body ...)\n\nIterates over iterators (e.g. created with JavaScript generator function)\nthat works with normal and async iterators. You can loop over an infinite\niterators and break the loop if you want, using expression like in do macro.\nLong synchronous iterators will block the main thread (you can't print\n1000 numbers from infinite iterators, because it will freeze the browser),\nbut if you use async iterators you can process the values as they are\ngenerated."},{"name":"drop","doc":"(take list n)\n\nReturns a list where first n elements are removed."},{"name":"dynamic-wind","doc":"(dynamic-wind before thunk after)\n\nAccepts 3 procedures/lambdas and executes before, then thunk, and\nalways after even if an error occurs in thunk."},{"name":"empty?","doc":"(empty? object)\n\nFunction that returns #t if value is nil (an empty list) or undefined."},{"name":"env","doc":"(env)\n(env obj)\n\nFunction that returns a list of names (functions, macros and variables)\nthat are bound in the current environment or one of its parents."},{"name":"environment-bound?","doc":"(environment-bound? env symbol)\n\nChecks if symbol is a bound variable similar to bound?."},{"name":"environment?","doc":"(environment? obj)\n\nChecks if object is a LIPS environment."},{"name":"eof-object","doc":"(eof-object)\n\nProcedure returns eof object that indicate end of the port"},{"name":"eof-object?","doc":"(eof-object? arg)\n\nChecks if value is eof object, returned from input string\nport when there are no more data to read."},{"name":"eq?","doc":"(eq? a b)\n\nFunction that compares two values if they are identical."},{"name":"equal?","doc":"(equal? a b)\n\nThe function checks if values are equal. If both are a pair or an array\nit compares their elements recursively. If pairs have cycles it compares\nthem with eq?"},{"name":"eqv?","doc":"(eqv? a b)\n\nFunction that compares the values. It returns true if they are the same, they\nneed to have the same type."},{"name":"error","doc":"(error message ...)\n\nFunction raises error with given message and arguments,\nwhich are called invariants."},{"name":"error-object-irritants","doc":"(error-object-irritants error-object)\n\nReturns a list of the irritants encapsulated by error-object."},{"name":"error-object-message","doc":"(error-object-message error-object)\n\nReturns the message encapsulated by error-object."},{"name":"error-object?","doc":"(error-object? obj)\n\nChecks if object is of Error object thrown by error function."},{"name":"escape-regex","doc":"(escape-regex string)\n\nFunction that returns a new string where all special operators used in regex,\nare escaped with backslashes so they can be used in the RegExp constructor\nto match a literal string."},{"name":"eval","doc":"(eval expr)\n(eval expr environment)\n\nFunction that evaluates LIPS Scheme code. If the second argument is provided\nit will be the environment that the code is evaluated in."},{"name":"even?","doc":"(even? number)\n\nChecks if number is even."},{"name":"every","doc":"(every fn list)\n\nFunction that calls fn on each item of the list, if every value returns true\nit will return true otherwise it return false.\nAnalogous to Python all(map(fn, list))."},{"name":"exact","doc":"(inexact->exact number)\n\nFunction that converts real number to exact rational number."},{"name":"exact->inexact","doc":"(exact->inexact n)\n\nConvert exact number to inexact."},{"name":"exact-integer?","doc":"(exact-integer? n)\n\nReturns #t if z is both exact and an integer; otherwise\nreturns #f."},{"name":"exact?","doc":"(exact? n)"},{"name":"exp","doc":"(exp n)\n\nFunction that calculates e raised to the power of n."},{"name":"expt","doc":"(** a b)\n\nFunction that calculates number a to to the power of b."},{"name":"f32vector","doc":"(f32vector v1 v2 ...)\n\nCreate 32-bit IEEE-754 floating point number vector (C float) from give arguments."},{"name":"f32vector-length","doc":"(f32vector-length v)\n\nreturn length of 32-bit IEEE-754 floating point number vector (C float)."},{"name":"f32vector-ref","doc":"(f32vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"f32vector-set!","doc":"(f32vector-set! vector k)\n\nFunction set value of 32-bit IEEE-754 floating point number vector (C float) at index k.\nIf index is out of range it throw exception."},{"name":"f32vector?","doc":"(f32vector? x)\n\nReturns #t of argument is 32-bit IEEE-754 floating point number vector (C float),\notherwise it return #f."},{"name":"f64vector","doc":"(f64vector v1 v2 ...)\n\nCreate 64-bit IEEE-754 floating point number vector (C double) from give arguments."},{"name":"f64vector-length","doc":"(f64vector-length v)\n\nreturn length of 64-bit IEEE-754 floating point number vector (C double)."},{"name":"f64vector-ref","doc":"(f64vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"f64vector-set!","doc":"(f64vector-set! vector k)\n\nFunction set value of 64-bit IEEE-754 floating point number vector (C double) at index k.\nIf index is out of range it throw exception."},{"name":"f64vector?","doc":"(f64vector? x)\n\nReturns #t of argument is 64-bit IEEE-754 floating point number vector (C double),\notherwise it return #f."},{"name":"features","doc":"(features)\n\nFunction returns implemented features as a list."},{"name":"filter","doc":"(filter fn list)\n(filter regex list)\n\nHigher-order function that calls `fn` for each element of the list\nand return a new list for only those elements for which fn returns\na truthy value. If called with a regex it will create a matcher function."},{"name":"find","doc":"(find fn list)\n(find regex list)\n\nHigher-order function that finds the first value for which fn return true.\nIf called with a regex it will create a matcher function."},{"name":"finite?","doc":"(finite? x)\n\nChecks if value is finite."},{"name":"flatten","doc":"(flatten list)\n\nReturns a shallow list from tree structure (pairs)."},{"name":"flip","doc":"(flip fn)\n\nHigher-order function that returns a new function where the first two arguments\nare swapped.\n\nExample:\n\n  (define first (curry (flip vector-ref) 0))\n  (first #(1 2 3))\n  ;; ==> 1"},{"name":"floor","doc":"(floor number)\n\nFunction that calculates the floor of a number."},{"name":"flush-output","doc":"(flush-output [port])\n\nIf output-port is buffered, this causes the contents of its buffer to be written to\nthe output device. Otherwise it has no effect. Returns an unspecified value."},{"name":"flush-output-port","doc":"(flush-output-port port)\n\nFunction do nothing, flush is not needed in LIPS in both NodeJS and Browser.\nThe function is added, so it don't throw exception when using R7RS code."},{"name":"fold","doc":"(fold fn init . lists)\n\nFunction fold is left-to-right reversal of reduce. It call `fn`\non each pair of elements of the list and returns a single value.\ne.g. it computes (fn 'a 'x (fn 'b 'y (fn 'c 'z 'foo)))\nfor: (fold fn 'foo '(a b c) '(x y z))"},{"name":"fold-left","doc":"(fold fn init . lists)\n\nFunction fold is left-to-right reversal of reduce. It call `fn`\non each pair of elements of the list and returns a single value.\ne.g. it computes (fn 'a 'x (fn 'b 'y (fn 'c 'z 'foo)))\nfor: (fold fn 'foo '(a b c) '(x y z))"},{"name":"fold-right","doc":"(reduce fn init list . lists)\n\nHigher-order function that takes each element of the list and calls\nthe fn with result of previous call or init and the next element\nof the list until each element is processed, and returns a single value\nas result of last call to `fn` function.\ne.g. it computes (fn 'c 'z (fn 'b 'y (fn 'a 'x 'foo)))\nfor: (reduce fn 'foo '(a b c) '(x y z))"},{"name":"for-each","doc":"(for-each fn . lists)\n\nHigher-order function that calls function `fn` on each\nvalue of the argument. If you provide more than one list\nit will take each value from each list and call `fn` function\nwith that many arguments as number of list arguments."},{"name":"force","doc":"(force promise)\n\nFunction that forces the promise and evaluates the delayed expression."},{"name":"format","doc":"(format string n1 n2 ...)\n\nThis function accepts a string template and replaces any\nescape sequences in its inputs:\n\n* ~a value as if printed with `display`\n* ~s value as if printed with `write`\n* ~% newline character\n* ~~ literal tilde '~'\n\nIf there are missing inputs or other escape characters it\nwill error."},{"name":"function?","doc":"(function? expression)\n\nPredicate that tests if value is a callable function."},{"name":"gcd","doc":"(gcd n1 n2 ...)\n\nFunction that returns the greatest common divisor of the arguments."},{"name":"gensym","doc":"(gensym)\n\nGenerates a unique symbol that is not bound anywhere,\nto use with macros as meta name."},{"name":"gensym-interal","doc":"(gensym-interal symbol)\n\nParser extension that creates a new quoted named gensym."},{"name":"gensym?","doc":"(gensym? value)\n\nReturns #t if value is a symbol created by gensym. It returns #f otherwise."},{"name":"get","doc":"(. obj . args)\n(get obj . args)\n\nThis function uses an object as a base and keeps using arguments to get the\nproperty of JavaScript object. Arguments need to be a strings.\ne.g. `(. console \"log\")` if you use any function inside LIPS it\nwill be weakly bound (can be rebound), so you can call this log function\nwithout problem unlike in JavaScript when you use\n`var log = console.log`.\n`get` is an alias because . doesn't work everywhere, e.g. you can't\npass it as an argument."},{"name":"get-environment-variable","doc":"(get-environment-variable name)\n\nReturns given environment variable. This function returns #void\nwhen called in the browser."},{"name":"get-environment-variables","doc":"(get-environment-variables)\n\nReturns all process environment variables as an alist. This function returns\nan empty list when called in the browser."},{"name":"get-output-bytevector","doc":"(get-output-string port)\n\nGets full string from string port. If nothing was wrote\nto given port it will return empty string."},{"name":"get-output-string","doc":"(get-output-string port)\n\nGets full string from string port. If nothing was wrote\nto given port it will return empty string."},{"name":"get-resource","doc":"(get-resource url)\n\nLoad JavaScript or CSS file in browser by adding script/link tag to head\nof the current document. When called from Node it allow it allows to load\nJavaScript files only."},{"name":"globalize","doc":"(globalize expr)\n\n Macro will get the value of the expression and add each method as function\n to global scope."},{"name":"help","doc":"(help object)\n\nThis macro returns documentation for a function or macro.\nYou can save the function or macro in a variable and use it\nhere. But getting help for a variable requires passing the\nvariable in a `quote`."},{"name":"http-get","doc":"(http-get url)\n\nNode.js function that sends a HTTP Request and returns a string or\nbinary Buffer object."},{"name":"identity","doc":"(identity n)\n\nNo-op function. It just returns its argument."},{"name":"if","doc":"(if cond true-expr false-expr)\n\nMacro that evaluates cond expression and if the value is true, it\nevaluates and returns true-expression, if not it evaluates and returns\nfalse-expression."},{"name":"ignore","doc":"(ignore . body)\n\nMacro that will evaluate the expression and swallow any promises that may\nbe created. It will discard any value that may be returned by the last body\nexpression. The code should have side effects and/or when it's promise\nit should resolve to undefined."},{"name":"imag-part","doc":"(imag-part n)\n\nReturn imaginary part of the complex number n."},{"name":"import","doc":"(import (library namespace))\n(import (only (library namespace) name1 name2))\n\nMacro for importing names from library."},{"name":"in","doc":"(in key value)\n\nFunction that uses the Javascript \"in\" operator to check if key is\na valid property in the value."},{"name":"include","doc":"(include file ...)\n\nLoad at least one file content and insert them into one,\nbody expression."},{"name":"indexed-db?","doc":"(indexed-db?)\n\nFunction that tests if IndexedDB is available."},{"name":"inexact","doc":"(exact->inexact n)\n\nConvert exact number to inexact."},{"name":"inexact->exact","doc":"(inexact->exact number)\n\nFunction that converts real number to exact rational number."},{"name":"inexact?","doc":"(inexact? n)"},{"name":"infinite?","doc":"(infinite? x)\n\nChecks if value is infinite."},{"name":"input-port-open?","doc":"(input-port-open? port)\n\nChecks if argument is input-port and if you can read from it."},{"name":"input-port?","doc":"(input-port? arg)\n\nReturns true if argument is input port."},{"name":"instance?","doc":"(instance? obj)\n\nChecks if object is an instance, created with a new operator"},{"name":"instanceof","doc":"(instanceof type obj)\n\nPredicate that tests if the obj is an instance of type."},{"name":"integer->char","doc":"(integer->char chr)\n\nFunction that converts number argument to character."},{"name":"integer?","doc":"(integer? x)\n\nChecks if the argument x is integer."},{"name":"interaction-environment","doc":"(interaction-environment)\n\nReturns the interaction environment equal to lips.env. This can be overwritten\nwhen creating new interpreter with lips.Interpreter."},{"name":"iterator->array","doc":"(iterator->array object)\n\nReturn array from JavaScript iterator object."},{"name":"iterator?","doc":"(iterator? x)\n\n Checks if value is JavaScript iterator object."},{"name":"join","doc":"(join separator list)\n\nFunction that returns a string by joining elements of the list using separator."},{"name":"key->string","doc":"(key->string symbol)\n\nIf symbol is a keyword it converts that to string and removes the colon."},{"name":"key?","doc":"(key? symbol)\n\nChecks if symbol is a keyword (has a colon as first character)."},{"name":"lambda","doc":"(lambda (a b) body)\n(lambda args body)\n(lambda (a b . rest) body)\n\nThe lambda macro creates a new anonymous function. If the first element of\nthe body is a string and there is more elements the string is used as the\ndocumentation string, that can be read using (help fn)."},{"name":"lcm","doc":"(lcm n1 n2 ...)\n\nFunction that returns the least common multiple of the arguments."},{"name":"length","doc":"(length expression)\n\nFunction that returns the length of the object. The object can be a LIPS\nlist or any object that has a \"length\" property. Returns undefined if the\nlength could not be found."},{"name":"let","doc":"(let ((a value-a) (b value-b) ...) . body)\n\nMacro that creates a new environment, then evaluates and assigns values to names,\nand then evaluates the body in context of that environment.  Values are evaluated\nsequentially but you can't access previous values/names when the next are\nevaluated. You can only get them in the body of the let expression.  (If you want\nto define multiple variables and use them in each other's definitions, use\n`let*`.)"},{"name":"let-env","doc":"(let-env env . body)\n\nSpecial macro that evaluates body in context of given environment\nobject."},{"name":"let-env-values","doc":"(let-env-values env ((name var)) . body)\n\nAdds mappings for variables var from specified env.\nit is similar to let-env but lexical scope is working with it."},{"name":"let-syntax","doc":"(let-syntax ((name fn) ...) . body)\n\n Works like a combination of let and define-syntax. It creates\n local macros and evaluates body in context of those macros.\n The macro to letrec-syntax is like letrec is to let."},{"name":"let*","doc":"(let* ((a value-a) (b value-b) ...) . body)\n\nMacro similar to `let`, but the subsequent bindings after the first\nare evaluated in the environment including the previous let variables,\nso you can define one variable, and use it in the next's definition."},{"name":"letrec","doc":"(letrec ((a value-a) (b value-b) ...) . body)\n\nMacro that creates a new environment, then evaluates and assigns values to\nnames and then evaluates the body in context of that environment.\nValues are evaluated sequentially and the next value can access the\nprevious values/names."},{"name":"letrec-syntax","doc":"(letrec-syntax ((name fn) ...) . body)\n\n Works like a combination of letrec and define-syntax. It creates\n local macros and evaluates the body in context of those macros."},{"name":"letrec*","doc":"(letrec* ((a value-a) (b value-b) ...) . body)\n\nSame as letrec but the order of execution of the binding is guaranteed,\nso you can use recursive code as well as referencing the previous binding.\n\nIn LIPS both letrec and letrec* behave the same."},{"name":"list","doc":"(list . args)\n\nFunction that creates a new list out of its arguments."},{"name":"list->array","doc":"(list->array list)\n\nFunction that converts a LIPS list into a JavaScript array."},{"name":"list->string","doc":"(list->string _list)\n\nReturns a string from a list of characters."},{"name":"list->vector","doc":"(list->array list)\n\nFunction that converts a LIPS list into a JavaScript array."},{"name":"list-copy","doc":"(list-copy obj)\n\nCopy the object passed as argument but only if it's list. The car elements\nof the list are not copied, they are passed as is."},{"name":"list-match?","doc":"(list-match? predicate list)\n\nChecks if consecutive elements of the list match the predicate function."},{"name":"list-ref","doc":"(list-ref list n)\n\nReturns n-th element of a list."},{"name":"list-set!","doc":"(list-set! list n)\n\nReturns n-th element of a list."},{"name":"list-tail","doc":"(list-tail list k)\n\nReturns the sublist of list obtained by omitting the first k elements."},{"name":"list?","doc":"(list? obj)\n\nPredicate that tests if value is a proper linked list structure.\nThe car of each pair can be any value. It returns false on cyclic lists.\""},{"name":"list*","doc":"(list* arg1 ...)\n\nParallel asynchronous version of list. Like begin* except all values\nare returned in a list."},{"name":"load","doc":"(load filename)\n(load filename environment)\n\nFetches the file (from disk or network) and evaluates its content as LIPS code.\nIf the second argument is provided and it's an environment the evaluation\nwill happen in that environment."},{"name":"log","doc":"(log z)\n(log z1 z2)\n\nFunction that calculates natural logarithm (base e) of z. Where the argument\ncan be any number (including complex negative and rational). If the value is 0\nit returns NaN. It two arguments are provided it will calculate logarithm\nof z1 with given base z2."},{"name":"macro?","doc":"(macro? expression)\n\nPredicate that tests if value is a macro."},{"name":"macroexpand","doc":"(macroexpand expr)\n\nMacro that expand all macros inside and return single expression as output."},{"name":"macroexpand-1","doc":"(macroexpand-1 expr)\n\nMacro similar to macroexpand but it expand macros only one level\nand return single expression as output."},{"name":"magnitude","doc":"(magnitude x)\n\nReturns magnitude of the complex number in polar coordinate system."},{"name":"make-bytevector","doc":"(make-u8vector k fill)\n\nAllocate new unsigned 8-bit integer vector (C unsigned char) of length k,\nwith optional initial values."},{"name":"make-f32vector","doc":"(make-f32vector k fill)\n\nAllocate new 32-bit IEEE-754 floating point number vector (C float) of length k,\nwith optional initial values."},{"name":"make-f64vector","doc":"(make-f64vector k fill)\n\nAllocate new 64-bit IEEE-754 floating point number vector (C double) of length k,\nwith optional initial values."},{"name":"make-parameter","doc":"(make-parameter init converter)\n\nFunction creates new dynamic variable that can be custimized with parameterize\nmacro. The value should be assigned to a variable e.g.:\n\n(define radix (make-parameter 10))\n\nThe result value is a procedure that return the value of dynamic variable."},{"name":"make-polar","doc":"(make-polar magnitude angle)\n\nCreate new complex number from polar parameters."},{"name":"make-promise","doc":"(make-promise fn)\n\nFunction that creates a promise from a function."},{"name":"make-rectangular","doc":"(make-rectangular im re)\n\nCreates a complex number from imaginary and real part (a+bi form)."},{"name":"make-s16vector","doc":"(make-s16vector k fill)\n\nAllocate new signed 16-bit integer vector (C short) of length k,\nwith optional initial values."},{"name":"make-s32vector","doc":"(make-s32vector k fill)\n\nAllocate new signed 32-bit integer vector (C unsigned int) of length k,\nwith optional initial values."},{"name":"make-s8vector","doc":"(make-s8vector k fill)\n\nAllocate new signed 8-bit integer vector (C signed char) of length k,\nwith optional initial values."},{"name":"make-string","doc":"(make-string k [char])\n\nReturns new string with k elements. If char is provided\nit's filled with that character."},{"name":"make-tags","doc":"(make-tags expression)\n\nReturns a list structure of code with better syntax then raw LIPS"},{"name":"make-u16vector","doc":"(make-u16vector k fill)\n\nAllocate new unsigned 16-bit integer vector (C unsigned short) of length k,\nwith optional initial values."},{"name":"make-u32vector","doc":"(make-u32vector k fill)\n\nAllocate new unsigned 32-bit integer vector (C int) of length k,\nwith optional initial values."},{"name":"make-u8vector","doc":"(make-u8vector k fill)\n\nAllocate new unsigned 8-bit integer vector (C unsigned char) of length k,\nwith optional initial values."},{"name":"make-vector","doc":"(make-vector n [fill])\n\nCreates a new vector with n empty elements. If fill is specified it will set\nall elements of the vector to that value."},{"name":"map","doc":"(map fn . lists)\n\nHigher-order function that calls function `fn` with each\nvalue of the list. If you provide more then one list as argument\nit will take each value from each list and call `fn` function\nwith that many argument as number of list arguments. The return\nvalues of the fn calls are accumulated in a result list and\nreturned by map."},{"name":"match","doc":"(match pattern string)\n\nFunction that returns a match object from JavaScript as a list or #f if\nno match."},{"name":"max","doc":"(max n1 n2 ...)\n\nReturns the maximum of its arguments."},{"name":"member","doc":"(member obj list)\n\nReturns first object in the list that match using equal? function."},{"name":"memq","doc":"(memq obj list)\n\nReturns first object in the list that match using eq? function."},{"name":"memv","doc":"(memv obj list)\n\nReturns first object in the list that match using eqv? function."},{"name":"min","doc":"(min n1 n2 ...)\n\nReturns the minimum of its arguments."},{"name":"modulo","doc":"(modulo a b)\n\nReturns modulo operation on its argumennts."},{"name":"n-ary","doc":"(n-ary n fn)\n\nReturns a new function that limits the number of arguments to n."},{"name":"nan?","doc":"(nan? x)\n\nChecks if argument x is Not a Number (NaN) value."},{"name":"native-symbol?","doc":"(native-symbol? object)\n\nChecks if value is JavaScript Symbol."},{"name":"native.number","doc":"(native.number obj)\n\nIf argument is a number it will convert it to a native number."},{"name":"negative?","doc":"(negative? x)\n\nChecks if the number is smaller then 0"},{"name":"new","doc":"(new obj . args)\n\nFunction that creates new JavaScript instance of an object."},{"name":"new-library","doc":"(new-library name)\n\nCreate new empty library object with empty namespace."},{"name":"newline","doc":"(newline [port])\n\nWrite newline character to standard output or given port"},{"name":"not","doc":"(not x)\n\nReturns true if value is false and false otherwise."},{"name":"nth","doc":"(nth index obj)\n\nFunction that returns the nth element of the list or array.\nIf used with a non-indexable value it will error."},{"name":"nth-pair","doc":"(nth-pair list n)\n\nReturns nth pair of a list."},{"name":"null-environment","doc":"(null-environment)\n\nReturns a clean environment with only the standard library."},{"name":"null?","doc":"(null? expression)\n\nPredicate that tests if value is null-ish (i.e. undefined, nil, or\nJavascript null)."},{"name":"number->string","doc":"(number->string x [radix])\n\nFunction that converts number to string with optional radix (number base)."},{"name":"number?","doc":"(number? expression)\n\nPredicate that tests if value is a number or NaN value."},{"name":"numerator","doc":"(numerator n)\n\nReturn numerator of rational or same number if n is not rational."},{"name":"object","doc":"(object :name value)\n\nCreates a JavaScript object using key like syntax."},{"name":"object->alist","doc":"(object->alist object)\n\nFunction that converts a JavaScript object to Alist"},{"name":"object-literal","doc":"(object-literal :name value)\n\nCreates a JavaScript object using key like syntax. This is similar,\nto object but all values are quoted. This macro is used by the & object literal."},{"name":"object?","doc":"(object? expression)\n\nPredicate that tests if value is an plain object (not another LIPS type)."},{"name":"odd?","doc":"(odd? number)\n\nChecks if number is odd."},{"name":"once","doc":"(once fn)\n\nHigher-order function that returns a new function, that only calls the original\non the first invocation, and immediately returns the first call's result again\non subsequent invocations."},{"name":"open-binary-input-file","doc":"(open-binary-input-file filename)\n\nReturns new Input Binary Port with given filename. In Browser\nuser need to provide global fs variable that is instance of FS interface."},{"name":"open-binary-output-file","doc":"(open-binary-output-file filename)\n\nOpens file and return port that can be used for writing. If file\nexists it will throw an Error."},{"name":"open-input-bytevector","doc":"(open-input-bytevector bytevector)\n\nCreate new input binary port with given bytevector"},{"name":"open-input-file","doc":"(open-input-file filename)\n\nReturns new Input Port with given filename. In Browser user need to\nprovide global fs variable that is instance of FS interface."},{"name":"open-input-string","doc":"(open-input-string string)\n\nCreates new string port as input that can be used to\nread S-exressions from this port using `read` function."},{"name":"open-output-bytevector","doc":"(open-output-bytevector)\n\nCreate new output port that can be used to write binary data.\nAfter done with the data the output buffer can be obtained by calling\n`get-output-bytevector` function."},{"name":"open-output-file","doc":"(open-output-file filename)\n\nFunction that opens file and return port that can be used for writing. If file\nexists it will throw an Error."},{"name":"open-output-string","doc":"(open-output-string)\n\nCreates new output port that can used to write string into\nand after finish get the whole string using `get-output-string`."},{"name":"or","doc":"(or . expressions)\n\nMacro that executes the values one by one and returns the first that is\na truthy value. If there are no expressions that evaluate to true it\nreturns false."},{"name":"output-port-open?","doc":"(output-port-open? port)\n\nChecks if argument is output-port and if you can write to it."},{"name":"output-port?","doc":"(output-port? arg)\n\nReturns true if argument is output port."},{"name":"pair-map","doc":"(pair-map fn list)\n\nFunction that calls fn argument for pairs in a list and returns a combined list\nwith values returned from function fn. It works likes map but take two items\nfrom the list each time."},{"name":"pair?","doc":"(pair? expression)\n\nPredicate that tests if value is a pair or list structure."},{"name":"parameterize","doc":"(parameterize ((name value) ...)\n\nMacro that change the dynamic variable created by make-parameter."},{"name":"parent.frame","doc":"(parent.frame)\n\nReturns the parent environment if called from inside a function.\nIf no parent frame can be found it returns nil."},{"name":"parent.frames","doc":"(parent.frames)\n\nReturns the list of environments from parent frames (lambda function calls)"},{"name":"peek-char","doc":"(peek-char port)\n\nThis function reads and returns a character from the string\nport, or, if there is no more data in the string port, it\nreturns an EOF."},{"name":"peek-u8","doc":"(peek-u8)\n(peek-u8 port)\n\nReturn next byte from input-binary port. If there are no more bytes\nit return eof object."},{"name":"pipe","doc":"(pipe . fns)\n\nHigher-order function that creates a new function that applies all functions\nfrom left to right and returns the last value. Reverse of compose.\ne.g.:\n((pipe (curry + 2) (curry * 3)) 10) ==> (* 3 (+ 2 10)) ==> 36"},{"name":"plain-object?","doc":"(plain-object? x)\n\nChecks if value is a plain JavaScript object created using the object macro."},{"name":"pluck","doc":"(pluck . strings)\n\nIf called with a single string it will return a function that when\ncalled with an object will return that key from the object.\nIf called with more then one string the returned function will\ncreate a new object by copying all properties from the given object."},{"name":"port?","doc":"(port? x)\n\nReturns true if the argument is an input or output port object."},{"name":"positive?","doc":"(positive? x)\n\nChecks if the number is larger then 0"},{"name":"pprint","doc":"(pprint expression)\n\nThis function will pretty print its input to stdout. If it is called\nwith a non-list, it will just call the print function on its\ninput."},{"name":"pretty-format","doc":"(pretty-format pair)\n\nReturns a pretty printed string from pair expression."},{"name":"print","doc":"(print . args)\n\nThis function converts each input into a string and prints\nthe result to the standard output (by default it's the\nconsole but it can be defined in user code). This function\ncalls `(newline)` after printing each input."},{"name":"procedure?","doc":"(procedure? expression)\n\nPredicate that tests if value is a callable function or continuation."},{"name":"promise","doc":"(promise . body)\n\nAnaphoric macro that exposes resolve and reject functions from JS promise."},{"name":"promise?","doc":"(promise? obj)\n\nChecks if the value is a promise created with delay or make-promise."},{"name":"promisify","doc":"(promisify fn)\n\nSimple function for adding promises to NodeJS two-callback based functions.\nFunction tested only with fs module."},{"name":"prototype?","doc":"(prototype? obj)\n\nPredicate that tests if value is a valid JavaScript prototype,\ni.e. calling (new) with it will not throw '<x> is not a constructor'."},{"name":"qsort","doc":"(qsort list predicate)\n\nSorts the list using the quick sort algorithm according to predicate."},{"name":"quasiquote","doc":"(quasiquote list)\n\nSimilar macro to `quote` but inside it you can use special expressions (unquote\nx) abbreviated to ,x that will evaluate x and insert its value verbatim or\n(unquote-splicing x) abbreviated to ,@x that will evaluate x and splice the value\ninto the result. Best used with macros but it can be used outside."},{"name":"quote","doc":"(quote expression) or 'expression\n\nMacro that returns a single LIPS expression as data (it won't evaluate the\nargument). It will return a list if put in front of LIPS code.\nAnd if put in front of a symbol it will return the symbol itself, not the value\nbound to that name."},{"name":"quote-promise","doc":"(quote-promise expr) or '>expr\n\nMacro used to escape automati awaiting of the expression. It will be wrapped\nwith a JavaScript class that behaves like Promise but will not be automatically\nresolved by LIPS like normal promises are."},{"name":"quoted-symbol?","doc":"(quoted-symbol? code)\n\nHelper function that tests if value is a quoted symbol. To be used in macros\nthat pass literal code that is transformed by parser.\n\nusage:\n\n  (define-macro (test x)\n     (if (quoted-symbol? x)\n         `',(cadr x)))\n\n  (list 'hello (test 'world))"},{"name":"quotient","doc":"(quotient a b)\n\nReturn quotient from division as integer."},{"name":"radians->degree","doc":"(radians->degree x)\n\nConvert radians to degrees."},{"name":"raise","doc":"(raise obj)\n\nThrows the object verbatim (no wrapping an a new Error)."},{"name":"random","doc":"(random)\n(random seed)\n\nFunction that generates new random real number using Knuth algorithm."},{"name":"range","doc":"(range stop)\n(range start stop)\n(range start stop step)\n\nReturns a list of numbers from start to stop with optional step.\nIf start is not defined it starts from 0. If start is larger than stop\nthe step needs to be negative otherwise it will hang in an infinite loop."},{"name":"rational?","doc":"(rational? x)\n\nChecks if the value is rational."},{"name":"rationalize","doc":"(rationalize number tolerance)\n\nReturns simplest rational number approximation differing from number by no more\nthan the tolerance."},{"name":"read","doc":"(read [port])\n\nThis function, if called with a port, it will parse the next\nitem from the port. If called without an input, it will read\na string from standard input (using the browser's prompt or\na user defined input method) and parse it. This function can be\nused together with `eval` to evaluate code from port."},{"name":"read-all","doc":"(read-all)\n(read-all port)\n\nRead all S-Expressions from port and return them as a list"},{"name":"read-bytevector","doc":"(read-bytevector k)\n(read-bytevector k port)\n\nRead next n bytes from input-binary port. If there are no more bytes\nit returns eof object. If there are less then n bytes in port it\nreturn the only bytes that are available"},{"name":"read-bytevector!","doc":"(read-bytevector! bytevector)\n(read-bytevector! bytevector port)\n(read-bytevector! bytevector port start)\n(read-bytevector! bytevector port start end)\n\nReads next bytes from binary input port and write them into byte vector.\nif not start is specified it start to write into 0 position of the vector until\nthe end or end the vector if no end is specified."},{"name":"read-char","doc":"(read-char port)\n\nThis function reads and returns the next character from the\ninput port."},{"name":"read-line","doc":"(read-line port)\n\nThis function reads and returns the next line from the input\nport."},{"name":"read-string","doc":"(read-string k)\n(read-string k port)\n\nReads the next k characters, or as many as are available\nbefore the end of file, from the textual input port into a\nnewly allocated string in left-to-right order and returns the\nstring. If no characters are available before the end of file,\nan end-of-file object is returned."},{"name":"read-u8","doc":"(read-u8)\n(read-u8 port)\n\nRead next byte from input-binary port. If there are no more bytes\nit return eof object."},{"name":"real-part","doc":"(real-part n)\n\nReturn real part of the complex number n."},{"name":"real?","doc":"(real? x)\n\nChecks if the argument x is real."},{"name":"reduce","doc":"(reduce fn init list . lists)\n\nHigher-order function that takes each element of the list and calls\nthe fn with result of previous call or init and the next element\nof the list until each element is processed, and returns a single value\nas result of last call to `fn` function.\ne.g. it computes (fn 'c 'z (fn 'b 'y (fn 'a 'x 'foo)))\nfor: (reduce fn 'foo '(a b c) '(x y z))"},{"name":"regex","doc":"(regex re)\n\nCreates a new regular expression from string, to not break Emacs formatting."},{"name":"regex?","doc":"(regex? x)\n\nReturns true if value is a regular expression, or false otherwise."},{"name":"remainder","doc":"(% n1 n2)\n\nFunction returns the remainder of n1/n2 (modulo)."},{"name":"remainder__","doc":"(modulo a b)\n\nReturns remainder from division operation."},{"name":"replace","doc":"(replace pattern replacement string)\n\nFunction that changes pattern to replacement inside string. Pattern can be a\nstring or regex and replacement can be function or string. See Javascript\nString.replace()."},{"name":"repr","doc":"(repr obj)\n\nFunction that returns a LIPS code representation of the object as a string."},{"name":"require","doc":"(require module)\n\nFunction used inside Node.js to import a module."},{"name":"require.resolve","doc":"(require.resolve path)\n\nReturns the path relative to the current module.\n\nOnly available when LIPS is running under Node.js."},{"name":"reset","doc":"(reset)\n\nFunction resets the environment and removes all user defined variables."},{"name":"response->content","doc":"(response->text binary res)\n\nReads all text from a Node.js HTTP response object. If binary argument\nis true it will return Buffer object that can be converted to u8vector.\n\n***Warning:*** it may overflow the Javascript call stack when converting the\nwhole buffer to u8vector, because LIPS doesn't have TCO."},{"name":"reverse","doc":"(reverse list)\n\nFunction that reverses the list or array. If value is not a list\nor array it will error."},{"name":"round","doc":"(round number)\n\nFunction that calculates the round of a number."},{"name":"s16vector","doc":"(s16vector v1 v2 ...)\n\nCreate signed 16-bit integer vector (C short) from give arguments."},{"name":"s16vector-length","doc":"(s16vector-length v)\n\nreturn length of signed 16-bit integer vector (C short)."},{"name":"s16vector-ref","doc":"(s16vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"s16vector-set!","doc":"(s16vector-set! vector k)\n\nFunction set value of signed 16-bit integer vector (C short) at index k.\nIf index is out of range it throw exception."},{"name":"s16vector?","doc":"(s16vector? x)\n\nReturns #t of argument is signed 16-bit integer vector (C short),\notherwise it return #f."},{"name":"s32vector","doc":"(s32vector v1 v2 ...)\n\nCreate signed 32-bit integer vector (C unsigned int) from give arguments."},{"name":"s32vector-length","doc":"(s32vector-length v)\n\nreturn length of signed 32-bit integer vector (C unsigned int)."},{"name":"s32vector-ref","doc":"(s32vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"s32vector-set!","doc":"(s32vector-set! vector k)\n\nFunction set value of signed 32-bit integer vector (C unsigned int) at index k.\nIf index is out of range it throw exception."},{"name":"s32vector?","doc":"(s32vector? x)\n\nReturns #t of argument is signed 32-bit integer vector (C unsigned int),\notherwise it return #f."},{"name":"s8vector","doc":"(s8vector v1 v2 ...)\n\nCreate signed 8-bit integer vector (C signed char) from give arguments."},{"name":"s8vector-length","doc":"(s8vector-length v)\n\nreturn length of signed 8-bit integer vector (C signed char)."},{"name":"s8vector-ref","doc":"(s8vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"s8vector-set!","doc":"(s8vector-set! vector k)\n\nFunction set value of signed 8-bit integer vector (C signed char) at index k.\nIf index is out of range it throw exception."},{"name":"s8vector?","doc":"(s8vector? x)\n\nReturns #t of argument is signed 8-bit integer vector (C signed char),\notherwise it return #f."},{"name":"scheme-report-environment","doc":"(scheme-report-environment version)\n\nReturns new Environment object for given Scheme Spec version.\nOnly argument 5 is supported that create environment for R5RS."},{"name":"search","doc":"(search pattern string)\n\nFunction that returns the first found index of the pattern inside a string."},{"name":"set-car!","doc":"(set-car! obj value)\n\nFunction that sets the car (first item) of the list/pair to specified value.\nThe old value is lost."},{"name":"set-cdr!","doc":"(set-cdr! obj value)\n\nFunction that sets the cdr (tail) of the list/pair to specified value.\nIt will destroy the list. The old tail is lost."},{"name":"set-current-directory!","doc":"(set-current-directory! string)\n\nChanges the current working directory to provided string."},{"name":"set-global!","doc":"(set-global! name)\n\nMacro to make the name a Javascript global variable (i.e. accessible on globalThis)."},{"name":"set-obj!","doc":"(set-obj! obj key value)\n(set-obj! obj key value props)\n\nFunction set a property of a JavaScript object. props should be a vector of pairs,\npassed to Object.defineProperty."},{"name":"set-repr!","doc":"(add-repr! type fn)\n\nFunction that adds the string representation to the type, which should be\na constructor function.\n\nFunction fn should have args (obj q) and it should return a string. obj\nis the value that need to be converted to a string. If the object is nested\nand you need to use `repr` recursively, it should pass the second parameter q\nto repr, so string will be quoted when it's true.\n\ne.g.: (lambda (obj q) (string-append \"<\" (repr obj q) \">\"))"},{"name":"set-special!","doc":"(set-special! symbol name [type])\n\nAdd a special symbol to the list of transforming operators by the parser.\ne.g.: `(add-special! \"#\" 'x)` will allow to use `#(1 2 3)` and it will be\ntransformed into (x (1 2 3)) so you can write x macro that will process\nthe list. 3rd argument is optional, and it can be one of two values:\nlips.specials.LITERAL, which is the default behavior, or\nlips.specials.SPLICE which causes the value to be unpacked into the expression.\nThis can be used for e.g. to make `#(1 2 3)` into (x 1 2 3) that is needed\nby # that defines vectors."},{"name":"set!","doc":"(set! name value)\n\nMacro that can be used to set the value of the variable or slot (mutate it).\nset! searches the scope chain until it finds first non empty slot and sets it."},{"name":"shuffle","doc":"(shuffle obj)\n\nOrder items in vector or list in random order."},{"name":"sin","doc":"(sin n)\n\nFunction that calculates sine of a number."},{"name":"single","doc":"(single list)\n\nChecks if argument is list with one element."},{"name":"some","doc":"(some fn list)\n\nHigher-order function that calls fn on each element of the list.\nIt stops and returns true when fn returns true for a value.\nIf none of the values give true, some will return false.\nAnalogous to Python any(map(fn, list))."},{"name":"sort","doc":"(sort list [predicate])\n\nSorts the list using optional predicate function. If no comparison function\nis given it will use <= and sort in increasing order."},{"name":"split","doc":"(split separator string)\n\nFunction that creates a list by splitting string by separator which can\nbe a string or regular expression."},{"name":"sqrt","doc":"(sqrt number)\n\nFunction that returns the square root of the number."},{"name":"square","doc":"(square z)\n\nReturns the square of z. This is equivalent to (* z z)."},{"name":"string","doc":"(string chr1 chr2 ...)\n\nFunction that creates a new string from it's arguments. Each argument\nneeds to be a character object."},{"name":"string->list","doc":"(string->list string)\n\nReturns a list of characters created from string."},{"name":"string->number","doc":"(string->number number [radix])\n\nFunction that parses a string into a number."},{"name":"string->symbol","doc":"(string->symbol string)\n\nFunction that converts a string to a LIPS symbol."},{"name":"string->utf8","doc":"(string->utf8 string)\n(string->utf8 string start)\n(string->utf8 string start end)\n\nConverts string into u8 bytevector using utf8 encoding.\nThe start and end is the range of the input string for the conversion."},{"name":"string->vector","doc":"(string->list string)\n(string->list string start)\n(string->list string start end)\n\nFunction that copies given range of string to list. If no start is specified it use\nstart of the string, if no end is specified it convert to the end of the string."},{"name":"string-append","doc":"(concat . strings)\n\nFunction that creates a new string by joining its arguments."},{"name":"string-ci<?","doc":"(string-ci<? string1 string2 ...)\n\nReturns true if strings are monotonically increasing, ignoring the case."},{"name":"string-ci<=?","doc":"(string-ci<=? string1 string2 ...)\n\nReturns true if strings are monotonically non-decreasing, ignoring the case."},{"name":"string-ci=?","doc":"(string-ci=? string1 string2 ...)\n\nChecks if all strings are equal, ignoring the case."},{"name":"string-ci>?","doc":"(string-ci>? string1 string2 ...)\n\nReturns true if strings are monotonically decreasing, ignoring the case"},{"name":"string-ci>=?","doc":"(string-ci>=? string1 string2 ...)\n\nReturns true if strings are monotonically non-increasing, ignoring the case."},{"name":"string-copy","doc":"(string-copy x)\n\nCreates a new string based on given argument."},{"name":"string-downcase","doc":"(string-downcase string)\n\nFunction convert a string passed as argument to lower case."},{"name":"string-fill!","doc":"(string-fill! symbol char)\n\nFunction that destructively fills the string with given character."},{"name":"string-foldcase","doc":"(string-foldcase string)\n\nReturns lowercase string using the Unicode simple case-folding algorithm."},{"name":"string-for-each","doc":"(string-for-each fn string1 stringr2 ...)\n\nApplies a function fn to each element of the strings, similar string-map.\nBut the return value is #void."},{"name":"string-join","doc":"(join separator list)\n\nFunction that returns a string by joining elements of the list using separator."},{"name":"string-length","doc":"(string-length string)\n\nReturns the length of the string."},{"name":"string-map","doc":"(string-map fn string1 stringr2 ...)\n\nReturns new string from applying function fn to each element\nof the strings, similar to map for lists."},{"name":"string-ref","doc":"(string-ref string k)\n\nReturns character inside string at given zero-based index."},{"name":"string-set!","doc":"(string-set! string index char)\n\nReplaces character in string at a given index."},{"name":"string-split","doc":"(split separator string)\n\nFunction that creates a list by splitting string by separator which can\nbe a string or regular expression."},{"name":"string-upcase","doc":"(string-downcase string)\n\nFunction convert a string passed as argument to upper case."},{"name":"string?","doc":"(string? expression)\n\nPredicate that tests if value is a string."},{"name":"string<?","doc":"(string<? string1 string2 ...)\n\nReturns true if strings are monotonically increasing."},{"name":"string<=?","doc":"(string<? string1 string2 ...)\n\nReturns true if strings are monotonically non-decreasing."},{"name":"string=?","doc":"(string=? string1 string2 ...)\n\nChecks if all strings are equal."},{"name":"string>?","doc":"(string<? string1 string2 ...)\n\nReturns true if strings are monotonically decreasing."},{"name":"string>=?","doc":"(string<? string1 string2 ...)\n\nReturns true if strings are monotonically non-increasing."},{"name":"substring","doc":"(substring string start end)\n\nFunction that returns the slice of the string starting at start and ending\nwith end."},{"name":"sxml","doc":"(sxml expr)\n\nMacro for JSX like syntax but with SXML.\ne.g. usage:\n\n(sxml (div (@ (data-foo \"hello\")\n             (id \"foo\"))\n          (span \"hello\")\n          (span \"world\")))\n;; ==> <div data-foo=\"hello\" id=\"foo\"><span>hello</span>\n;; ==> <span>world</span></div>"},{"name":"sxml-unquote","doc":"(sxml-unquote expression) or ~expression\n\nTreat expression as code and evaluate it inside sxml, similar to unquote\nwith quasiquote."},{"name":"symbol->string","doc":"(symbol->string symbol)\n\nFunction that converts a LIPS symbol to a string."},{"name":"symbol-append","doc":"(symbol-append s1 s2 ...)\n\nFunction that creates a new symbol from symbols passed as arguments."},{"name":"symbol?","doc":"(symbol? expression)\n\nPredicate that tests if value is a LIPS symbol."},{"name":"symbol=?","doc":"(symbol=? s1 s2 ...)\n\nChecks if each value is symbol and it's the same according to string=? predicate."},{"name":"syntax-parameterize","doc":"(syntax-parameterize (bindings) body)\n\nMacro work similar to let-syntax but the the bindnds will be exposed to the user.\nWith syntax-parameterize you can define anaphoric macros."},{"name":"syntax-rules","doc":"(syntax-rules () (pattern expression) ...)\n\nBase of hygienic macros, it will return a new syntax expander\nthat works like Lisp macros."},{"name":"take","doc":"(take list n)\n\nReturns n first values of the list."},{"name":"tan","doc":"(tan n)\n\nFunction that calculates tangent of a number."},{"name":"textual-port?","doc":"(textual-port? port)\n\nFunction that tests if argument is string port."},{"name":"throw","doc":"(throw string)\n\nThrows a new exception."},{"name":"timer","doc":"(timer time . body)\n\nEvaluates body after delay, it returns the timer ID from setTimeout.\nTo clear the timer you can use native JS clearTimeout function."},{"name":"tree->array","doc":"(tree->array list)\n\nFunction that converts a LIPS cons tree structure into a JavaScript array."},{"name":"tree-map","doc":"(tree-map fn tree)\n\nTree version of map. fn is invoked on every leaf."},{"name":"truncate","doc":"(truncate n)\n\nFunction that returns the integer part (floor) of a real number."},{"name":"try","doc":"(try expr (catch (e) code))\n(try expr (catch (e) code) (finally code))\n(try expr (finally code))\n\nMacro that executes expr and catches any exceptions thrown. If catch is provided\nit's executed when an error is thrown. If finally is provided it's always\nexecuted at the end."},{"name":"type","doc":"(type object)\n\nFunction that returns the type of an object as string."},{"name":"typecheck","doc":"(typecheck label value type [position])\n\nChecks the type of value and errors if the type is not one allowed.  Type can be\nstring or list of strings. The position optional argument is used to create a\nproper error message for the nth argument of function calls."},{"name":"typecheck-args","doc":"(typecheck-args type label lst)\n\nFunction that makes sure that all items in list are of same type."},{"name":"typecheck-number","doc":"(typecheck-number label value type [position])\n\nFunction similar to typecheck but checks if the argument is a number\nand specific type of number e.g. complex."},{"name":"typed-array?","doc":"(typed-array? o)\n\nFunction that tests if the arguments is a JavaScript typed array (Scheme byte vector)."},{"name":"u16vector","doc":"(u16vector v1 v2 ...)\n\nCreate unsigned 16-bit integer vector (C unsigned short) from give arguments."},{"name":"u16vector-length","doc":"(u16vector-length v)\n\nreturn length of unsigned 16-bit integer vector (C unsigned short)."},{"name":"u16vector-ref","doc":"(u16vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"u16vector-set!","doc":"(u16vector-set! vector k)\n\nFunction set value of unsigned 16-bit integer vector (C unsigned short) at index k.\nIf index is out of range it throw exception."},{"name":"u16vector?","doc":"(u16vector? x)\n\nReturns #t of argument is unsigned 16-bit integer vector (C unsigned short),\notherwise it return #f."},{"name":"u32vector","doc":"(u32vector v1 v2 ...)\n\nCreate unsigned 32-bit integer vector (C int) from give arguments."},{"name":"u32vector-length","doc":"(u32vector-length v)\n\nreturn length of unsigned 32-bit integer vector (C int)."},{"name":"u32vector-ref","doc":"(u32vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"u32vector-set!","doc":"(u32vector-set! vector k)\n\nFunction set value of unsigned 32-bit integer vector (C int) at index k.\nIf index is out of range it throw exception."},{"name":"u32vector?","doc":"(u32vector? x)\n\nReturns #t of argument is unsigned 32-bit integer vector (C int),\notherwise it return #f."},{"name":"u8-ready?","doc":"(u8-ready?)\n(u8-ready? port)\n\nReturns #t if a byte is ready on the binary input port and returns #f otherwise.\nIf u8-ready? returns #t then the next read-u8 operation on the given port is\nguaranteed not to hang. If the port is at end of file then u8-ready? returns #t."},{"name":"u8vector","doc":"(u8vector v1 v2 ...)\n\nCreate unsigned 8-bit integer vector (C unsigned char) from give arguments."},{"name":"u8vector-length","doc":"(u8vector-length v)\n\nreturn length of unsigned 8-bit integer vector (C unsigned char)."},{"name":"u8vector-ref","doc":"(u8vector-ref vector k)\n\nReturns value from vector at index k.\nIf index is out of range it throw exception."},{"name":"u8vector-set!","doc":"(u8vector-set! vector k)\n\nFunction set value of unsigned 8-bit integer vector (C unsigned char) at index k.\nIf index is out of range it throw exception."},{"name":"u8vector?","doc":"(u8vector? x)\n\nReturns #t of argument is unsigned 8-bit integer vector (C unsigned char),\notherwise it return #f."},{"name":"unary","doc":"(unary fn)\n\nReturns a new function with arguments limited to one."},{"name":"unbind","doc":"(unbind fn)\n\nFunction that removes the weak 'this' binding from a function so you\ncan get properties from the actual function object."},{"name":"unfold","doc":"(unfold fn init)\n\nReturns a list from the given function and init value. The function should\nreturn a pair where first is the item added to the list and second is next value\npassed to the function. If the function returns false it ends the loop."},{"name":"unquote","doc":"(unquote code) or ,code\n\nSpecial form used in the quasiquote macro. It evaluates the expression inside and\nsubstitutes the value into quasiquote's result."},{"name":"unquote-splicing","doc":"(unquote-splicing code) or ,@code\n\nSpecial form used in the quasiquote macro. It evaluates the expression inside and\nsplices the list into quasiquote's result. If it is not the last element of the\nexpression, the computed value must be a pair."},{"name":"unset-repr!","doc":"(unset-repr! type)\n\nRemoves the string representation of the type, which should be constructor function,\nadded by add-repr! function."},{"name":"unset-special!","doc":"(unset-special! name)\n\nFunction that removes a special symbol from parser added by `set-special!`,\nname must be a string."},{"name":"unset!","doc":"(unset! name)\n\nFunction to delete the specified name from environment.\nTrying to access the name afterwards will error."},{"name":"utf8->string","doc":"(utf8->string u8vector)\n(utf8->string u8vector start)\n(utf8->string u8vector start end)\n\nConverts u8 bytevector into string using utf8 encoding.\nThe start and end is the range of the input byte vector for the conversion."},{"name":"value","doc":"(value obj)\n\nFunction that unwraps LNumbers and converts '() to #void."},{"name":"values","doc":"(values a1 a2 ...)\n\nIf called with more then one element it will create a special\nValues object that can be used in the call-with-values function."},{"name":"values-ref","doc":"(values-ref values n)\n\nReturns n value of values object which is result of value function."},{"name":"vector","doc":"(vector 1 2 3 (+ 3 1)) or #(1 2 3 4)\n\nMacro for defining vectors (Javascript Arrays). Vector literals are\nautomatically quoted, so you can't use expressions inside them, only other\nliterals, like other vectors or objects."},{"name":"vector->list","doc":"(vector->list vector)\n(vector->list vector start)\n(vector->list vector start end)\n\nFunction that copies given range of vector to list. If no start is specified it use\nstart of the vector, if no end is specified it convert to the end of the vector."},{"name":"vector->string","doc":"(vector->string vector)\n(vector->string vector start)\n(vector->string vector start end)\n\nReturns new string created from vector of characters in given range.\nIf no start is given it create string from 0, if no end is given it return\nstring to the end."},{"name":"vector-append","doc":"(vector-append v1 v2 ...)\n\nReturns new vector by combining it's arguments that should be vectors."},{"name":"vector-copy","doc":"(vector-copy vector)\n(vector-copy vector start)\n(vector-copy vector start end)\n\nReturns a new vecotor that is a copy of given vector. If start\nis not provided it starts at 0, if end it's not provided it copy\ntil the end of the given vector."},{"name":"vector-copy!","doc":"(vector-copy to at from)\n(vector-copy to at from start)\n(vector-copy to at from start end)\n\nCopies the elements of vector from between start and end into\nvector to starting at `at`. If start is missing it start at 0 and if end\nis missing it copy til the end of the vector from. It throws an error\nif vector from don't fit into the destination `to`."},{"name":"vector-fill!","doc":"(vector-fill! vector fill)\n(vector-fill! vector fill start)\n(vector-fill! vector fill start end)\n\nFill vector with a given value in given range. If start is not given is start\nat 0. If end is not given it fill till the end if the vector."},{"name":"vector-for-each","doc":"(vector-for-each fn vector1 vector2 ...)\n\nInvokes every Returns new vector from applying function fn to each element\nof the vectors, similar to map for lists."},{"name":"vector-length","doc":"(vector-length vec)\n\nReturns length of the vector. It errors if the argument is not a vector."},{"name":"vector-map","doc":"(vector-map fn vector1 vector2 ...)\n\nReturns new vector from applying function fn to each element\nof the vectors, similar to map for lists."},{"name":"vector-ref","doc":"(vector-ref vec n)\n\nReturns nth element of the vector vec."},{"name":"vector-set!","doc":"(vector-set! vec n value)\n\nFunction that sets nth item of the vector to value."},{"name":"vector?","doc":"(vector? n)\n\nReturns true if value is vector and false if not."},{"name":"wait","doc":"(wait time . expr)\n\nReturns a promise that will resolve with the expression after delay."},{"name":"warn-quote","doc":"(warn-quote)\n\nSimple macro that throws an error, when you try to use ’ symbol as quote in code."},{"name":"while","doc":"(while cond body)\n\nCreates a loop, it executes cond and body until cond expression is false."},{"name":"with-exception-handler","doc":"(with-exception-handler handler thunk)\n\nProcedure call and return value of thunk function, if exception happen\nit call handler procedure."},{"name":"with-input-from-file","doc":"(with-input-from-file string thunk)\n\nProcedure open file and make it current-input-port then thunk is executed.\nAfter thunk is executed current-input-port is restored and file port\nis closed."},{"name":"with-input-from-port","doc":"(with-input-from-port port thunk)\n\nProcedure use port and make it current-input-port then thunk is executed.\nAfter thunk is executed current-input-port is restored and given port\nis closed."},{"name":"with-input-from-string","doc":"(with-input-from-string string thunk)\n\nProcedure open string and make it current-input-port then thunk is executed.\nAfter thunk is executed current-input-port is restored and string port\nis closed."},{"name":"with-tags","doc":"(with-tags expression)\n\nvalutes LIPS shorter code for S-Expression equivalent of JSX.\ne.g.:\n\n(with-tags (:div (:class \"item\" :id \"item-1\")\n                 (list (:span () \"Random Item\")\n                       (:a (:onclick (lambda (e) (alert \"close\")))\n                           \"close\"))))\n\nAbove expression can be passed to function that renders JSX (like render\nin React, Preact) To get the string from the macro you can use vhtml\nlibrary from npm."},{"name":"write","doc":"(write obj [port])\n\nWrite object to standard output or give port. For strings it will include\nwrap in quotes."},{"name":"write-bytevector","doc":"(write-bytevector bytevector)\n(write-bytevector bytevector port)\n\nWrite byte vector into binary output port."},{"name":"write-char","doc":"(write-char string)\n(write-char string port)\n\nWrites the character char (not an external representation of the character)\nto the given textual output port and returns an unspecified value."},{"name":"write-string","doc":"(write-string string)\n(write-string string port)\n(write-string string port start)\n(write-string string port start end)\n\nWrites the characters of string from start to end in left-toright order\nto the textual output port."},{"name":"write-u8","doc":"(write-u8 byte)\n(write-u8 byte port)\n\nWrite byte into binary output port."},{"name":"Y","doc":"(Y f)\n\n  _ __   __    _            _       _      _ __   __         _   _  _\n /  \\ \\ / /   /  __        /   ____  \\    /  \\ \\ / /    ____  \\   \\  \\\n+    \\ v /   +   \\ \\      +   / ___|  +  +    \\ v /    / ___|  +   +  +\n|     \\ /    |    \\ \\     |  | |__    |  |     \\ /    | |__    |   |  |\n|     | |    |    /  \\    |  |  __|   |  |     | |    |  __|   |   |  |\n|     | |    |   / /\\ \\   |  | |      |  |     | |    | |      |   |  |\n+     |_|    +  /_/  \\_\\  +  |_|      +  +     |_|    |_|      +   +  +\n \\_           \\_           \\_       _/    \\_                 _/  _/ _/"},{"name":"zero?","doc":"(zero? x)\n\nChecks if the number is equal to 0"},{"name":"zip","doc":"(zip list1 list2 ...)\n\nReturn list where elements are taken from each list.\ne.g.:\n(zip '(1 2 3) '(2 3 4))\n;; ==> '((1 2) (2 3) (3 4))"}]