Revision: 50624
          http://brlcad.svn.sourceforge.net/brlcad/?rev=50624&view=rev
Author:   starseeker
Date:     2012-05-21 20:52:13 +0000 (Mon, 21 May 2012)
Log Message:
-----------
Allow negative numbers as values instead of treating them as flags.

Modified Paths:
--------------
    brlcad/trunk/src/tclscripts/util/getopt.tcl

Modified: brlcad/trunk/src/tclscripts/util/getopt.tcl
===================================================================
--- brlcad/trunk/src/tclscripts/util/getopt.tcl 2012-05-21 20:37:32 UTC (rev 
50623)
+++ brlcad/trunk/src/tclscripts/util/getopt.tcl 2012-05-21 20:52:13 UTC (rev 
50624)
@@ -110,7 +110,9 @@
 }
 
 proc getopt::isShortOpt {o} {
-        return [regexp {^-[a-zA-Z0-9]+} $o]
+       set is_short 0
+       if {[regexp {^-[a-zA-Z0-9]+} $o] && ![regexp {^-[0-9]+} $o]} {set 
is_short 1}
+        return $is_short
 }
 
 proc getopt::isLongOpt {o} {

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to