-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/internal/gccgoimporter: handle conversions in exported const values
Same as https://go-review.googlesource.com/c/33412/ in the standard library. Fixes #17981. Change-Id: Iaf47872840a4456d824ed5d7b3eda205c043e4cf Reviewed-on: https://go-review.googlesource.com/34110 Reviewed-by: Robert Griesemer <gri@golang.org>
- Loading branch information
Showing
5 changed files
with
48 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package conversions | ||
|
||
type Units string | ||
|
||
const Bits = Units("bits") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
v2; | ||
package conversions; | ||
prefix go; | ||
package conversions go.conversions go.conversions; | ||
const Bits <type 1 "Units" <type -16>> = convert(<type 1>, "bits"); | ||
type <type 1>; |