diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2016-10-23 19:45:36 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2016-10-23 19:56:28 -0700 |
commit | f918675c8b11adb80a83000a3a984e4ff3bdcf1b (patch) | |
tree | 2472316e3bf536e0bad76751c5f3504d029b8215 /html/channel.mu.html | |
parent | af7349d50c40e0604c9bb1e9a50aa1c3c0d407d8 (diff) | |
download | mu-f918675c8b11adb80a83000a3a984e4ff3bdcf1b.tar.gz |
3569
Update syntax highlighting to not color numeric locations like literals.
Diffstat (limited to 'html/channel.mu.html')
-rw-r--r-- | html/channel.mu.html | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/html/channel.mu.html b/html/channel.mu.html index 3970a8c2..a6dcc4f2 100644 --- a/html/channel.mu.html +++ b/html/channel.mu.html @@ -37,15 +37,15 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color <span class="Constant">local-scope</span> <span class="Constant">load-ingredients</span> <span class="Comment"># n = 0</span> - n:char<span class="Special"> <- </span>copy <span class="Constant">0</span> + n:char <span class="Special"><-</span> copy<span class="Constant"> 0</span> <span class="Delimiter">{</span> - done?:bool<span class="Special"> <- </span>lesser-than n, <span class="Constant">5</span> + done?:bool <span class="Special"><-</span> lesser-than n,<span class="Constant"> 5</span> <span class="muControl">break-unless</span> done? <span class="Comment"># other threads might get between these prints</span> $print <span class="Constant">[produce: ]</span>, n, <span class="Constant">[ </span> <span class="Constant">]</span> - sink<span class="Special"> <- </span>write sink, n - n<span class="Special"> <- </span>add n, <span class="Constant">1</span> + sink <span class="Special"><-</span> write sink, n + n <span class="Special"><-</span> add n,<span class="Constant"> 1</span> <span class="muControl">loop</span> <span class="Delimiter">}</span> close sink @@ -57,7 +57,7 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color <span class="Constant">load-ingredients</span> <span class="Delimiter">{</span> <span class="Comment"># read an integer from the channel</span> - n:char, eof?:bool, source<span class="Special"> <- </span>read source + n:char, eof?:bool, source <span class="Special"><-</span> read source <span class="muControl">break-if</span> eof? <span class="Comment"># other threads might get between these prints</span> $print <span class="Constant">[consume: ]</span>, n:char, <span class="Constant">[ </span> @@ -68,10 +68,10 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color <span class="muRecipe">def</span> main [ <span class="Constant">local-scope</span> - source:&:source:char, sink:&:sink:char<span class="Special"> <- </span>new-channel <span class="Constant">3/capacity</span> + source:&:source:char, sink:&:sink:char <span class="Special"><-</span> new-channel <span class="Constant">3/capacity</span> <span class="Comment"># create two background 'routines' that communicate by a channel</span> - routine1:num<span class="Special"> <- </span>start-running producer, sink - routine2:num<span class="Special"> <- </span>start-running consumer, source + routine1:num <span class="Special"><-</span> start-running producer, sink + routine2:num <span class="Special"><-</span> start-running consumer, source wait-for-routine routine1 wait-for-routine routine2 ] |