blob: 86fe95e469545c3b4a70422a9eb2a56a51e773a7 [file] [log] [blame]
Joe Tsai08e00302018-11-26 22:32:06 -08001// Copyright 2018 The Go Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5package impl
6
7import pvalue "github.com/golang/protobuf/v2/internal/value"
8
9// TODO: Add a default LegacyWrapper that panics with a more helpful message?
10var legacyWrapper pvalue.LegacyWrapper
11
12// RegisterLegacyWrapper registers a set of constructor functions that are
13// called when a legacy enum or message is encountered that does not natively
14// support the protobuf reflection APIs.
15func RegisterLegacyWrapper(w pvalue.LegacyWrapper) {
16 legacyWrapper = w
17}