4 ms·
I just saw two screenshots and already don't like it. It seems its output sacrifices information for the sake of... tabulation? presentation? I don't know, but
by tangus 4y ago
I just saw two screenshots and already don't like it. It seems its output sacrifices information for the sake of... tabulation? presentation? I don't know, but it's the wrong call.
Maybe it wasn't intended, but having that screenshot as the tool's showcase sends a message to me.
- toomanydoubts 4y agoI don't think you have fully understood the screenshots. The first one shows an example source code, the second one shows the byte code generated from the source code of calling the print function. This is the bytecode that will be executed when the program is executed. It has nothing to do with the output of the program itself.
- tangus 4y agoI understood them. Take a look at the constants table, indices 0, 2, 4, 6: the column "Value" is truncated. Now imagine you have trouble with an ana function and want to take a look at the generated bytecode. Would you rather have the columns perfected aligned and try to guess the loaded function name from its first letter? I see several HNers with downvote capacity would, which is a surprise...
- klibertp 4y agoGuilty as charged: https://klibert.pl/statics/awesome-taglist-shown.png https://klibert.pl/statics/awesome-taglist-shown.png - see `make_wibox_conta[iner, obviously]`. It happens when you don't want, or can't, compute the needed column width before printing. It's just a lot less code to pick a number and leave the formatting for later. The same problem bit me multiple times when pretty-printing nested data structures. There's often an arbitrary limit to the depth the printer recurse to and/or the number of elements that get displayed, with the rest hidden behind "..." or something similar. No matter what number you pick, sooner or later you're going to get a case where you miss a really interesting/important piece of information because it got hidden. And if you try to change the default, you're going to get a case where you miss important info because you couldn't be bothered to scroll that far up... Anyway: you're right, this is bad, but also pretty common. Though in this particular case it's really bad, because most of the column width is taken by irrelevant data. Replacing `<function '` with λ would already help a lot.