Commit 31d19c0b authored by Than McIntosh's avatar Than McIntosh

test: add testcase for gccgo compile failure

Also includes a small tweak to test/run.go to allow package names
with Unicode letters (as opposed to just ASCII chars).

Updates #27836

Change-Id: Idbf0bdea24174808cddcb69974dab820eb13e521
Reviewed-on: https://go-review.googlesource.com/138075Reviewed-by: default avatarCherry Zhang <cherryyz@google.com>
parent 019aee55
package Äfoo
var ÄbarV int = 101
func Äbar(x int) int {
defer func() { ÄbarV += 3 }()
return Äblix(x)
}
func Äblix(x int) int {
defer func() { ÄbarV += 9 }()
return ÄbarV + x
}
package main
import (
"fmt"
"./Äfoo"
Äblix "./Äfoo"
)
func main() {
fmt.Printf("Äfoo.Äbar(33) returns %v\n", Äfoo.Äbar(33))
fmt.Printf("Äblix.Äbar(33) returns %v\n", Äblix.Äbar(33))
}
// compiledir
// 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.
package ignored
......@@ -321,7 +321,7 @@ func goDirFiles(longdir string) (filter []os.FileInfo, err error) {
return
}
var packageRE = regexp.MustCompile(`(?m)^package (\w+)`)
var packageRE = regexp.MustCompile(`(?m)^package ([\p{Lu}\p{Ll}\w]+)`)
// If singlefilepkgs is set, each file is considered a separate package
// even if the package names are the same.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment