...

Source file src/internal/types/testdata/check/go1_22_21.go

Documentation: internal/types/testdata/check

     1  // -lang=go1.22
     2  
     3  // Copyright 2024 The Go Authors. All rights reserved.
     4  // Use of this source code is governed by a BSD-style
     5  // license that can be found in the LICENSE file.
     6  
     7  // Check Go language version-specific errors.
     8  
     9  //go:build go1.21
    10  
    11  package p
    12  
    13  func f() {
    14  	for _ = range 10 /* ERROR "requires go1.22 or later" */ {
    15  	}
    16  }
    17  

View as plain text