diff options
author | Martin Odersky <odersky@gmail.com> | 2016-10-14 09:12:58 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-10-14 09:16:37 +0200 |
commit | e82cb7cdb93306b5fccf6aeef0e087999f46a016 (patch) | |
tree | ea06fc1746220b1ae6864174dde02c7cd171b5fe /tests/pos/1567/Test_2.scala | |
parent | dac5b931bcf8757070c8aa74571e52f3b4c6e5eb (diff) | |
download | dotty-e82cb7cdb93306b5fccf6aeef0e087999f46a016.tar.gz dotty-e82cb7cdb93306b5fccf6aeef0e087999f46a016.tar.bz2 dotty-e82cb7cdb93306b5fccf6aeef0e087999f46a016.zip |
Fix #1567: Widen private constructor in value class
Private or protected constructors of value classes need to be widenened
to public in order to enable boxing anywhere.
Technically we should also do something about qualified private constructors, but since we
want to get rid of them anyway it's urgent.
Diffstat (limited to 'tests/pos/1567/Test_2.scala')
-rw-r--r-- | tests/pos/1567/Test_2.scala | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/pos/1567/Test_2.scala b/tests/pos/1567/Test_2.scala new file mode 100644 index 000000000..db6ca7070 --- /dev/null +++ b/tests/pos/1567/Test_2.scala @@ -0,0 +1,3 @@ +object Test { + scala.util.Try(PosZInt.from(1).get) +} |