diff options
author | Ayke van Laethem <[email protected]> | 2019-01-13 17:05:00 +0100 |
---|---|---|
committer | Ayke van Laethem <[email protected]> | 2019-01-21 22:09:37 +0100 |
commit | 2e4dd09bbccf5dd8d3908b98887bbd2320346a85 (patch) | |
tree | 00eb010c13b1da80021dbeb3f94bdaf517c4cf9f /testdata/channel.txt | |
parent | 602c2647490fc2352ff283da59a6b537c8e8cacc (diff) | |
download | tinygo-2e4dd09bbccf5dd8d3908b98887bbd2320346a85.tar.gz tinygo-2e4dd09bbccf5dd8d3908b98887bbd2320346a85.zip |
compiler: add support for channel operations
Support for channels is not complete. The following pieces are missing:
* Channels with values bigger than int. An int in TinyGo can always
contain at least a pointer, so pointers are okay to send.
* Buffered channels.
* The select statement.
Diffstat (limited to 'testdata/channel.txt')
-rw-r--r-- | testdata/channel.txt | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/testdata/channel.txt b/testdata/channel.txt new file mode 100644 index 000000000..eaffd7330 --- /dev/null +++ b/testdata/channel.txt @@ -0,0 +1,21 @@ +len, cap of channel: 0 0 +recv from open channel: 1 true +received num: 2 +received num: 3 +slept +received num: 4 +received num: 5 +received num: 6 +received num: 7 +received num: 8 +recv from closed channel: 0 false +got n: 10 +got n: 11 +got n: 10 +got n: 11 +got n: 10 +got n: 11 +sum: 25 +sum: 29 +sum: 33 +sum(100): 4950 |