Don't include '...' to empty-dimensional matrices#174
Don't include '...' to empty-dimensional matrices#174flying-sheep merged 11 commits intoIRkernel:mainfrom
Conversation
|
this one also has a conflict now! |
|
Hmm, could you please add a test to check if they’re displayed correctly? The example you gave in #141 should probably not show NAs when there’s no actual rows, if I understood correctly. |
|
Appreciate your guidance on what a test should look like -- the main thing I had in mind when testing is to ensure there's no warning. Beyond that, I added the simple test: expect_match(repr(m), "A04[^A]*A07")Which checks that |
|
Yeah, maybe just add a check that the repr string is just one line for the zero-rows column (i.e. only the headers) |
|
beautiful, thank you! |
Closes #141.
Finally understood the code well enough to offer this simple fix.
Crucially, we don't need to worry about
omit='both'case because that implies both dimensions are non-empty (and, in fact, large). Also, passingNULLtorbind(),cbind(), just omits them, leading to the desired behavior without needing anelseclause.