diff options
Diffstat (limited to 'html/001help.cc.html')
-rw-r--r-- | html/001help.cc.html | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/html/001help.cc.html b/html/001help.cc.html index 16025a66..eeebfa25 100644 --- a/html/001help.cc.html +++ b/html/001help.cc.html @@ -81,7 +81,7 @@ if ('onhashchange' in window) { <span id="L18" class="LineNr"> 18 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">"Examples:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L19" class="LineNr"> 19 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To load files and run 'main':</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L20" class="LineNr"> 20 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu file1.mu file2.mu ...</span><span class="cSpecial">\n</span><span class="Constant">"</span> -<span id="L21" class="LineNr"> 21 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run 'main' and dump a <a href='003trace.cc.html#L161'>trace</a> of all operations at the <a href='003trace.cc.html#L197'>end</a>:</span><span class="cSpecial">\n</span><span class="Constant">"</span> +<span id="L21" class="LineNr"> 21 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run 'main' and <a href='003trace.cc.html#L120'>dump</a> a <a href='003trace.cc.html#L167'>trace</a> of all operations at the <a href='003trace.cc.html#L203'>end</a>:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L22" class="LineNr"> 22 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu --trace file1.mu file2.mu ...</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L23" class="LineNr"> 23 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run all tests:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L24" class="LineNr"> 24 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu test</span><span class="cSpecial">\n</span><span class="Constant">"</span> @@ -89,7 +89,7 @@ if ('onhashchange' in window) { <span id="L26" class="LineNr"> 26 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu test file1.mu file2.mu ...</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L27" class="LineNr"> 27 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run a single Mu <a href='050scenario.cc.html#L57'>scenario</a>:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L28" class="LineNr"> 28 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu test file1.mu file2.mu ... <a href='050scenario.cc.html#L57'>scenario</a></span><span class="cSpecial">\n</span><span class="Constant">"</span> -<span id="L29" class="LineNr"> 29 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run a single Mu <a href='050scenario.cc.html#L57'>scenario</a> and dump a <a href='003trace.cc.html#L161'>trace</a> at the <a href='003trace.cc.html#L197'>end</a>:</span><span class="cSpecial">\n</span><span class="Constant">"</span> +<span id="L29" class="LineNr"> 29 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To run a single Mu <a href='050scenario.cc.html#L57'>scenario</a> and <a href='003trace.cc.html#L120'>dump</a> a <a href='003trace.cc.html#L167'>trace</a> at the <a href='003trace.cc.html#L203'>end</a>:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L30" class="LineNr"> 30 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu --trace test file1.mu file2.mu ... <a href='050scenario.cc.html#L57'>scenario</a></span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L31" class="LineNr"> 31 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To load files and run only the tests in explicitly loaded files (for apps):</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L32" class="LineNr"> 32 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu --test-only-app test file1.mu file2.mu ...</span><span class="cSpecial">\n</span><span class="Constant">"</span> @@ -103,7 +103,7 @@ if ('onhashchange' in window) { <span id="L40" class="LineNr"> 40 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu --profile file_or_dir1 file_or_dir2 ...</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L41" class="LineNr"> 41 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" this slices and dices time spent in various profile.* output files</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L42" class="LineNr"> 42 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">"</span><span class="cSpecial">\n</span><span class="Constant">"</span> -<span id="L43" class="LineNr"> 43 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To browse a <a href='003trace.cc.html#L161'>trace</a> generated by a previous run:</span><span class="cSpecial">\n</span><span class="Constant">"</span> +<span id="L43" class="LineNr"> 43 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" To browse a <a href='003trace.cc.html#L167'>trace</a> generated by a previous run:</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L44" class="LineNr"> 44 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><< <span class="Constant">" mu browse-trace file</span><span class="cSpecial">\n</span><span class="Constant">"</span> <span id="L45" class="LineNr"> 45 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span><span class="Delimiter">;</span> <span id="L46" class="LineNr"> 46 </span> <span class="Identifier">return</span> <span class="Constant">0</span><span class="Delimiter">;</span> @@ -139,9 +139,9 @@ if ('onhashchange' in window) { <span id="L76" class="LineNr"> 76 </span> <span id="L77" class="LineNr"> 77 </span><span class="Normal">bool</span> <a href='001help.cc.html#L77'>starts_with</a><span class="Delimiter">(</span><span class="Normal">const</span> string& s<span class="Delimiter">,</span> <span class="Normal">const</span> string& pat<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span id="L78" class="LineNr"> 78 </span> string::const_iterator a=s<span class="Delimiter">.</span>begin<span class="Delimiter">(),</span> b=pat<span class="Delimiter">.</span>begin<span class="Delimiter">();</span> -<span id="L79" class="LineNr"> 79 </span> <span class="Normal">for</span> <span class="Delimiter">(</span><span class="Comment">/*</span><span class="Comment">nada</span><span class="Comment">*/</span><span class="Delimiter">;</span> a!=s<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">()</span> && b!=pat<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> ++a<span class="Delimiter">,</span> ++b<span class="Delimiter">)</span> +<span id="L79" class="LineNr"> 79 </span> <span class="Normal">for</span> <span class="Delimiter">(</span><span class="Comment">/*</span><span class="Comment">nada</span><span class="Comment">*/</span><span class="Delimiter">;</span> a!=s<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">()</span> && b!=pat<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">();</span> ++a<span class="Delimiter">,</span> ++b<span class="Delimiter">)</span> <span id="L80" class="LineNr"> 80 </span> <span class="Conceal">¦</span> <span class="Normal">if</span> <span class="Delimiter">(</span>*a != *b<span class="Delimiter">)</span> <span class="Identifier">return</span> <span class="Constant">false</span><span class="Delimiter">;</span> -<span id="L81" class="LineNr"> 81 </span> <span class="Identifier">return</span> b == pat<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> +<span id="L81" class="LineNr"> 81 </span> <span class="Identifier">return</span> b == pat<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">();</span> <span id="L82" class="LineNr"> 82 </span><span class="Delimiter">}</span> <span id="L83" class="LineNr"> 83 </span> <span id="L84" class="LineNr"> 84 </span><span class="Comment">//: I'll throw some style conventions here for want of a better place for them.</span> @@ -273,12 +273,12 @@ if ('onhashchange' in window) { <span id="L210" class="LineNr">210 </span><span class="Comment">// from <a href="http://stackoverflow.com/questions/152643/idiomatic-c-for-reading-from-a-const-map">http://stackoverflow.com/questions/152643/idiomatic-c-for-reading-from-a-const-map</a></span> <span id="L211" class="LineNr">211 </span><span class="Normal">template</span><<span class="Normal">typename</span> T> <span class="Normal">typename</span> T::mapped_type& get<span class="Delimiter">(</span>T& map<span class="Delimiter">,</span> <span class="Normal">typename</span> T::key_type <span class="Normal">const</span>& key<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span id="L212" class="LineNr">212 </span> <span class="Normal">typename</span> T::iterator iter<span class="Delimiter">(</span>map<span class="Delimiter">.</span>find<span class="Delimiter">(</span>key<span class="Delimiter">));</span> -<span id="L213" class="LineNr">213 </span> assert<span class="Delimiter">(</span>iter != map<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">());</span> +<span id="L213" class="LineNr">213 </span> assert<span class="Delimiter">(</span>iter != map<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">());</span> <span id="L214" class="LineNr">214 </span> <span class="Identifier">return</span> iter<span class="Delimiter">-></span>second<span class="Delimiter">;</span> <span id="L215" class="LineNr">215 </span><span class="Delimiter">}</span> <span id="L216" class="LineNr">216 </span><span class="Normal">template</span><<span class="Normal">typename</span> T> <span class="Normal">typename</span> T::mapped_type <span class="Normal">const</span>& get<span class="Delimiter">(</span><span class="Normal">const</span> T& map<span class="Delimiter">,</span> <span class="Normal">typename</span> T::key_type <span class="Normal">const</span>& key<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span id="L217" class="LineNr">217 </span> <span class="Normal">typename</span> T::const_iterator iter<span class="Delimiter">(</span>map<span class="Delimiter">.</span>find<span class="Delimiter">(</span>key<span class="Delimiter">));</span> -<span id="L218" class="LineNr">218 </span> assert<span class="Delimiter">(</span>iter != map<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">());</span> +<span id="L218" class="LineNr">218 </span> assert<span class="Delimiter">(</span>iter != map<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">());</span> <span id="L219" class="LineNr">219 </span> <span class="Identifier">return</span> iter<span class="Delimiter">-></span>second<span class="Delimiter">;</span> <span id="L220" class="LineNr">220 </span><span class="Delimiter">}</span> <span id="L221" class="LineNr">221 </span><span class="Normal">template</span><<span class="Normal">typename</span> T> <span class="Normal">typename</span> T::mapped_type <span class="Normal">const</span>& <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>T& map<span class="Delimiter">,</span> <span class="Normal">typename</span> T::key_type <span class="Normal">const</span>& key<span class="Delimiter">,</span> <span class="Normal">typename</span> T::mapped_type <span class="Normal">const</span>& value<span class="Delimiter">)</span> <span class="Delimiter">{</span> @@ -287,7 +287,7 @@ if ('onhashchange' in window) { <span id="L224" class="LineNr">224 </span> <span class="Identifier">return</span> value<span class="Delimiter">;</span> <span id="L225" class="LineNr">225 </span><span class="Delimiter">}</span> <span id="L226" class="LineNr">226 </span><span class="Normal">template</span><<span class="Normal">typename</span> T> <span class="Normal">bool</span> contains_key<span class="Delimiter">(</span>T& map<span class="Delimiter">,</span> <span class="Normal">typename</span> T::key_type <span class="Normal">const</span>& key<span class="Delimiter">)</span> <span class="Delimiter">{</span> -<span id="L227" class="LineNr">227 </span> <span class="Identifier">return</span> map<span class="Delimiter">.</span>find<span class="Delimiter">(</span>key<span class="Delimiter">)</span> != map<span class="Delimiter">.</span><a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> +<span id="L227" class="LineNr">227 </span> <span class="Identifier">return</span> map<span class="Delimiter">.</span>find<span class="Delimiter">(</span>key<span class="Delimiter">)</span> != map<span class="Delimiter">.</span><a href='003trace.cc.html#L203'>end</a><span class="Delimiter">();</span> <span id="L228" class="LineNr">228 </span><span class="Delimiter">}</span> <span id="L229" class="LineNr">229 </span><span class="Normal">template</span><<span class="Normal">typename</span> T> <span class="Normal">typename</span> T::mapped_type& <a href='001help.cc.html#L229'>get_or_insert</a><span class="Delimiter">(</span>T& map<span class="Delimiter">,</span> <span class="Normal">typename</span> T::key_type <span class="Normal">const</span>& key<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span id="L230" class="LineNr">230 </span> <span class="Identifier">return</span> map[key]<span class="Delimiter">;</span> |