f0670897bd
Added new debug option, to display the addresses of tables in comments.
2017-06-06 00:22:37 +02:00
39dad0dadb
analyse_structure
refactored to perform breath-first traversal. It also now keeps track of breath first depth of tables.
2017-06-06 00:02:34 +02:00
48ca04bcb8
Changed all function signatures to exclude the old options
arguments..
2017-06-05 23:24:38 +02:00
7005a080c0
Working on outphasing the options
value.
2017-06-05 23:13:50 +02:00
192575ded8
String Builder is now an actual object, and can now be called to append.
2017-06-05 22:58:09 +02:00
97ced3a173
Merged format_map
into format_table
.
2017-06-05 22:47:07 +02:00
bf9c5a6749
Removed some old orphaned functions.
2017-06-05 22:35:47 +02:00
65c2acb447
Removed the possibility of the 'max'
depth value, refactored format_table
, and added lots of asserts in rest of pretty.lua
2017-06-05 22:34:23 +02:00
7ae38f1567
Small change to README.md
2017-06-05 22:08:33 +02:00
e98487fcae
Added basic README.md
2017-06-05 21:49:23 +02:00
f528a7853f
Moved sorting to own file, and added very large tests.
2017-06-05 20:38:44 +02:00
7ccb9e8123
Added vulgar_fraction function, and increased resilience.
2017-05-25 22:53:02 +02:00
0ab7942023
Integers should be preferred to 2^x
2017-04-30 22:40:24 +02:00
0f26759ee2
Moved to doing seperator fixing just before returning from pretty.
2017-04-14 14:01:01 +02:00
f29004fe17
Improved resilience of library.
2017-04-14 13:24:29 +02:00
9050d53962
Removed unused functionallity, and associated tests.
2017-04-14 13:09:05 +02:00
87b12e15b2
Fixed issues with analýse_structure.lua
...
The most significant was a misclassification of tables with number
exclusive keys, with huge jumps between each one.
Example: { 1, [300] = 300 }
This was caused by logic faults in `get_table_info`, which has been fixed.
When solving above issue, a two new issues appeared:
1. Due to a logic fault, the count of number of elements in a table was wrong,
leading to issues with tables with boolean keys. This was fixed with simple
logic changes.
2. Some very small tables (1 element) would be classified as sets, and thus
rendered wrongly. This was fixed by adding a MINIMUM_NUMBER_OF_SET_ELEMENTS
constant.
2017-04-14 13:06:43 +02:00
155c877987
Alternative process for determining short tables
...
This one is based on the representative width of the table. Not only
does this produce better results, but it's also more futureproof.
2017-04-14 12:19:23 +02:00
5bee4a7378
Small holes in sequences will now be filled with nil
, rather than triggering a reclassification to PURE_MAP.
2017-04-14 10:56:38 +02:00
6ac8a2d6de
Added more tests.
2017-04-12 15:15:03 +02:00
2a652a4c92
Implemented more advanced utf8 support + moved fractional support to the SPECIAL_NUMBER list.
2017-04-12 14:52:51 +02:00
ed252643e9
Added some thoughts on pretty printing of functions, into the header of function.lua
2017-04-06 14:46:45 +02:00
5a3e9d0e27
Improved sorting of tables.
2017-04-05 13:10:23 +02:00
ec3ba2cab9
Improved error messages, and fixed issue with importing from other modules
2017-04-05 12:21:43 +02:00
ae73cc9b64
Reworked the number formatting system. Will now attempt to generate the shortest possible representation of the given number.
2017-04-03 20:01:36 +02:00
e5e23422ef
Indent to stirng
2017-04-03 17:03:32 +02:00
736335b208
Added check for bad options.
2017-04-03 16:39:19 +02:00
9695a27394
Added short_builtins
2017-04-03 13:56:06 +02:00
588e5588ac
Added closure creation.
2017-04-03 13:49:18 +02:00
8f956bf444
Moved function formatting into own file.
2017-04-03 11:55:49 +02:00
0a79b830ba
Moved some constants into their own file, more info is stored in l, and improved some marker stuff.
2017-04-03 11:24:51 +02:00
948bc6c0d8
Added init.lua file, to allow import from other projects.
2017-04-03 11:13:43 +02:00
4e3d5e2bf9
Changed to use imported TestSuite.lua, instead of embedded in the tests/ folder.
2017-04-03 11:12:19 +02:00
c75ee00f88
Added shortness info-gathering to analyze_structure
2017-01-19 14:23:34 +01:00
e2570ee780
Working on more extensive table info gathering.
2017-01-19 14:02:34 +01:00
d848c96fb1
Very minor work on recursion.
2017-01-16 16:22:46 +01:00
cad8258a6f
Added number.lua
file, to allow more informative representations of numbers.
2017-01-16 16:10:10 +01:00
b405afeae8
Improved compatibility with PUC Lua 5.1 - 5.3
2017-01-05 15:50:44 +01:00
a333bb2b36
Added JIT std library.
2017-01-05 15:07:08 +01:00
616c9f7a6b
Improved alignment of functions.
2017-01-05 14:28:31 +01:00
b2b295cf8a
Fixed issue with values not being properly indented.-
2017-01-05 13:44:47 +01:00
a20f6bddb7
Restructure to allow using only a single table to create output.
2017-01-05 13:37:44 +01:00
931d422581
Improved resilience of library.lua. Pretty can now run in a sandbox while still providing information about the std functions exposed to it.
2017-01-05 13:22:25 +01:00
877c954b78
Expanded library.lua to include all documented standard library functions.
2016-12-31 16:50:12 +01:00
961bdf4a90
Added resilience test for loading library.lua
2016-12-30 12:03:14 +01:00
061ffb2d9e
Extended library.lua, and added improved printing of doc string.
2016-12-30 12:02:46 +01:00
d75507da40
Added library function over builtin functions. (Currently only math library covered.)
2016-12-29 18:40:30 +01:00
038a88eca5
Functions defined within a string will now be shown fully.
2016-12-29 16:54:31 +01:00
b27d307da0
Slight improvements to function formatting.
2016-12-29 16:17:58 +01:00
55265378f9
Attempting more comprehensive coverage of types, including threads/coroutines and functions.
2016-12-29 15:33:43 +01:00