Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.
This repository was archived by the owner on Jun 13, 2025. It is now read-only.

[Question] Rationale for not returning errors? #9

Description

@jasondeutsch

Several functions, such as the one below, do not return an error.

func NewMessage(v []byte) *Message {

The nil value is used (such as msg == nil to determine success failure. This appears to lead to awkward error handling and the at least one use of a Fatal call.

I am new to this project, thus if there is a reason inherent to the workings of HL7 then that is something I am now aware of.
Excluding a hard requirement, what is the reason for not returning the idiomatic (and useful) result, err?

Along this lines, it seems like many calls do not handle errors. Is this intentional or a factor of time?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions