gipeda icon indicating copy to clipboard operation
gipeda copied to clipboard

Feature request: Add Boolean number type

Open christetreault opened this issue 10 years ago • 3 comments

Might it be useful to add a BooleanNT to data NumberType?

Our test suite produces a .csv of the form [name],[text execution time],[test successful?], and we're currently just cutting off the success field in our log2csv. I think it might be useful to instead let the [test successful?] field be a separate benchmark.

I could just have that field be a small integer, and 0=false/1=true but I think it'd be cleaner to have a boolean. Additionally, it'd allow you to change how boolean values are represented in graphs and such if you cared to do such a thing in the future.

christetreault avatar Oct 05 '15 23:10 christetreault

Regarding the question of what "less is better" for a boolean means, I propose the C definition of true=1, false=0, and that false < true.

Alternatively, I think "good/bad" is reasonable. Maybe make the specific word that appears configurable? (i.e. success/failure, in range/out of range, etc...)

christetreault avatar Oct 05 '15 23:10 christetreault

I think a configurable two-value type is too complicated for what it provides .good and bad would be generic enough (and might be displayed by :smile: and :cry: or :white_check_mark: and :negative_squared_cross_mark: or some other pictogram anyways).

nomeata avatar Oct 06 '15 09:10 nomeata

Fair enough, works for me!

christetreault avatar Oct 06 '15 15:10 christetreault