github.com/c9s/go@v0.0.0-20180120015821-984e81f64e0c/src/go/parser/testdata/commas.src (about)

     1  // Copyright 2012 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // Test case for error messages/parser synchronization
     6  // after missing commas.
     7  
     8  package p
     9  
    10  var _ = []int{
    11  	0 /* ERROR "missing ','" */
    12  }
    13  
    14  var _ = []int{
    15  	0,
    16  	1,
    17  	2,
    18  	3 /* ERROR "missing ','" */
    19  }