mirror of
				https://github.com/golang/go.git
				synced 2025-11-04 02:30:57 +00:00 
			
		
		
		
	Always process the DWARF info, even when the const value is determined using the debug data block. This ensures that the injected enum is removed and future loads of the same constant do not trigger inconsistent definitions. Add tests for issues 2470 and 4054. Fixes #4054. R=golang-dev, fullung, dave, rsc, minux.ma CC=golang-dev https://golang.org/cl/6501101
		
			
				
	
	
		
			23 lines
		
	
	
	
		
			341 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
	
		
			341 B
		
	
	
	
		
			Go
		
	
	
	
	
	
// Copyright 2012 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 cgotest
 | 
						|
 | 
						|
/*
 | 
						|
typedef enum {
 | 
						|
	A = 0,
 | 
						|
	B,
 | 
						|
	C,
 | 
						|
	D,
 | 
						|
	E,
 | 
						|
	F,
 | 
						|
	G,
 | 
						|
	H,
 | 
						|
	I,
 | 
						|
	J,
 | 
						|
} issue4054b;
 | 
						|
*/
 | 
						|
import "C"
 | 
						|
 | 
						|
var issue4054b = []int{C.A, C.B, C.C, C.D, C.E, C.F, C.G, C.H, C.I, C.J}
 |