<p dir="auto">by <strong>RickySeltzer</strong>:</p>
<pre class="notranslate">The syntax for initializing arrays of byte arrays is excessively restrictive and very
inelegant and inconvenient.  Both of these ought to compile and do the obvious thing.

See Also <a href="https://golang.org/issue/6386" rel="nofollow">issue #6386</a>: <a href="http://code.google.com/p/go/issues/detail" rel="nofollow">http://code.google.com/p/go/issues/detail</a>\?id\=6386

There are TWO problems.
 I) Arrays of constants can not be declared const.
 II) The syntax requires peppering the source with REDUNDANT redeclarations of '[]byte' before each word.

    const epigram [][]byte = [][]byte {
    []byte("He"), []byte("who"), []byte("laughs"),
    []byte("last"), []byte("laughs"), []byte("best."),
    }

    var epigram2 [][]byte = [][]byte {
    "He", "who", "laughs",
    "last", "laughs", "best.",
    }

1. What is a short input program that triggers the error?
<a href="http://play.golang.org/p/g7A-bNLV7L" rel="nofollow">http://play.golang.org/p/g7A-bNLV7L</a>

2. What is the full compiler output?
prog.go:13: cannot use "He" (type string) as type []byte in array element
prog.go:13: cannot use "who" (type string) as type []byte in array element
prog.go:13: cannot use "laughs" (type string) as type []byte in array element
prog.go:14: cannot use "last" (type string) as type []byte in array element
prog.go:14: cannot use "laughs" (type string) as type []byte in array element
prog.go:14: cannot use "best." (type string) as type []byte in array element
prog.go:15: const initializer &lt;T&gt; literal is not a constant

3. What version of the compiler are you using?  (Run it with the -V flag.)
any</pre>
<pre class="notranslate">What steps will reproduce the problem?

We had two instances of a process stuck in an infinite loop. Probably in the same place.
Killing one with SIGQUIT gave stack traces for all goroutines and I could see the
problem.

Here's an abridged version of the stack dump. Not sure how to reproduce this reliably
yet.

SIGQUIT: quit
PC=0x418209
goroutine 1 [running]:

!!! This was empty !!!

goroutine 2 [syscall]:
ib._Cfunc_ibv_get_async_event(0x410ddc0, 0xf8481b2800)

goroutine 4 [runnable]:
syscall.Syscall6()
syscall.EpollWait(0xf80000000d, 0xf84004a170, 0xa0000000a, 0x2710, 0xc, ...)

goroutine 5 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf840003140, 0xf84000e060, 0xb)

goroutine 6 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf8400031e0, 0xf84000e060, 0xb)

goroutine 7 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf840003280, 0xf84000e060, 0xb)

goroutine 8 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf840003320, 0xf84000e060, 0xb)

goroutine 9 [select]:
actor.(*actor).run(0xf84852c930, 0x7fd115b8ef98)

goroutine 10 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf8400035a0, 0xf84000e060, 0xb)

goroutine 11 [chan receive]:
net.(*pollServer).WaitRead(0xf8481b5380, 0xf840003aa0, 0xf84000e060, 0xb)

goroutine 12 [sleep]:
time.Sleep(0x2540be400, 0x40049300)

goroutine 13 [runnable]:
created by addtimer
go/src/pkg/runtime/ztime_amd64.c:68

goroutine 14 [runnable]:
syscall.Syscall()
foo/syscall.Poll(0xf848547fa0, 0x100000001, 0x12a0, 0x0, 0x0, ...)

rax     0xfffffffffffffffc
rbx     0xac7e68
rcx     0xffffffffffffffff
rdx     0x0
rdi     0xac8708
rsi     0x0
rbp     0x7fd115b90f30
rsp     0x7fff5dee1c00
r8      0x0
r9      0x0
r10     0x0
r11     0x246
r12     0x7b9ce0
r13     0xa
r14     0x0
r15     0x0
rip     0x418209
rflags  0x246
cs      0x33
fs      0x0
gs      0x0

What is the expected output?

stacktraces for all goroutines

What do you see instead?

no stacktrace for the running goroutine #1

Which compiler are you using (5g, 6g, 8g, gccgo)?

6g

Which operating system are you using?

linux

Which revision are you using?  (hg identify)

tip</pre>