csharpfritz / TAML

Defining the coolest and simplest markup language delimited ONLY by tabs
MIT License
23 stars 11 forks source link

Issue: How to define an array with no values #60

Closed csharpfritz closed 3 years ago

csharpfritz commented 3 years ago

In JSON, it's possible to define an array as:

"array": []

This results in a key value pair with an empty array as the value.

Possible solutions:

  1. Empty array is defined with a blank line
  2. Some meta-character is used to define "null"

Other ideas?

Stelzi79 commented 3 years ago

Well I would call such an array as optional setting in a configuration file.

On one side requiring such an array to be in a configuration file on the other hand there doesn't need to be any value in the array. If you don't need or want use that configuration array why even force a user to mark up that you don't use it?

I would argue to not allow such things, because if something needs to "be configured" to nothingness why not leave it out at all.

I don't thing TAML needs to embrace the enlargement of the entropy of nothingness like JavaScript does it.

csharpfritz commented 3 years ago

Resolved for specification 1.1: Empty array is indicated with a single entry on a new line where a value WOULD have been presented, in the format ![]

The magic characters ![] indicate the empty array