bump(code.google.com/p/goprotobuf): 1141ccae4b85
parent
ea28b1cdf3
commit
111888adea
|
@ -332,17 +332,13 @@ func (p *Buffer) buffree(s []byte) {
|
||||||
// Bool is a helper routine that allocates a new bool value
|
// Bool is a helper routine that allocates a new bool value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Bool(v bool) *bool {
|
func Bool(v bool) *bool {
|
||||||
p := new(bool)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Int32 is a helper routine that allocates a new int32 value
|
// Int32 is a helper routine that allocates a new int32 value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Int32(v int32) *int32 {
|
func Int32(v int32) *int32 {
|
||||||
p := new(int32)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Int is a helper routine that allocates a new int32 value
|
// Int is a helper routine that allocates a new int32 value
|
||||||
|
@ -357,25 +353,19 @@ func Int(v int) *int32 {
|
||||||
// Int64 is a helper routine that allocates a new int64 value
|
// Int64 is a helper routine that allocates a new int64 value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Int64(v int64) *int64 {
|
func Int64(v int64) *int64 {
|
||||||
p := new(int64)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Float32 is a helper routine that allocates a new float32 value
|
// Float32 is a helper routine that allocates a new float32 value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Float32(v float32) *float32 {
|
func Float32(v float32) *float32 {
|
||||||
p := new(float32)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Float64 is a helper routine that allocates a new float64 value
|
// Float64 is a helper routine that allocates a new float64 value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Float64(v float64) *float64 {
|
func Float64(v float64) *float64 {
|
||||||
p := new(float64)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Uint32 is a helper routine that allocates a new uint32 value
|
// Uint32 is a helper routine that allocates a new uint32 value
|
||||||
|
@ -389,17 +379,13 @@ func Uint32(v uint32) *uint32 {
|
||||||
// Uint64 is a helper routine that allocates a new uint64 value
|
// Uint64 is a helper routine that allocates a new uint64 value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func Uint64(v uint64) *uint64 {
|
func Uint64(v uint64) *uint64 {
|
||||||
p := new(uint64)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// String is a helper routine that allocates a new string value
|
// String is a helper routine that allocates a new string value
|
||||||
// to store v and returns a pointer to it.
|
// to store v and returns a pointer to it.
|
||||||
func String(v string) *string {
|
func String(v string) *string {
|
||||||
p := new(string)
|
return &v
|
||||||
*p = v
|
|
||||||
return p
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// EnumName is a helper function to simplify printing protocol buffer enums
|
// EnumName is a helper function to simplify printing protocol buffer enums
|
||||||
|
|
Loading…
Reference in New Issue