No subject


Sun Dec 8 17:39:16 PST 2013


<h3>Modified Paths</h3>
<ul>
<li><a href=3D"#trunkbasesrcmacports10macportstcl">trunk/base/src/macport=
s1.0/macports.tcl</a></li>
<li><a href=3D"#trunkbasesrcmacports10macports_dlisttcl">trunk/base/src/m=
acports1.0/macports_dlist.tcl</a></li>
<li><a href=3D"#trunkbasesrcmacports10macports_utiltcl">trunk/base/src/ma=
cports1.0/macports_util.tcl</a></li>
<li><a href=3D"#trunkbasesrcmacports10teststesttcl">trunk/base/src/macpor=
ts1.0/tests/test.tcl</a></li>
</ul>

</div>
<div id=3D"patch">
<h3>Diff</h3>
<a id=3D"trunkbasesrcmacports10macportstcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/macports1.0/macports.=
tcl (116444 =3D> 116445)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/macports1.0/macports.tcl	2014-01-=
25 16:44:00 UTC (rev 116444)
+++ trunk/base/src/macports1.0/macports.tcl	2014-01-25 16:46:33 UTC (rev =
116445)
</span><span class=3D"lines">@@ -1536,7 +1536,7 @@
</span><span class=3D"cx">     set protocol [macports::getprotocol $url]
</span><span class=3D"cx">     switch -- $protocol {
</span><span class=3D"cx">         file {
</span><del>-            set path [file normalize [string range $url [exp=
r {[string length $protocol] + 3}] end]]
</del><ins>+            set path [file normalize [string range $url [stri=
ng length $protocol]+3 end]]
</ins><span class=3D"cx">             if {![file isfile $path]} {
</span><span class=3D"cx">                 # the URL points to a local di=
rectory
</span><span class=3D"cx">                 return $path
</span><span class=3D"lines">@@ -2653,7 +2653,7 @@
</span><span class=3D"cx">                             } else {
</span><span class=3D"cx">                                 set compres [s=
tring compare -nocase $pattern $target]
</span><span class=3D"cx">                             }
</span><del>-                            set matchres [expr 0 =3D=3D $com=
pres]
</del><ins>+                            set matchres [expr {0 =3D=3D $com=
pres}]
</ins><span class=3D"cx">                         }
</span><span class=3D"cx">                         glob {
</span><span class=3D"cx">                             if {$case_sensitiv=
e eq yes} {
</span><span class=3D"lines">@@ -4012,7 +4012,7 @@
</span><span class=3D"cx">         # we have to force the uninstall in ca=
se of dependents
</span><span class=3D"cx">         set force_cur [info exists options(por=
ts_force)]
</span><span class=3D"cx">         set options(ports_force) yes
</span><del>-        set existing_epoch [lindex [lindex [registry::instal=
led $newname ${version_in_tree}_${revision_in_tree}$portinfo(canonical_ac=
tive_variants)] 0] 5]
</del><ins>+        set existing_epoch [lindex [registry::installed $newn=
ame ${version_in_tree}_${revision_in_tree}$portinfo(canonical_active_vari=
ants)] 0 5]
</ins><span class=3D"cx">         set newregref [registry::open_entry $ne=
wname $version_in_tree $revision_in_tree $portinfo(canonical_active_varia=
nts) $existing_epoch]
</span><span class=3D"cx">         if {$is_dryrun eq {yes}} {
</span><span class=3D"cx">             ui_msg &quot;Skipping uninstall $n=
ewname @${version_in_tree}_${revision_in_tree}$portinfo(canonical_active_=
variants) (dry run)&quot;
</span></span></pre></div>
<a id=3D"trunkbasesrcmacports10macports_dlisttcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/macports1.0/macports_=
dlist.tcl (116444 =3D> 116445)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/macports1.0/macports_dlist.tcl	20=
14-01-25 16:44:00 UTC (rev 116444)
+++ trunk/base/src/macports1.0/macports_dlist.tcl	2014-01-25 16:46:33 UTC=
 (rev 116445)
</span><span class=3D"lines">@@ -292,7 +292,7 @@
</span><span class=3D"cx"> =09
</span><span class=3D"cx"> 	# Do a pre-run seeing if any items automagica=
lly
</span><span class=3D"cx"> 	# can evaluate to true.
</span><del>-	if {$testcond !=3D &quot;&quot;} {
</del><ins>+	if {$testcond ne &quot;&quot;} {
</ins><span class=3D"cx"> 		foreach ditem $dlist {
</span><span class=3D"cx"> 			if {[eval &quot;expr \[\$testcond \$ditem\]=
 =3D=3D 1&quot;]} {
</span><span class=3D"cx"> 				foreach token [ditem_key $ditem provides] =
{
</span><span class=3D"lines">@@ -323,7 +323,7 @@
</span><span class=3D"cx"> 			if {$result =3D=3D {}} { set result 0 }
</span><span class=3D"cx"> 		=09
</span><span class=3D"cx"> 			foreach token [ditem_key $ditem provides] {
</span><del>-				set statusdict($token) [expr $result =3D=3D 0]
</del><ins>+				set statusdict($token) [expr {$result =3D=3D 0}]
</ins><span class=3D"cx"> 			}
</span><span class=3D"cx"> 		=09
</span><span class=3D"cx"> 			# Abort if we're not allowed to fail
</span></span></pre></div>
<a id=3D"trunkbasesrcmacports10macports_utiltcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/macports1.0/macports_=
util.tcl (116444 =3D> 116445)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/macports1.0/macports_util.tcl	201=
4-01-25 16:44:00 UTC (rev 116444)
+++ trunk/base/src/macports1.0/macports_util.tcl	2014-01-25 16:46:33 UTC =
(rev 116445)
</span><span class=3D"lines">@@ -98,8 +98,8 @@
</span><span class=3D"cx">             if {$size =3D=3D 0} {
</span><span class=3D"cx">                 set badrange? 1
</span><span class=3D"cx">             }
</span><del>-        } elseif {[string match end-* $idx] &amp;&amp; [stri=
ng is integer -strict [string range $idx 4 end]]} {
-            set i [expr $size - 1 - [string range $idx 4 end]]
</del><ins>+        } elseif {[string match &quot;end-*&quot; $idx] &amp;=
&amp; [string is integer -strict [string range $idx 4 end]]} {
+            set i [expr {$size - 1 - [string range $idx 4 end]}]
</ins><span class=3D"cx">             if {$i &lt; 0 || $i &gt;=3D $size} =
{
</span><span class=3D"cx">                 set badrange? 1
</span><span class=3D"cx">             }
</span></span></pre></div>
<a id=3D"trunkbasesrcmacports10teststesttcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/macports1.0/tests/tes=
t.tcl (116444 =3D> 116445)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/macports1.0/tests/test.tcl	2014-0=
1-25 16:44:00 UTC (rev 116444)
+++ trunk/base/src/macports1.0/tests/test.tcl	2014-01-25 16:46:33 UTC (re=
v 116445)
</span><span class=3D"lines">@@ -15,7 +15,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> proc print_help {arg} {
</span><del>-    if { $arg =3D=3D &quot;tests&quot; } {
</del><ins>+    if { $arg eq &quot;tests&quot; } {
</ins><span class=3D"cx">         puts &quot;The list of available tests =
is:&quot;
</span><span class=3D"cx"> 	cd tests
</span><span class=3D"cx"> 	set test_suite [glob *.test]
</span><span class=3D"lines">@@ -34,11 +34,11 @@
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Process args
</span><span class=3D"cx"> foreach arg $argv {
</span><del>-    if { $arg =3D=3D &quot;-h&quot; || $arg =3D=3D &quot;-he=
lp&quot; } {
</del><ins>+    if { $arg eq &quot;-h&quot; || $arg eq &quot;-help&quot; =
} {
</ins><span class=3D"cx">         print_help &quot;&quot;
</span><span class=3D"cx">         exit 0
</span><del>-    } elseif { $arg =3D=3D &quot;-debug&quot; } {
-        set index [expr [lsearch $argv $arg] + 1]
</del><ins>+    } elseif { $arg eq &quot;-debug&quot; } {
+        set index [expr {[lsearch $argv $arg] + 1}]
</ins><span class=3D"cx">         set level [lindex $argv $index]
</span><span class=3D"cx">         if { $level &gt;=3D 0 &amp;&amp; $leve=
l &lt;=3D 3 } {
</span><span class=3D"cx">             append arguments &quot;-debug &quo=
t; $level
</span><span class=3D"lines">@@ -46,32 +46,32 @@
</span><span class=3D"cx">             puts &quot;Invalid debug level.&qu=
ot;
</span><span class=3D"cx">             exit 1
</span><span class=3D"cx">         }
</span><del>-    } elseif { $arg =3D=3D &quot;-t&quot; } {
-        set index [expr [lsearch $argv $arg] + 1]
</del><ins>+    } elseif { $arg eq &quot;-t&quot; } {
+        set index [expr {[lsearch $argv $arg] + 1}]
</ins><span class=3D"cx">         set test_name [lindex $argv $index]
</span><span class=3D"cx">         set no 0
</span><span class=3D"cx"> 	cd tests
</span><span class=3D"cx"> 	set test_suite [glob *.test]
</span><span class=3D"cx">         foreach test $test_suite {
</span><span class=3D"cx">             if { $test_name !=3D $test } {
</span><del>-                set no [expr $no + 1]
</del><ins>+                set no [expr {$no + 1}]
</ins><span class=3D"cx">             }
</span><span class=3D"cx">         }
</span><span class=3D"cx">         if { $no =3D=3D [llength $test_suite] =
} {
</span><span class=3D"cx">             print_help tests
</span><span class=3D"cx">             exit 1
</span><span class=3D"cx">         }
</span><del>-    } elseif { $arg =3D=3D &quot;-l&quot; } {
</del><ins>+    } elseif { $arg eq &quot;-l&quot; } {
</ins><span class=3D"cx">         print_help tests
</span><span class=3D"cx">         exit 0
</span><del>-    } elseif { $arg =3D=3D &quot;-nocolor&quot; } {
</del><ins>+    } elseif { $arg eq &quot;-nocolor&quot; } {
</ins><span class=3D"cx">         set color_out &quot;no&quot;
</span><span class=3D"cx">     }
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Run tests
</span><del>-if { $test_name !=3D &quot;&quot;} {
</del><ins>+if { $test_name ne &quot;&quot;} {
</ins><span class=3D"cx">     set result [eval exec $tcl $test_name $argu=
ments 2&gt;@stderr]
</span><span class=3D"cx">     puts $result
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -104,7 +104,7 @@
</span><span class=3D"cx">         if { $fail !=3D 0 } { set err &quot;ye=
s&quot; }
</span><span class=3D"cx">=20
</span><span class=3D"cx">         set out &quot;&quot;
</span><del>-        if { ($fail !=3D 0 || $skip !=3D 0) &amp;&amp; $colo=
r_out =3D=3D &quot;&quot; } {
</del><ins>+        if { ($fail !=3D 0 || $skip !=3D 0) &amp;&amp; $color=
_out eq &quot;&quot; } {
</ins><span class=3D"cx">             # Color failed tests.
</span><span class=3D"cx">             append out &quot;\x1b\[1;31mTotal:=
&quot; $total &quot; Passed:&quot; $pass &quot; Failed:&quot; $fail &quot=
; Skipped:&quot; $skip &quot;  \x1b\[0m&quot; $test
</span><span class=3D"cx">         } else {
</span><span class=3D"lines">@@ -119,13 +119,13 @@
</span><span class=3D"cx">             puts $out
</span><span class=3D"cx">         }
</span><span class=3D"cx"> 	if { $fail !=3D 0 } {
</span><del>-	    set end [expr [string first $test $result 0] - 1]
</del><ins>+	    set end [expr {[string first $test $result 0] - 1}]
</ins><span class=3D"cx"> 	    puts [string range $result 0 $end]
</span><span class=3D"cx"> 	}
</span><span class=3D"cx">     }
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Return 1 if errors were found.
</span><del>-if {$err !=3D &quot;&quot;} { exit 1 }
</del><ins>+if {$err ne &quot;&quot;} { exit 1 }
</ins><span class=3D"cx">=20
</span><span class=3D"cx"> return 0
</span></span></pre>
</div>
</div>

</body>
</html>
--UMW4ssTJ0G7--


More information about the macports-changes mailing list