From 0e86dca2ad2161e0180df719f99fe65c93706080 Mon Sep 17 00:00:00 2001 From: BCG Date: Wed, 1 Feb 2023 07:40:43 -0500 Subject: [PATCH] Adding reflect.Chan stubs --- src/reflect/chan.go | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 src/reflect/chan.go diff --git a/src/reflect/chan.go b/src/reflect/chan.go new file mode 100644 index 0000000000..67b4da81e7 --- /dev/null +++ b/src/reflect/chan.go @@ -0,0 +1,30 @@ +package reflect + +type SelectDir int + +const ( + _ SelectDir = iota + SelectSend // case Chan <- Send + SelectRecv // case <-Chan: + SelectDefault // default +) + +type SelectCase struct { + Dir SelectDir // direction of case + Chan Value // channel to use (for send or receive) + Send Value // value to send (for send) +} + +func Select(cases []SelectCase) (chosen int, recv Value, recvOK bool) { + panic("reflect.Select: unimplemented") +} + +func (v Value) Send(x Value) { + panic("reflect.Value.Send(): unimplemented") + +} + +func (v Value) Close() { + panic("reflect.Value.Close(): unimplemented") + +}