Commit Graph

6 Commits

Author SHA1 Message Date
sjg d388dcd1a3 Implement :[] modifier to allow picking a range of words out of a variable.
Also :tW and a W flag to :C and :S to allow treating value as a single word.
Add unit tests for the above, and fix some corner cases.
Based on patches supplied by Alan Barrett <apb@cequrux.com>
2003-09-27 21:29:37 +00:00
sjg 3dfdacc170 Avoid \a as a test of invalid separator, since if we make ksh the default
shell, we get different results.  \x seems safe.
2003-08-01 04:57:20 +00:00
sjg 1ebbf35953 Test behavior of commandline variable assignments. 2003-07-31 00:46:15 +00:00
sjg b806b12f2d First bug picked up by the unit tests - delim wasn't always initialized.
Avoid putting '\' in test case script lines since shell's like that on
SunOS insist on interpreting them.
2003-07-29 08:44:41 +00:00
sjg e3cd1dc68c Use single quotes to protect everything from shell's that might
alter the results.
2003-07-29 08:16:01 +00:00
sjg db7ca3c993 Fix parsing bug for :ts - patch from Alan Barrett <apb@cequrux.com>
Also add simple unit-test jig (regress/usr.bin/make will use it too)
but having it local here makes inclusion in bmake simpler.
2003-07-28 22:52:10 +00:00