Sign in
go
/
talks
/
a07c284bcf333dc17a1489fd441e8fccf1e01c2a
/
.
/
content
/
2014
/
readability
/
err_close_write_bad.go
blob: 8de949767387d6fbd9844254b68ff454820ad1e8 [
file
] [
log
] [
blame
]
// +build ignore,OMIT
package sample
// OMIT
func run() error {
in, err := os.Open(*input)
if err != nil {
return err
}
defer in.Close()
out, err := os.Create(*output)
if err != nil {
return err
}
defer out.Close()
// HL
// some code
}