[ros-diffs] [royce] 17956: a few more tests to clarify parsing oddities based on my playing around

royce at svn.reactos.com royce at svn.reactos.com
Wed Sep 21 03:23:53 CEST 2005


a few more tests to clarify parsing oddities based on my playing around
Modified: trunk/reactos/subsys/system/cmd/seta_test.cmd
  _____  

Modified: trunk/reactos/subsys/system/cmd/seta_test.cmd
--- trunk/reactos/subsys/system/cmd/seta_test.cmd	2005-09-21
01:22:56 UTC (rev 17955)
+++ trunk/reactos/subsys/system/cmd/seta_test.cmd	2005-09-21
01:23:44 UTC (rev 17956)
@@ -1,6 +1,8 @@

- at echo off
- at rem the next line illustrates a bug in our cmd
-set /a a=5%2
+ at rem echo off
+
+ at rem the next line reexecutes the script without params if it was
called with params, else we'll get false failures
+ at if not "%1"=="" seta_test.cmd
+
 @rem the next two lines illustrate bug in existing if code
 if not "=="=="==" goto failure
 if "=="=="==" goto next1
@@ -26,6 +28,10 @@
 if not "%a%"=="200" goto failure
 set /a a=42%%9
 if not "%a%"=="6" goto failure
+set /a a=5%2
+if not "%a%"=="5" goto failure
+set /a a=42^%13
+if not "%a%"=="423" goto failure
 set /a a=7+9
 if not "%a%"=="16" goto failure
 set /a a=9-7
@@ -36,6 +42,8 @@
 if not "%a%"=="9" goto failure
 set /a a=42^&9
 if not "%a%"=="8" goto failure
+set /a a=32^9
+if not "%a%"=="329" goto failure
 set /a a=32^^9
 if not "%a%"=="41" goto failure
 set /a a=10^|22
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-diffs/attachments/20050921/5d99ff71/attachment.html


More information about the Ros-diffs mailing list