NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/59029: cut(1) -n argument doesn't work (presently unsupported, though documented)



The following reply was made to PR bin/59029; it has been noted by GNATS.

From: "David H. Gutteridge" <david%gutteridge.ca@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: 
Subject: Re: bin/59029: cut(1) -n argument doesn't work (presently
 unsupported, though documented)
Date: Wed, 12 Feb 2025 21:53:38 -0500

 The existing NetBSD code is a touch ungainly to modify to handle this
 context (depending on the approach) since it uses a preprocessor
 "trick", and would be uglier with macro-wrapped conditionals. Comparing
 other implementations, I see OpenBSD simply made "cut -b -n" be handled
 as "cut -c". FreeBSD, on the other hand, uses a distinct function
 "b_n_cut" with unique logic. (Neither offer anything useful I can find
 for test suite content. It would be good to find an illustration of
 where the two approaches give varied output.)
 


Home | Main Index | Thread Index | Old Index