Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It does. If I define struct to contain boolean, Go yaml parser will always parse it to boolean

If I define it as any other type, it will parse it as that type. So any conflicts like in the article just don't happen, or at worst, produce error in parsing.

Static typing in this case acts essentially as schema



Go isn’t the only language using YAML




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: