go styleguide: require Stringer for custom string wrapper types #3

Closed
clawbot wants to merge 1 commits from clawbot/prompts:add-stringer-rule into main
Contributor

Add rule: custom string types should implement fmt.Stringer and use .String() method calls instead of string() casts when passing to library code.

This codifies the pattern applied in upaas PR #126.

Add rule: custom string types should implement `fmt.Stringer` and use `.String()` method calls instead of `string()` casts when passing to library code. This codifies the pattern applied in upaas PR #126.
clawbot added 1 commit 2026-02-23 20:55:02 +01:00
Custom string-based types (e.g. ImageID, ContainerID) must implement
fmt.Stringer. Use .String() at SDK/library boundaries instead of
string(v) for explicit, grep-able conversions.
clawbot force-pushed add-stringer-rule from 8fc81c3774 to cfa5d4e174 2026-02-23 20:56:18 +01:00 Compare
Author
Contributor

Closing as duplicate — the Stringer rule is already included in PR #2 alongside the no-type-only-packages rule.

Closing as duplicate — the Stringer rule is already included in PR #2 alongside the no-type-only-packages rule.
clawbot closed this pull request 2026-02-23 20:56:46 +01:00

Pull request closed

Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sneak/prompts#3
No description provided.