is_string_like

fairseq2.data.is_string_like(s)[source]

Return True if s is of type str or CString.

Return type:

TypeGuard[str | CString]