Commit Graph

9 Commits

Author SHA1 Message Date
Max Cahill
795f2587d2 fixed pretty.lua using tablex instead of table alias 2022-05-23 14:54:05 +10:00
Max Cahill
1e75fad409 changed pretty printing to use sorted keys 2022-05-23 14:51:18 +10:00
David Briscoe
0c193d7901 lint: Don't assign values that will never be used
No bugs here, but giving an initial value can hide cases where we fail
to set a value. Use an assert instead so we can see errors if we change
and break this code.

Except break_next which goes out of scope after it's assigned (I guess
it used to be outside the loop).
2022-03-03 10:17:35 -08:00
David Briscoe
8d41c6d3d1 lint: Fix whitespace issues
Remove excess whitespace and remove related ignores.
2022-03-03 10:17:34 -08:00
Max Cahill
2d5555400d fixed pretty print depth issues 2021-11-26 16:50:44 +11:00
Max Cahill
2b6a6d8f53 pretty format: circular reference ids only apply in their own reference tree
so, repeated but not circular data is repeatedly output
helpful for serialisation-like uses and more clear because the id was not printed on the actual data structure in this case
2021-08-14 19:10:12 +10:00
Max Cahill
65d06d01f6 fixed pretty default config getting modified by parameters 2021-07-05 16:20:03 +10:00
Max Cahill
67019de5b5 made pretty module default config and doc comments consistent order 2021-07-05 16:18:03 +10:00
Max Cahill
e726f19a5e added pretty module with pretty.print and pretty.string
breaking: string.pretty still exists but takes new config argument
2021-07-05 16:12:16 +10:00