engine: resources: Add some compile time checks for groupers
These can "break" silently and not autogroup if we change the resource and it no longer fulfills the interface. Add this compile time check to prevent that.
This commit is contained in:
@@ -48,6 +48,8 @@ func init() {
|
||||
engine.RegisterResource(httpServerFlagKind, func() engine.Res { return &HTTPServerFlagRes{} })
|
||||
}
|
||||
|
||||
var _ HTTPServerGroupableRes = &HTTPServerFlagRes{} // compile time check
|
||||
|
||||
// HTTPServerFlagRes is a special path that exists within an http server. The
|
||||
// name is used as the public path of the flag, unless the path field is
|
||||
// specified, and in that case it is used instead. The way this works is that it
|
||||
|
||||
Reference in New Issue
Block a user