lack
47062da36a
Add os.arch
and os.platform
( #437 )
...
* add and
* .ignore
2024-02-24 13:24:35 +00:00
E Sequeira
48308d45d9
fix json decode ( #424 )
...
* fix json decode
2023-06-26 08:40:49 +01:00
Mikael Ganehag Brorsson
82b543fd98
Better support for TZ locations in the times module ( #397 )
...
* Handle panics by deferring recover as an error
* Check for type in recover handler
* Added support for times.in_location
* Added support for location (TZ) to times.date
* Updated documentation
2023-01-31 09:51:04 +00:00
Wannes
ecc3d9181e
Added more math consts ( #404 )
2023-01-30 08:12:28 +00:00
gufeijun
3f4245d962
fix: solve precision problem when decode bigint in json ( #399 )
2023-01-30 08:10:04 +00:00
Michał Idzikowski
7b5d207914
fix documentation for enum.filter ( #359 )
...
* fix documentation for enum.filter
fixes https://github.com/d5/tengo/issues/358
* update stdlib code comment for enum.filter
2022-02-06 22:53:27 -08:00
Ozan Hacıbekiroğlu
3d7269c2c8
fix stdlib json string encoding ( #272 )
2020-05-05 06:46:08 +02:00
daniel
d5b24138d3
add go module v2 ( #244 )
2019-12-29 13:38:51 -08:00
daniel
a9a233a750
fix internal package issue ( #241 )
...
* fix internal package issue
* ExampleSimple -> Example
2019-12-24 07:42:30 -08:00
daniel
c88a5f506e
some code clean up ( #237 )
2019-12-20 11:40:38 -08:00
geseq
4cd9a2bcbc
fix #231 ( #235 )
2019-11-02 07:36:47 +01:00
Ma_124
1ee7425c9d
Stdlib encodings: hex, base64 ( #216 ) ( #221 )
...
* stdlib/hex and stdlib/base64
* stdlib/hex and stdlib/base64: added docs
2019-08-09 13:36:45 -04:00
earncef
b2df4f579c
Custom formatter based on go's fmt package. ( #185 )
...
* Custom formatter based on go's fmt package.
* Cleanup
* Cleanup
* Added tengo.MaxStringLen check
* Cleanup
2019-04-13 11:29:50 -07:00
earncef
bb07fa15b7
text.trim, text.pad_left and text.pad_right ( #183 )
...
* Added trim, pad_left and pad_right to text
* Check MaxStringLen
* Added doc
* Fixed doc
* Moved length check
2019-04-11 00:23:30 -07:00
Daniel
719e269cb1
minor lint fixes ( #182 )
2019-04-10 21:39:19 -07:00
earncef
3eebecb2a4
Fix %v formatting ( #181 )
...
* Fix %v formatting
* Added Bytes
* Fixed tests.
2019-04-09 23:15:31 -07:00
earncef
09009d4040
Substring function ( #180 )
...
* Substring function
* substring -> substr
2019-04-08 23:32:39 -07:00
Daniel
2cde0eaeea
json module faster implementation ( #173 )
...
* json module faster implementation
* add some decoding error test
2019-04-06 05:25:23 -07:00
Daniel
2f86800724
'enum' module ( #166 )
...
* 1. adding more methods to enum module
2. added ModuleMap.AddMap()
3. added bytes iterator
* add builtin functions 'is_enumerable' and 'is_array_like'
* builtin function 'is_iterable'
* first iteration on 'enum' module
* fix 'is_iterable' builtin function
2019-03-27 01:27:59 -07:00
Daniel
3c30109cd0
fix bytecode encoding/decoding of builtin modules ( #154 )
...
* fix bytecode encoding/decoding of builtin modules
* Bytecode.Decode() to take map[string]objects.Importable
* add objects.ModuleMap
* update docs
* stdlib.GetModuleMap()
2019-03-20 01:28:40 -07:00
Daniel
61890b15cb
module refactor ( #148 )
...
* wip
* move print and JSON functions to modules
* builtin functions are not replacable now
* builtin functions are added for default nil symbol table
* importables: builtin modules and source modules
* refactoring runtime tests
* fix tests
* update documentation
* cleanup
* clean up cli
* fix REPL prints
2019-03-18 08:15:26 -07:00
earncef
5d8457a8f6
Removed double indirection for massive performance gains ( #140 )
...
* Removed double indirection for performance gains
* Added missing file
* Cleanup
* Remove pointers patch.
* Cleanup
* Removed redundant parenthesis
* FreeVar changed to ObjectPtr and removed OpSetLocalPtr
* Removed truePtr, falsePtr and undefinedPtr
* Cleanup
2019-03-14 01:07:19 -07:00
earncef
c437def4a0
Decoupled stdlib from vm, script and compiler ( #126 )
...
* Decoupled stdlib from script
* Decoupled compiler and vm from stdlib
* cleanup
* Docs and cleanup
* main package with and without stdlib
* cleanup
* Update .goreleaser
2019-03-04 10:21:39 -08:00
Daniel
0c5e80b057
Limit the maximum size of string/bytes values ( #121 )
...
* add tengo.MaxStringLen and tengo.MaxBytesLen to limit the maximum byte-length of string/bytes values
* add couple more tests
2019-03-01 10:48:02 -08:00
Daniel
306055ad65
add helper functions for builtin functions and builtin modules ( #122 )
...
* add helper functions for builtin functions and builtin modules
* fix a builtin function bug for modules
2019-02-28 18:41:29 -08:00
Daniel
3500c686b3
Improvements on compiler/VM error reporting (filename:line:col)
...
- add type infos to VM error messages
- add 'Name' to UserFunction objects
- add 'expectErrorString' to VM tests
- replace vm.expectError() with vm.expectErrorString() to make it more explicit
- add source map info to VM error messages
- optimization in function calls
- add file/line/col info to compiler errors
- change stdlib module to be loaded from VM (instead of compiler) so they can be properly loaded after the source is compiled into binary
- VM can take builtin modules optionally
2019-02-20 16:26:11 -08:00