inspect.lua icon indicating copy to clipboard operation
inspect.lua copied to clipboard

Looks strange with `inspect {{ x = 1 }}`

Open sumneko opened this issue 4 years ago • 2 comments

The result of inspect {{ x = 1 }} is

{ {
    x = 1
  } }

The indentation is not aligned, is this a special case or bug?

sumneko avatar Apr 05 '22 15:04 sumneko

You did table inside table, where's the problem

borsuczyna avatar May 13 '22 07:05 borsuczyna

You did table inside table, where's the problem

It may be a common special case of this structure:

inspect { { x = 1 }, { x = 2 }, { x = 3 } }

Is it possible to keep their performance consistent?

However, I have no strong demand for this. If considering workload, cost performance or difficult ambiguity, I can accept the maintenance status.

sumneko avatar May 14 '22 08:05 sumneko

You might not get exactly the output you want, but tweaking options.newline and options.indent might help.

See #58 for reference.

kikito avatar Jan 19 '23 12:01 kikito