aboutsummaryrefslogtreecommitdiff
path: root/v_windows/v/vlib/v/checker/tests/no_pub_in_main.out
diff options
context:
space:
mode:
authorIndrajith K L2022-12-03 17:00:20 +0530
committerIndrajith K L2022-12-03 17:00:20 +0530
commitf5c4671bfbad96bf346bd7e9a21fc4317b4959df (patch)
tree2764fc62da58f2ba8da7ed341643fc359873142f /v_windows/v/vlib/v/checker/tests/no_pub_in_main.out
downloadcli-tools-windows-master.tar.gz
cli-tools-windows-master.tar.bz2
cli-tools-windows-master.zip
Adds most of the toolsHEADmaster
Diffstat (limited to 'v_windows/v/vlib/v/checker/tests/no_pub_in_main.out')
-rw-r--r--v_windows/v/vlib/v/checker/tests/no_pub_in_main.out49
1 files changed, 49 insertions, 0 deletions
diff --git a/v_windows/v/vlib/v/checker/tests/no_pub_in_main.out b/v_windows/v/vlib/v/checker/tests/no_pub_in_main.out
new file mode 100644
index 0000000..e1da080
--- /dev/null
+++ b/v_windows/v/vlib/v/checker/tests/no_pub_in_main.out
@@ -0,0 +1,49 @@
+vlib/v/checker/tests/no_pub_in_main.vv:3:1: error: type alias `Integer` in module main cannot be declared public
+ 1 | module main
+ 2 |
+ 3 | pub type Integer = int
+ | ~~~~~~~~~~~~~~~~
+ 4 |
+ 5 | pub type Float = f32 | f64
+vlib/v/checker/tests/no_pub_in_main.vv:5:1: error: sum type `Float` in module main cannot be declared public
+ 3 | pub type Integer = int
+ 4 |
+ 5 | pub type Float = f32 | f64
+ | ~~~~~~~~~~~~~~
+ 6 |
+ 7 | // Buggy ATM
+vlib/v/checker/tests/no_pub_in_main.vv:10:1: error: enum `Color` in module main cannot be declared public
+ 8 | // pub type Fn = fn () int
+ 9 |
+ 10 | pub enum Color {
+ | ~~~~~~~~~~~~~~
+ 11 | red
+ 12 | green
+vlib/v/checker/tests/no_pub_in_main.vv:16:1: error: const in module main cannot be declared public
+ 14 | }
+ 15 |
+ 16 | pub const (
+ | ~~~~~~~~~
+ 17 | w = 'world'
+ 18 | )
+vlib/v/checker/tests/no_pub_in_main.vv:20:1: error: function `my_fn` in module main cannot be declared public
+ 18 | )
+ 19 |
+ 20 | pub fn my_fn() int {
+ | ~~~~~~~~~~~~~~~~~~
+ 21 | return 1
+ 22 | }
+vlib/v/checker/tests/no_pub_in_main.vv:24:1: error: function `main` cannot be declared public
+ 22 | }
+ 23 |
+ 24 | pub fn main() {
+ | ~~~~~~~~~~~~~
+ 25 | println('main')
+ 26 | }
+vlib/v/checker/tests/no_pub_in_main.vv:28:1: error: struct `MyStruct` in module main cannot be declared public
+ 26 | }
+ 27 |
+ 28 | pub struct MyStruct {
+ | ~~~~~~~~~~~~~~~~~~~
+ 29 | field int
+ 30 | }