From 5239bd3e11ed0fda65ce7970bd4c8b336f8017ee Mon Sep 17 00:00:00 2001 From: John Kerl Date: Wed, 12 May 2021 04:23:41 +0000 Subject: [PATCH] todo --- go/src/types/mlrval_new.go | 1 + go/todo.txt | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) diff --git a/go/src/types/mlrval_new.go b/go/src/types/mlrval_new.go index 4815d8be9..5dfc21783 100644 --- a/go/src/types/mlrval_new.go +++ b/go/src/types/mlrval_new.go @@ -366,6 +366,7 @@ func LengthenMlrvalArray(array *[]Mlrval, newLength64 int) { if newLength <= cap(*array) { newArray := (*array)[:newLength] for zindex := len(*array); zindex < newLength; zindex++ { + // TODO: comment why not MT_ABSENT newArray[zindex] = MlrvalFromString("") } *array = newArray diff --git a/go/todo.txt b/go/todo.txt index 381179b6d..0609f9007 100644 --- a/go/todo.txt +++ b/go/todo.txt @@ -6,6 +6,22 @@ TOP OF LIST: o profile mlr --j2x cat mappings.json o golang static-analysis tool -- ? +* 2121 case: + o ../c/mlr --from s put '$z=1+""' + o ../go/mlr --from s put '$z=1+""' + o array auto-extend: + - fill with absent is not ok + > Miller internal coding error: absent-values should not have been assigned + > cmt mlrval_new.go + - fill with empty results in these situations :( + > https://miller.readthedocs.io/en/latest/reference.html#null-data-empty-and-absent + "Empty values are explicit in the data so they should explicitly affect + accumulations: mlr put '@sum += $x' should accumulate numeric x values + into the sum but an empty x, when encountered in the input data stream, + should make the sum non-numeric." + - fill with ... use JSON_NULL here? + o needs doc-ent for JSON_NULL -- only for JSON user data only only ... except for this + * blockers: o repifs, for nidx & pprint both o --d2n commawrong