about summary refs log tree commit diff
path: root/src/rt/rust_kernel.cpp
diff options
context:
space:
mode:
authorFelix S. Klock II <pnkfelix@pnkfx.org>2013-01-29 10:20:28 +0100
committerFelix S. Klock II <pnkfelix@pnkfx.org>2013-01-29 11:28:52 +0100
commit6cabe2b90226e2262c8c1937b604d9f2c6f14059 (patch)
tree1998ff99086b56d0655f37732b59631cd3c785f1 /src/rt/rust_kernel.cpp
parent88bec09e6345d64d334c6dc1ef4947b35c467373 (diff)
downloadrust-6cabe2b90226e2262c8c1937b604d9f2c6f14059.tar.gz
rust-6cabe2b90226e2262c8c1937b604d9f2c6f14059.zip
Fixed two examples of erroneous code so their errors match expectation.
1. In the first case, the previous code was failing during type inference
   due to mismatched structure.  Fix is to use the X structure at both
   points in the code.

2. In the second case, a naive transcription that subsitutes *nothing*
   in for the omitted statements signified by "..." will actually
   compile without an error.  Furthermore, any pure code could also be
   substituted for the ellipsis and the code would compile (as the
   text already states).  So to make the example more illustrative, it
   would be better to include an impure callback, which makes the
   potential for aliasing immediately obvious to the reader.
Diffstat (limited to 'src/rt/rust_kernel.cpp')
0 files changed, 0 insertions, 0 deletions