<html>
<head>
<style><!--
body {background-color:#ffffff;}
.file {border:1px solid #eeeeee;margin-top:1em;margin-bottom:1em;}
.pathname {font-family:monospace; float:right;}
.fileheader {margin-bottom:.5em;}
.diff {margin:0;}
.tasklist {padding:4px;border:1px dashed #000000;margin-top:1em;}
.tasklist ul {margin-top:0;margin-bottom:0;}
tr.alt {background-color:#eeeeee}
#added {background-color:#ddffdd;}
#addedchars {background-color:#99ff99;font-weight:bolder;}
tr.alt #added {background-color:#ccf7cc;}
#removed {background-color:#ffdddd;}
#removedchars {background-color:#ff9999;font-weight:bolder;}
tr.alt #removed {background-color:#f7cccc;}
#copied {background-color:#ccccff;}
tr.alt #copied {background-color:#bbbbf7;}
#info {color:#888888;}
#context {background-color:#eeeeee;}
td {padding-left:.3em;padding-right:.3em;}
tr.head {border-bottom-width:1px;border-bottom-style:solid;}
tr.head td {padding:0;padding-top:.2em;}
.task {background-color:#ffff00;}
.comment {white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;white-space:pre-wrap;word-wrap:break-word;padding:4px;border:1px dashed #000000;background-color:#ffffdd}
.error {color:red;}
hr {border-width:0px;height:2px;background:black;}
--></style>
</head>
<body>
<table cellspacing="0" cellpadding="0" border="0" rules="cols">
<tr class="head"><td colspan="5">Commit in <b><tt>as2api/trunk/as2api/lib</tt></b></td></tr>
<tr><td><tt><a href="#file1">api_loader.rb</a></tt> </td><td></td><td align="right" id="added">+11</td><td align="right" id="removed">-11</td><td nowrap="nowrap" align="center">373 -> 374</td></tr>
<tr class="alt"><td><tt><a href="#file2">doc_comment.rb</a></tt> </td><td></td><td align="right" id="added">+1</td><td align="right" id="removed">-1</td><td nowrap="nowrap" align="center">373 -> 374</td></tr>
<tr><td><tt>output/diff/<a href="#file3">api_deserializer.rb</a></tt> </td><td></td><td align="right" id="added">+2</td><td align="right" id="removed">-2</td><td nowrap="nowrap" align="center">373 -> 374</td></tr>
<tr class="alt"><td><tt>output/html/<a href="#file4">html_framework.rb</a></tt> </td><td></td><td align="right" id="added">+14</td><td align="right" id="removed">-6</td><td nowrap="nowrap" align="center">373 -> 374</td></tr>
<tr><td></td><td></td><td align="right" id="added">+28</td><td align="right" id="removed">-20</td><td></td></tr>
</table>
<small id="info">4 modified files</small><br />
<pre class="comment">
Can't use MethodRef vs. FieldRef, as we often don't know up front which kind of member we'll have.
i.e. Doc comments can refer to '#foo', and this might be a field or a method.
Hence we have a MemeberRef, which could be either, and a MethodRef for when
the link in the doc comment contains parens, like '#foo()'.
Better, up-front reporting of miss-referencess still needed.
</pre>
<hr /><a name="file1" /><div class="file">
<span class="pathname">as2api/trunk/as2api/lib</span><br />
<div class="fileheader"><big><b>api_loader.rb</b></big> <small id="info">373 -> 374</small></div>
<pre class="diff"><small id="info">--- trunk/as2api/lib/api_loader.rb        2006-04-07 00:20:11 UTC (rev 373)
+++ trunk/as2api/lib/api_loader.rb        2006-04-07 00:28:10 UTC (rev 374)
@@ -376,8 +376,8 @@
</small></pre><pre class="diff" id="context"> MethodRef.new(self, method_name, lineno)
end
</pre><pre class="diff" id="removed">- def ref_field(field_name, lineno)
- FieldRef.new(self, field_name, lineno)
</pre><pre class="diff" id="added">+ def ref_member(member_name, lineno)
+ MemberRef.new(self, member_name, lineno)
</pre><pre class="diff" id="context"> end
def ==(o)
</pre><pre class="diff"><small id="info">@@ -398,7 +398,7 @@
</small></pre><pre class="diff" id="context">
# A reference, by name, to a member of a type, which may or may not actually
</pre><pre class="diff" id="removed">-# exist. See MethodRef and FieldRef for concrete implementations.
</pre><pre class="diff" id="added">+# exist.
</pre><pre class="diff" id="context"> class MemberRef
def initialize(type_ref, member_name, lineno)
@type_ref = type_ref
</pre><pre class="diff"><small id="info">@@ -424,6 +424,14 @@
</small></pre><pre class="diff" id="context"> # resolution
type_resolved? && !resolved_member.nil?
end
</pre><pre class="diff" id="added">+ def resolved_member
+ astype = @type_ref.resolved_type
+ if astype.respond_to?(:get_field_called)
+ field = astype.get_field_called(@member_name)
+ return field if field
+ end
+ return astype.get_method_called(@member_name)
+ end
</pre><pre class="diff" id="context">
def ==(o)
!o.nil? && member_name == o.member_name && type_local_name == o.type_local_name
</pre><pre class="diff"><small id="info">@@ -438,15 +446,7 @@
</small></pre><pre class="diff" id="context"> def resolved_member; resolved_method; end
end
</pre><pre class="diff" id="removed">-class FieldRef < MemberRef
- def resolved_field
- @type_ref.resolved_type.get_field_called(@member_name)
- end
</pre><pre class="diff" id="context">
</pre><pre class="diff" id="removed">- def resolved_member; resolved_field; end
-end
-
-
</pre><pre class="diff" id="context"> # Resolves type names to instances of TypeRef for a particular compilation
# unit (the same name could refer to different types in different compilation
# units).
</pre></div>
<hr /><a name="file2" /><div class="file">
<span class="pathname">as2api/trunk/as2api/lib</span><br />
<div class="fileheader"><big><b>doc_comment.rb</b></big> <small id="info">373 -> 374</small></div>
<pre class="diff"><small id="info">--- trunk/as2api/lib/doc_comment.rb        2006-04-07 00:20:11 UTC (rev 373)
+++ trunk/as2api/lib/doc_comment.rb        2006-04-07 00:28:10 UTC (rev 374)
@@ -336,7 +336,7 @@
</small></pre><pre class="diff" id="context"> if member_name =~ /\(/
        target_ref = type_ref.ref_method($`, lineno)
else
</pre><pre class="diff" id="removed">-        target_ref = type_ref.ref_<span id="removedchars">field</span>(member_name, lineno)
</pre><pre class="diff" id="added">+        target_ref = type_ref.ref_<span id="addedchars">member</span>(member_name, lineno)
</pre><pre class="diff" id="context"> end
else
target_ref = type_ref
</pre></div>
<hr /><a name="file3" /><div class="file">
<span class="pathname">as2api/trunk/as2api/lib/output/diff</span><br />
<div class="fileheader"><big><b>api_deserializer.rb</b></big> <small id="info">373 -> 374</small></div>
<pre class="diff"><small id="info">--- trunk/as2api/lib/output/diff/api_deserializer.rb        2006-04-07 00:20:11 UTC (rev 373)
+++ trunk/as2api/lib/output/diff/api_deserializer.rb        2006-04-07 00:28:10 UTC (rev 374)
@@ -176,7 +176,7 @@
</small></pre><pre class="diff" id="context">         when :method
         ref = type_ref.ref_method(member, nil)
        when :field
</pre><pre class="diff" id="removed">-         ref = type_ref.ref_<span id="removedchars">field</span>(member, nil)
</pre><pre class="diff" id="added">+         ref = type_ref.ref_<span id="addedchars">member</span>(member, nil)
</pre><pre class="diff" id="context">         else
         ref = type_ref
end
</pre><pre class="diff"><small id="info">@@ -198,7 +198,7 @@
</small></pre><pre class="diff" id="context">         when :method
         ref = type_ref.ref_method(member, nil)
        when :field
</pre><pre class="diff" id="removed">-         ref = type_ref.ref_<span id="removedchars">field</span>(member, nil)
</pre><pre class="diff" id="added">+         ref = type_ref.ref_<span id="addedchars">member</span>(member, nil)
</pre><pre class="diff" id="context">         else
         ref = type_ref
end
</pre></div>
<hr /><a name="file4" /><div class="file">
<span class="pathname">as2api/trunk/as2api/lib/output/html</span><br />
<div class="fileheader"><big><b>html_framework.rb</b></big> <small id="info">373 -> 374</small></div>
<pre class="diff"><small id="info">--- trunk/as2api/lib/output/html/html_framework.rb        2006-04-07 00:20:11 UTC (rev 373)
+++ trunk/as2api/lib/output/html/html_framework.rb        2006-04-07 00:28:10 UTC (rev 374)
@@ -367,11 +367,19 @@
</small></pre><pre class="diff" id="context"> end
end
</pre><pre class="diff" id="removed">- def link_field_ref(field_ref)
- if field_ref.resolved?
- link_field(field_ref.resolved_field)
</pre><pre class="diff" id="added">+ def link_field_or_method_ref(member_ref)
+ if member_ref.resolved?
+ member = member_ref.resolved_member
+ case member
+        when ASField
+         link_field(member)
+        when ASMethod
+         link_method(member)
+        else
+         raise "unhandled member type #{member.class.name}"
+ end
</pre><pre class="diff" id="context"> else
</pre><pre class="diff" id="removed">- html_span(field_ref.member_name, {"class"=>"unresolved field_name"})
</pre><pre class="diff" id="added">+ html_span(member_ref.member_name, {"class"=>"unresolved member_name"})
</pre><pre class="diff" id="context"> end
end
</pre><pre class="diff"><small id="info">@@ -468,8 +476,8 @@
</small></pre><pre class="diff" id="context"> link_type_ref(ref)
elsif ref.is_a?(MethodRef)
link_method_ref(ref)
</pre><pre class="diff" id="removed">- elsif ref.is_a?(FieldRef)
- link_field_ref(ref)
</pre><pre class="diff" id="added">+ elsif ref.is_a?(MemberRef)
+ link_field_or_method_ref(ref)
</pre><pre class="diff" id="context"> else
raise "unhandled ref type #{ref.class.name}"
end
</pre></div>
<center><small><a href="http://www.badgers-in-foil.co.uk/projects/cvsspam/" title="commit -> email">CVSspam</a> 0.2.12</small></center>
</body></html>