mirror of
https://github.com/golang/go
synced 2024-11-15 03:40:29 -07:00
6933d76a7e
This was missed as part of adding a top-level VARDEF for stack tracing (CL 134156). Fixes #28055 Change-Id: Id14748dfccb119197d788867d2ec6a3b3c9835cf Reviewed-on: https://go-review.googlesource.com/c/140304 Run-TryBot: Keith Randall <khr@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Alberto Donizetti <alb.donizetti@gmail.com>
17 lines
330 B
Go
17 lines
330 B
Go
// compile
|
|
|
|
// Copyright 2018 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
// Make sure VARDEF can be a top-level statement.
|
|
|
|
package p
|
|
|
|
func f() {
|
|
var s string
|
|
var as []string
|
|
switch false && (s+"a"+as[0]+s+as[0]+s == "") {
|
|
}
|
|
}
|