From 5b53cef59ed9965abafb486063f24b236f912eb1 Mon Sep 17 00:00:00 2001 From: Artem Yadelskyi Date: Thu, 3 Nov 2022 05:55:14 +0200 Subject: [PATCH] all: remove old `// +build` comments (#2431) Closes #2325 --- CONTRIBUTING.md | 1 - audio/buffersize_mobile.go | 1 - audio/buffersize_notmobile.go | 1 - audio/error_notios.go | 1 - cmd/ebitenmobile/gobind.go | 1 - cmd/ebitenmobile/gomobile.go | 3 +-- ebitenutil/file_notjs.go | 1 - ebitenutil/gen.go | 1 - ebitenutil/loadimage_notmobile.go | 1 - examples/2048/main.go | 1 - examples/additive/main.go | 1 - examples/address/main.go | 1 - examples/airship/main.go | 1 - examples/alphablending/main.go | 1 - examples/animation/main.go | 1 - examples/audio/main.go | 1 - examples/audioinfiniteloop/main.go | 1 - examples/audiopanning/main.go | 1 - examples/blocks/main.go | 1 - examples/blur/main.go | 1 - examples/camera/main.go | 1 - examples/chipmunk/main.go | 1 - examples/clip/main.go | 1 - examples/contextlost/context_js.go | 1 - examples/contextlost/context_notjs.go | 1 - examples/contextlost/main.go | 1 - examples/cursor/main.go | 1 - examples/doomfire/main.go | 1 - examples/drag/main.go | 1 - examples/filter/main.go | 1 - examples/flappy/crt.go | 1 - examples/flappy/main.go | 1 - examples/flappy/main_c.go | 2 -- examples/flood/main.go | 1 - examples/font/main.go | 1 - examples/fullscreen/main.go | 1 - examples/gamepad/main.go | 1 - examples/highdpi/main.go | 1 - examples/hsv/main.go | 1 - examples/hue/main.go | 1 - examples/infinitescroll/main.go | 1 - examples/isometric/game.go | 1 - examples/isometric/level.go | 1 - examples/isometric/main.go | 1 - examples/isometric/spritesheet.go | 1 - examples/isometric/tile.go | 1 - examples/keyboard/keyboard/gen.go | 1 - examples/keyboard/main.go | 1 - examples/lasttouch/main.go | 1 - examples/life/main.go | 1 - examples/mandelbrot/main.go | 1 - examples/mascot/main.go | 1 - examples/masking/main.go | 1 - examples/minify/main.go | 1 - examples/moire/main.go | 1 - examples/mosaic/main.go | 1 - examples/noise/main.go | 1 - examples/paint/main.go | 1 - examples/particles/main.go | 1 - examples/pcm/main.go | 1 - examples/perspective/main.go | 1 - examples/piano/main.go | 1 - examples/platformer/main.go | 1 - examples/polygons/main.go | 1 - examples/raycasting/main.go | 1 - examples/realtimepcm/main.go | 1 - examples/rotate/main.go | 1 - examples/set/main.go | 1 - examples/shader/chromaticaberration.go | 1 - examples/shader/default.go | 1 - examples/shader/dissolve.go | 1 - examples/shader/lighting.go | 1 - examples/shader/main.go | 1 - examples/shader/radialblur.go | 1 - examples/shader/texel.go | 1 - examples/shader/water.go | 1 - examples/shapes/main.go | 1 - examples/sinewave/main.go | 1 - examples/skipdraw/main.go | 1 - examples/snake/main.go | 1 - examples/sprites/main.go | 1 - examples/spriteshd/main.go | 1 - examples/squiral/main.go | 1 - examples/stars/main.go | 1 - examples/text/main.go | 1 - examples/tiles/main.go | 1 - examples/touch/main.go | 1 - examples/typewriter/main.go | 1 - examples/ui/main.go | 1 - examples/vector/main.go | 1 - examples/vibrate/main.go | 1 - examples/wav/main.go | 1 - examples/wheel/main.go | 1 - examples/windowclosing/main.go | 1 - examples/windowsize/main.go | 1 - genevents.go | 1 - genkeys.go | 11 +++-------- internal/debug/debug_ebitenginedebug.go | 1 - internal/debug/debug_notebitenginedebug.go | 1 - internal/devicescale/impl_desktop.go | 1 - internal/gamepad/api_desktop_windows.go | 1 - internal/gamepad/api_ios.go | 1 - internal/gamepad/api_linux.go | 1 - internal/gamepad/api_xbox_windows.go | 1 - internal/gamepad/extern_android.go | 1 - internal/gamepad/gamepad_android.go | 1 - internal/gamepad/gamepad_darwin.go | 1 - internal/gamepad/gamepad_desktop_windows.go | 1 - internal/gamepad/gamepad_ios.go | 1 - internal/gamepad/gamepad_linux.go | 1 - internal/gamepad/gamepad_nintendosdk.go | 1 - internal/gamepad/gamepad_null.go | 1 - internal/gamepad/gamepad_windows.go | 1 - internal/gamepad/gamepad_xbox_windows.go | 1 - internal/glfw/callback_notwindows.go | 1 - internal/glfw/const.go | 1 - internal/glfw/glfw_notwindows.go | 1 - internal/glfw/keys.go | 1 - internal/glfw/type_notwindows.go | 1 - internal/graphicscommand/image_notjs.go | 1 - internal/graphicsdriver/directx/api_32bit_windows.go | 1 - internal/graphicsdriver/directx/api_64bit_windows.go | 1 - .../directx/api_microsoftgdk_windows.go | 1 - .../directx/api_notmicrosoftgdk_windows.go | 1 - internal/graphicsdriver/metal/view_macos_darwin.go | 1 - internal/graphicsdriver/opengl/context_gl.go | 1 - internal/graphicsdriver/opengl/context_gles.go | 2 -- internal/graphicsdriver/opengl/gl/conversions_cgo.go | 1 - .../graphicsdriver/opengl/gl/conversions_nocgo.go | 1 - internal/graphicsdriver/opengl/gl/package.go | 1 - .../graphicsdriver/opengl/gl/package_notpurego.go | 1 - internal/graphicsdriver/opengl/gl/package_purego.go | 1 - internal/graphicsdriver/opengl/gl/procaddr_others.go | 1 - internal/graphicsdriver/opengl/gles/default.go | 1 - internal/graphicsdriver/opengl/gles/gomobile.go | 1 - internal/graphicsdriver/opengl/graphics_gl.go | 1 - internal/graphicsdriver/opengl/graphics_gles.go | 2 -- internal/graphicsdriver/opengl/graphics_mobile.go | 1 - internal/graphicsdriver/opengl/shader_gl.go | 1 - internal/graphicsdriver/opengl/shader_gles.go | 2 -- internal/microsoftgdk/microsoftgdk_windows.go | 1 - internal/microsoftgdk/notmicrosoftgdk.go | 1 - internal/nintendosdk/nintendosdk.go | 1 - internal/png/gen.go | 1 - internal/processtest/processtest_test.go | 1 - internal/processtest/testdata/issue1753.go | 1 - internal/processtest/testdata/issue2079.go | 1 - internal/processtest/testdata/issue2089.go | 1 - internal/processtest/testdata/issue2129.go | 1 - internal/processtest/testdata/issue2138.go | 1 - internal/processtest/testdata/issue2154_1.go | 3 +-- internal/processtest/testdata/issue2154_2.go | 1 - internal/processtest/testdata/issue2162.go | 1 - internal/processtest/testdata/issue2180.go | 1 - internal/processtest/testdata/issue2362.go | 1 - internal/processtest/testdata/issue2390.go | 1 - internal/ui/api_windows.go | 1 - internal/ui/hideconsole_notwindows.go | 1 - internal/ui/hideconsole_windows.go | 1 - internal/ui/input_glfw.go | 1 - internal/ui/input_mobile.go | 2 -- internal/ui/input_nintendosdk.go | 1 - internal/ui/keys_glfw.go | 1 - internal/ui/keys_mobile.go | 2 -- internal/ui/run_notsinglethread.go | 1 - internal/ui/run_singlethread.go | 5 ----- internal/ui/ui_glfw.go | 1 - internal/ui/ui_glfw_darwin.go | 1 - internal/ui/ui_glfw_gl.go | 1 - internal/ui/ui_glfw_gles.go | 1 - internal/ui/ui_glfw_unix.go | 1 - internal/ui/ui_glfw_windows.go | 1 - internal/ui/ui_mobile.go | 2 -- internal/ui/ui_nintendosdk.go | 1 - internal/ui/window_glfw.go | 1 - internal/vibrate/vibrate_android.go | 1 - internal/vibrate/vibrate_ios.go | 1 - internal/vibrate/vibrate_null.go | 1 - mobile/ebitenmobileview/input.go | 1 - mobile/ebitenmobileview/mobile.go | 1 - mobile/impl_mobile.go | 1 - mobile/impl_notmobile.go | 1 - run_mobile.go | 1 - 183 files changed, 5 insertions(+), 203 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 55d64ba86..cafa5340d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -49,7 +49,6 @@ You don't have to update existing files' license comments. ```go //go:build example -// +build example ``` `example` is to prevent from installing executions by `go get github.com/hajimehoshi/ebiten/v2/...`. diff --git a/audio/buffersize_mobile.go b/audio/buffersize_mobile.go index f4c63c77d..08c6d1539 100644 --- a/audio/buffersize_mobile.go +++ b/audio/buffersize_mobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package audio diff --git a/audio/buffersize_notmobile.go b/audio/buffersize_notmobile.go index 0897a8d11..ad04120b9 100644 --- a/audio/buffersize_notmobile.go +++ b/audio/buffersize_notmobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios -// +build !android,!ios package audio diff --git a/audio/error_notios.go b/audio/error_notios.go index da4da0b57..1afda4f2e 100644 --- a/audio/error_notios.go +++ b/audio/error_notios.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !ios -// +build !ios package audio diff --git a/cmd/ebitenmobile/gobind.go b/cmd/ebitenmobile/gobind.go index e470bbc6a..c36dc85b8 100644 --- a/cmd/ebitenmobile/gobind.go +++ b/cmd/ebitenmobile/gobind.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ebitenmobilegobind -// +build ebitenmobilegobind // gobind is a wrapper of the original gobind. This command adds extra files like a view controller. package main diff --git a/cmd/ebitenmobile/gomobile.go b/cmd/ebitenmobile/gomobile.go index 6b47767b2..fe3660448 100644 --- a/cmd/ebitenmobile/gomobile.go +++ b/cmd/ebitenmobile/gomobile.go @@ -116,8 +116,7 @@ func prepareGomobileCommands() (string, error) { const ( modname = "ebitenmobiletemporary" - buildtags = "//go:build tools" + - "\n// +build tools" + buildtags = "//go:build tools" ) if err := runGo("mod", "init", modname); err != nil { return tmp, err diff --git a/ebitenutil/file_notjs.go b/ebitenutil/file_notjs.go index e16a51935..e9a2be305 100644 --- a/ebitenutil/file_notjs.go +++ b/ebitenutil/file_notjs.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js -// +build !android,!ios,!js package ebitenutil diff --git a/ebitenutil/gen.go b/ebitenutil/gen.go index 6196c56ff..00e2774d1 100644 --- a/ebitenutil/gen.go +++ b/ebitenutil/gen.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/ebitenutil/loadimage_notmobile.go b/ebitenutil/loadimage_notmobile.go index 34dcc4369..c44f9bb73 100644 --- a/ebitenutil/loadimage_notmobile.go +++ b/ebitenutil/loadimage_notmobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios -// +build !android,!ios package ebitenutil diff --git a/examples/2048/main.go b/examples/2048/main.go index fa67105e7..a02ed7ec1 100644 --- a/examples/2048/main.go +++ b/examples/2048/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/additive/main.go b/examples/additive/main.go index 664eb9cd9..a4452aa06 100644 --- a/examples/additive/main.go +++ b/examples/additive/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/address/main.go b/examples/address/main.go index d03d223f9..184f109ed 100644 --- a/examples/address/main.go +++ b/examples/address/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/airship/main.go b/examples/airship/main.go index 60c2172e0..3e2e2e59c 100644 --- a/examples/airship/main.go +++ b/examples/airship/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/alphablending/main.go b/examples/alphablending/main.go index 3a805bf0f..f02071898 100644 --- a/examples/alphablending/main.go +++ b/examples/alphablending/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/animation/main.go b/examples/animation/main.go index b2dab8c44..1b9cef145 100644 --- a/examples/animation/main.go +++ b/examples/animation/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/audio/main.go b/examples/audio/main.go index 05895c28d..ce0196176 100644 --- a/examples/audio/main.go +++ b/examples/audio/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example // This is an example to implement an audio player. // See examples/wav for a simpler example to play a sound file. diff --git a/examples/audioinfiniteloop/main.go b/examples/audioinfiniteloop/main.go index a6eeea3ab..e49fc7517 100644 --- a/examples/audioinfiniteloop/main.go +++ b/examples/audioinfiniteloop/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/audiopanning/main.go b/examples/audiopanning/main.go index d1bb3338a..eb52bc90d 100644 --- a/examples/audiopanning/main.go +++ b/examples/audiopanning/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/blocks/main.go b/examples/blocks/main.go index cccfc8dbd..cee7259d6 100644 --- a/examples/blocks/main.go +++ b/examples/blocks/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/blur/main.go b/examples/blur/main.go index 46b661127..7523fa088 100644 --- a/examples/blur/main.go +++ b/examples/blur/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/camera/main.go b/examples/camera/main.go index 001e1fbb0..3a8c66213 100644 --- a/examples/camera/main.go +++ b/examples/camera/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/chipmunk/main.go b/examples/chipmunk/main.go index 1d3cd452b..d6904a531 100644 --- a/examples/chipmunk/main.go +++ b/examples/chipmunk/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/clip/main.go b/examples/clip/main.go index 833a9852d..d788cd514 100644 --- a/examples/clip/main.go +++ b/examples/clip/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/contextlost/context_js.go b/examples/contextlost/context_js.go index 85c546f6a..11f26b0d2 100644 --- a/examples/contextlost/context_js.go +++ b/examples/contextlost/context_js.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/contextlost/context_notjs.go b/examples/contextlost/context_notjs.go index 17e747352..0bca66f59 100644 --- a/examples/contextlost/context_notjs.go +++ b/examples/contextlost/context_notjs.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example && !js -// +build example,!js package main diff --git a/examples/contextlost/main.go b/examples/contextlost/main.go index a9c377706..5fe8cc491 100644 --- a/examples/contextlost/main.go +++ b/examples/contextlost/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/cursor/main.go b/examples/cursor/main.go index ee224d95d..9162d6993 100644 --- a/examples/cursor/main.go +++ b/examples/cursor/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/doomfire/main.go b/examples/doomfire/main.go index cca379e93..7551e1cda 100644 --- a/examples/doomfire/main.go +++ b/examples/doomfire/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/drag/main.go b/examples/drag/main.go index aa971c685..c37548885 100644 --- a/examples/drag/main.go +++ b/examples/drag/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/filter/main.go b/examples/filter/main.go index a61037f8b..563e41d80 100644 --- a/examples/filter/main.go +++ b/examples/filter/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/flappy/crt.go b/examples/flappy/crt.go index 4ba45aebd..cf6261e50 100644 --- a/examples/flappy/crt.go +++ b/examples/flappy/crt.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore // Reference: a public domain CRT effect // https://github.com/libretro/glsl-shaders/blob/master/crt/shaders/crt-lottes.glsl diff --git a/examples/flappy/main.go b/examples/flappy/main.go index 51e1c231c..a072b51b8 100644 --- a/examples/flappy/main.go +++ b/examples/flappy/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/flappy/main_c.go b/examples/flappy/main_c.go index 7008bb01f..a3a0f4259 100644 --- a/examples/flappy/main_c.go +++ b/examples/flappy/main_c.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build example && (microsoftgdk || nintendosdk) -// +build example -// +build microsoftgdk nintendosdk // This file is for some special environments using 'microsoftgdk' or 'nintendosdk'. // You usually don't have to care about this file. diff --git a/examples/flood/main.go b/examples/flood/main.go index 61ad4706c..694316ac8 100644 --- a/examples/flood/main.go +++ b/examples/flood/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/font/main.go b/examples/font/main.go index 4c70e7a6e..b8dccb19e 100644 --- a/examples/font/main.go +++ b/examples/font/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/fullscreen/main.go b/examples/fullscreen/main.go index 8a05def79..5865c480a 100644 --- a/examples/fullscreen/main.go +++ b/examples/fullscreen/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/gamepad/main.go b/examples/gamepad/main.go index 723057daa..c314cb339 100644 --- a/examples/gamepad/main.go +++ b/examples/gamepad/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/highdpi/main.go b/examples/highdpi/main.go index 45f92f4c5..2466b70b6 100644 --- a/examples/highdpi/main.go +++ b/examples/highdpi/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/hsv/main.go b/examples/hsv/main.go index 5227e103a..262a13c3e 100644 --- a/examples/hsv/main.go +++ b/examples/hsv/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/hue/main.go b/examples/hue/main.go index b04f844d5..77f2c568d 100644 --- a/examples/hue/main.go +++ b/examples/hue/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/infinitescroll/main.go b/examples/infinitescroll/main.go index a32afffee..990e435ae 100644 --- a/examples/infinitescroll/main.go +++ b/examples/infinitescroll/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/isometric/game.go b/examples/isometric/game.go index a05107e03..7c3a6ddd8 100644 --- a/examples/isometric/game.go +++ b/examples/isometric/game.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/isometric/level.go b/examples/isometric/level.go index aba0c3abb..5d523ffcc 100644 --- a/examples/isometric/level.go +++ b/examples/isometric/level.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/isometric/main.go b/examples/isometric/main.go index 3c6821da8..07162127e 100644 --- a/examples/isometric/main.go +++ b/examples/isometric/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/isometric/spritesheet.go b/examples/isometric/spritesheet.go index 0909624b1..1283e0115 100644 --- a/examples/isometric/spritesheet.go +++ b/examples/isometric/spritesheet.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/isometric/tile.go b/examples/isometric/tile.go index 72595c53d..666805434 100644 --- a/examples/isometric/tile.go +++ b/examples/isometric/tile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/keyboard/keyboard/gen.go b/examples/keyboard/keyboard/gen.go index 94e7ae830..15091de97 100644 --- a/examples/keyboard/keyboard/gen.go +++ b/examples/keyboard/keyboard/gen.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/keyboard/main.go b/examples/keyboard/main.go index 40bd431af..b2244621d 100644 --- a/examples/keyboard/main.go +++ b/examples/keyboard/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/lasttouch/main.go b/examples/lasttouch/main.go index d96245198..2f0134d14 100644 --- a/examples/lasttouch/main.go +++ b/examples/lasttouch/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/life/main.go b/examples/life/main.go index b0085dfa1..0f8ee05f9 100644 --- a/examples/life/main.go +++ b/examples/life/main.go @@ -22,7 +22,6 @@ // DEALINGS IN THE SOFTWARE. //go:build example -// +build example package main diff --git a/examples/mandelbrot/main.go b/examples/mandelbrot/main.go index 9c0df6e07..cf4e7d543 100644 --- a/examples/mandelbrot/main.go +++ b/examples/mandelbrot/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/mascot/main.go b/examples/mascot/main.go index 23353257d..5b7c8ebe6 100644 --- a/examples/mascot/main.go +++ b/examples/mascot/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example // Mascot is a desktop mascot on cross platforms. // This is inspired by mattn's gopher (https://github.com/mattn/gopher). diff --git a/examples/masking/main.go b/examples/masking/main.go index 50299ab1a..085b7acf8 100644 --- a/examples/masking/main.go +++ b/examples/masking/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/minify/main.go b/examples/minify/main.go index c2e65f428..194ac6ac8 100644 --- a/examples/minify/main.go +++ b/examples/minify/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example // This example is an experiment to minify images with various filters. // When linear filter is used, mipmap images should be used for high-quality rendering (#578). diff --git a/examples/moire/main.go b/examples/moire/main.go index dfd029d69..ebf1c6355 100644 --- a/examples/moire/main.go +++ b/examples/moire/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example // This example is just to check if Ebitengine can draw fine checker pattern evenly. // If there is something wrong in the implementation, the result might include diff --git a/examples/mosaic/main.go b/examples/mosaic/main.go index 928eca7e0..6642ae357 100644 --- a/examples/mosaic/main.go +++ b/examples/mosaic/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/noise/main.go b/examples/noise/main.go index 7f5382e66..5bcdf5bf9 100644 --- a/examples/noise/main.go +++ b/examples/noise/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/paint/main.go b/examples/paint/main.go index c1fce491d..f13847197 100644 --- a/examples/paint/main.go +++ b/examples/paint/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/particles/main.go b/examples/particles/main.go index 435e25757..d09d1a6a7 100644 --- a/examples/particles/main.go +++ b/examples/particles/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/pcm/main.go b/examples/pcm/main.go index 02d8a50bd..9d71433de 100644 --- a/examples/pcm/main.go +++ b/examples/pcm/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/perspective/main.go b/examples/perspective/main.go index f24fc5ae9..e124ae3ee 100644 --- a/examples/perspective/main.go +++ b/examples/perspective/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/piano/main.go b/examples/piano/main.go index db6dd2208..f867d8124 100644 --- a/examples/piano/main.go +++ b/examples/piano/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/platformer/main.go b/examples/platformer/main.go index 66e47ef08..8ac8d2faf 100644 --- a/examples/platformer/main.go +++ b/examples/platformer/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/polygons/main.go b/examples/polygons/main.go index e21064006..4efbcb247 100644 --- a/examples/polygons/main.go +++ b/examples/polygons/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/raycasting/main.go b/examples/raycasting/main.go index 97ac1e2a5..d17bdbe70 100644 --- a/examples/raycasting/main.go +++ b/examples/raycasting/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/realtimepcm/main.go b/examples/realtimepcm/main.go index a55d51552..e66a29384 100644 --- a/examples/realtimepcm/main.go +++ b/examples/realtimepcm/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/rotate/main.go b/examples/rotate/main.go index 8b671a5ed..e2dfbf777 100644 --- a/examples/rotate/main.go +++ b/examples/rotate/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/set/main.go b/examples/set/main.go index ca2ab70e8..fcae28a72 100644 --- a/examples/set/main.go +++ b/examples/set/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/shader/chromaticaberration.go b/examples/shader/chromaticaberration.go index 1188d3490..bbdfeb0c7 100644 --- a/examples/shader/chromaticaberration.go +++ b/examples/shader/chromaticaberration.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/default.go b/examples/shader/default.go index ce2864d5a..7634814be 100644 --- a/examples/shader/default.go +++ b/examples/shader/default.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/dissolve.go b/examples/shader/dissolve.go index ba87e81b2..49852263b 100644 --- a/examples/shader/dissolve.go +++ b/examples/shader/dissolve.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/lighting.go b/examples/shader/lighting.go index 48528f209..20921b101 100644 --- a/examples/shader/lighting.go +++ b/examples/shader/lighting.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/main.go b/examples/shader/main.go index 9100b3dba..bdb5d0564 100644 --- a/examples/shader/main.go +++ b/examples/shader/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/shader/radialblur.go b/examples/shader/radialblur.go index 8638bd56a..0cb4521e4 100644 --- a/examples/shader/radialblur.go +++ b/examples/shader/radialblur.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/texel.go b/examples/shader/texel.go index bd1c21c0d..5a2000e13 100644 --- a/examples/shader/texel.go +++ b/examples/shader/texel.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shader/water.go b/examples/shader/water.go index 7fa3526dc..c702c150a 100644 --- a/examples/shader/water.go +++ b/examples/shader/water.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/examples/shapes/main.go b/examples/shapes/main.go index 68b098328..e9d4e3522 100644 --- a/examples/shapes/main.go +++ b/examples/shapes/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/sinewave/main.go b/examples/sinewave/main.go index 629cd29f9..cc09cc6ef 100644 --- a/examples/sinewave/main.go +++ b/examples/sinewave/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/skipdraw/main.go b/examples/skipdraw/main.go index 5ad8cbb63..0a7e66f03 100644 --- a/examples/skipdraw/main.go +++ b/examples/skipdraw/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/snake/main.go b/examples/snake/main.go index 0942ef08d..f843573f2 100644 --- a/examples/snake/main.go +++ b/examples/snake/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/sprites/main.go b/examples/sprites/main.go index a3cae627a..f2a1017d5 100644 --- a/examples/sprites/main.go +++ b/examples/sprites/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/spriteshd/main.go b/examples/spriteshd/main.go index f1bb10e3d..ff330dbc2 100644 --- a/examples/spriteshd/main.go +++ b/examples/spriteshd/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/squiral/main.go b/examples/squiral/main.go index b3a9114c9..61947d960 100644 --- a/examples/squiral/main.go +++ b/examples/squiral/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example // This demo is inspired by the xscreensaver 'squirals'. diff --git a/examples/stars/main.go b/examples/stars/main.go index 7ecf4904a..9bb96c925 100644 --- a/examples/stars/main.go +++ b/examples/stars/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/text/main.go b/examples/text/main.go index 7df1f62f2..60a82d60a 100644 --- a/examples/text/main.go +++ b/examples/text/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/tiles/main.go b/examples/tiles/main.go index ce40e3e6e..2f822d486 100644 --- a/examples/tiles/main.go +++ b/examples/tiles/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/touch/main.go b/examples/touch/main.go index 624554db0..48f8d5651 100644 --- a/examples/touch/main.go +++ b/examples/touch/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/typewriter/main.go b/examples/typewriter/main.go index dbca529b5..2f3207365 100644 --- a/examples/typewriter/main.go +++ b/examples/typewriter/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/ui/main.go b/examples/ui/main.go index 4bcd7dfb5..f2a2bfb3c 100644 --- a/examples/ui/main.go +++ b/examples/ui/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/vector/main.go b/examples/vector/main.go index c883c918a..da15346e5 100644 --- a/examples/vector/main.go +++ b/examples/vector/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/vibrate/main.go b/examples/vibrate/main.go index 36a72fc41..a55fc0b6e 100644 --- a/examples/vibrate/main.go +++ b/examples/vibrate/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/wav/main.go b/examples/wav/main.go index f0b9e07df..62607262a 100644 --- a/examples/wav/main.go +++ b/examples/wav/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/wheel/main.go b/examples/wheel/main.go index 6d7d82c04..90482beab 100644 --- a/examples/wheel/main.go +++ b/examples/wheel/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/windowclosing/main.go b/examples/windowclosing/main.go index 9db3a329b..1da6803e8 100644 --- a/examples/windowclosing/main.go +++ b/examples/windowclosing/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/examples/windowsize/main.go b/examples/windowsize/main.go index b36375e1a..9e3514b90 100644 --- a/examples/windowsize/main.go +++ b/examples/windowsize/main.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build example -// +build example package main diff --git a/genevents.go b/genevents.go index dc1304e64..2b5252d84 100644 --- a/genevents.go +++ b/genevents.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/genkeys.go b/genkeys.go index 7f6caf1eb..62dde8039 100644 --- a/genkeys.go +++ b/genkeys.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore // The key name convention follows the Web standard: https://www.w3.org/TR/uievents-code/#keyboard-key-codes @@ -822,15 +821,11 @@ func main() { buildTag := "" switch path { case filepath.Join("internal", "glfw", "keys.go"): - buildTag = "//go:build !js" + - "\n// +build !js" + buildTag = "//go:build !js" case filepath.Join("internal", "ui", "keys_mobile.go"): - buildTag = "//go:build (android || ios) && !nintendosdk" + - "\n// +build android ios" + - "\n// +build !nintendosdk" + buildTag = "//go:build (android || ios) && !nintendosdk" case filepath.Join("internal", "ui", "keys_glfw.go"): - buildTag = "//go:build !android && !ios && !js && !nintendosdk" + - "\n// +build !android,!ios,!js,!nintendosdk" + buildTag = "//go:build !android && !ios && !js && !nintendosdk" } // NOTE: According to godoc, maps are automatically sorted by key. if err := tmpl.Execute(f, struct { diff --git a/internal/debug/debug_ebitenginedebug.go b/internal/debug/debug_ebitenginedebug.go index 4ddc3b292..d82afb8c0 100644 --- a/internal/debug/debug_ebitenginedebug.go +++ b/internal/debug/debug_ebitenginedebug.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ebitenginedebug || ebitendebug -// +build ebitenginedebug ebitendebug package debug diff --git a/internal/debug/debug_notebitenginedebug.go b/internal/debug/debug_notebitenginedebug.go index 63506fa30..86259fc9e 100644 --- a/internal/debug/debug_notebitenginedebug.go +++ b/internal/debug/debug_notebitenginedebug.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !ebitenginedebug && !ebitendebug -// +build !ebitenginedebug,!ebitendebug package debug diff --git a/internal/devicescale/impl_desktop.go b/internal/devicescale/impl_desktop.go index 6f26fe957..c468f12f5 100644 --- a/internal/devicescale/impl_desktop.go +++ b/internal/devicescale/impl_desktop.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js -// +build !android,!ios,!js package devicescale diff --git a/internal/gamepad/api_desktop_windows.go b/internal/gamepad/api_desktop_windows.go index fb2d39a39..4ca899ed1 100644 --- a/internal/gamepad/api_desktop_windows.go +++ b/internal/gamepad/api_desktop_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/api_ios.go b/internal/gamepad/api_ios.go index 05492e036..d42c7313b 100644 --- a/internal/gamepad/api_ios.go +++ b/internal/gamepad/api_ios.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/api_linux.go b/internal/gamepad/api_linux.go index 2d8cebc40..df6846f06 100644 --- a/internal/gamepad/api_linux.go +++ b/internal/gamepad/api_linux.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !nintendosdk -// +build !android,!nintendosdk package gamepad diff --git a/internal/gamepad/api_xbox_windows.go b/internal/gamepad/api_xbox_windows.go index 408415fa3..75536e341 100644 --- a/internal/gamepad/api_xbox_windows.go +++ b/internal/gamepad/api_xbox_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/extern_android.go b/internal/gamepad/extern_android.go index ca328f05c..b1e016c67 100644 --- a/internal/gamepad/extern_android.go +++ b/internal/gamepad/extern_android.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_android.go b/internal/gamepad/gamepad_android.go index ebd02c673..ea01f574a 100644 --- a/internal/gamepad/gamepad_android.go +++ b/internal/gamepad/gamepad_android.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_darwin.go b/internal/gamepad/gamepad_darwin.go index 4c229fc3e..977b8c382 100644 --- a/internal/gamepad/gamepad_darwin.go +++ b/internal/gamepad/gamepad_darwin.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !ios && !nintendosdk -// +build !ios,!nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_desktop_windows.go b/internal/gamepad/gamepad_desktop_windows.go index 09b208ce5..b686d1762 100644 --- a/internal/gamepad/gamepad_desktop_windows.go +++ b/internal/gamepad/gamepad_desktop_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_ios.go b/internal/gamepad/gamepad_ios.go index 8dc0a23b3..2700683d9 100644 --- a/internal/gamepad/gamepad_ios.go +++ b/internal/gamepad/gamepad_ios.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_linux.go b/internal/gamepad/gamepad_linux.go index dd413f49f..77259dd97 100644 --- a/internal/gamepad/gamepad_linux.go +++ b/internal/gamepad/gamepad_linux.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !nintendosdk -// +build !android,!nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_nintendosdk.go b/internal/gamepad/gamepad_nintendosdk.go index 711d3c52e..da1baec93 100644 --- a/internal/gamepad/gamepad_nintendosdk.go +++ b/internal/gamepad/gamepad_nintendosdk.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build nintendosdk -// +build nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_null.go b/internal/gamepad/gamepad_null.go index 56cbe2886..7ec164538 100644 --- a/internal/gamepad/gamepad_null.go +++ b/internal/gamepad/gamepad_null.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !darwin && !js && !linux && !windows -// +build !darwin,!js,!linux,!windows package gamepad diff --git a/internal/gamepad/gamepad_windows.go b/internal/gamepad/gamepad_windows.go index 7cf49415f..273661f7a 100644 --- a/internal/gamepad/gamepad_windows.go +++ b/internal/gamepad/gamepad_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/gamepad/gamepad_xbox_windows.go b/internal/gamepad/gamepad_xbox_windows.go index de7bc5eb6..84b3bcc24 100644 --- a/internal/gamepad/gamepad_xbox_windows.go +++ b/internal/gamepad/gamepad_xbox_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package gamepad diff --git a/internal/glfw/callback_notwindows.go b/internal/glfw/callback_notwindows.go index 2b9bbe27d..da822aba3 100644 --- a/internal/glfw/callback_notwindows.go +++ b/internal/glfw/callback_notwindows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !js && !windows -// +build !js,!windows package glfw diff --git a/internal/glfw/const.go b/internal/glfw/const.go index 968add24b..0f8f7edda 100644 --- a/internal/glfw/const.go +++ b/internal/glfw/const.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !js -// +build !js package glfw diff --git a/internal/glfw/glfw_notwindows.go b/internal/glfw/glfw_notwindows.go index 68b4b8ed0..18011a05f 100644 --- a/internal/glfw/glfw_notwindows.go +++ b/internal/glfw/glfw_notwindows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !windows && !js -// +build !windows,!js package glfw diff --git a/internal/glfw/keys.go b/internal/glfw/keys.go index 74131cfc3..0e056955d 100644 --- a/internal/glfw/keys.go +++ b/internal/glfw/keys.go @@ -15,7 +15,6 @@ // Code generated by genkeys.go using 'go generate'. DO NOT EDIT. //go:build !js -// +build !js package glfw diff --git a/internal/glfw/type_notwindows.go b/internal/glfw/type_notwindows.go index d112eec19..8e254cd47 100644 --- a/internal/glfw/type_notwindows.go +++ b/internal/glfw/type_notwindows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !windows && !js -// +build !windows,!js package glfw diff --git a/internal/graphicscommand/image_notjs.go b/internal/graphicscommand/image_notjs.go index 21570f852..ca0aa0696 100644 --- a/internal/graphicscommand/image_notjs.go +++ b/internal/graphicscommand/image_notjs.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !js -// +build !js package graphicscommand diff --git a/internal/graphicsdriver/directx/api_32bit_windows.go b/internal/graphicsdriver/directx/api_32bit_windows.go index 5b46b09ec..2dd7538ad 100644 --- a/internal/graphicsdriver/directx/api_32bit_windows.go +++ b/internal/graphicsdriver/directx/api_32bit_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build 386 || arm -// +build 386 arm package directx diff --git a/internal/graphicsdriver/directx/api_64bit_windows.go b/internal/graphicsdriver/directx/api_64bit_windows.go index 464fcc204..843609706 100644 --- a/internal/graphicsdriver/directx/api_64bit_windows.go +++ b/internal/graphicsdriver/directx/api_64bit_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build amd64 || arm64 -// +build amd64 arm64 package directx diff --git a/internal/graphicsdriver/directx/api_microsoftgdk_windows.go b/internal/graphicsdriver/directx/api_microsoftgdk_windows.go index 4e5a97f1e..7221d0d34 100644 --- a/internal/graphicsdriver/directx/api_microsoftgdk_windows.go +++ b/internal/graphicsdriver/directx/api_microsoftgdk_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build microsoftgdk -// +build microsoftgdk package directx diff --git a/internal/graphicsdriver/directx/api_notmicrosoftgdk_windows.go b/internal/graphicsdriver/directx/api_notmicrosoftgdk_windows.go index 226f4aadb..e4db9722d 100644 --- a/internal/graphicsdriver/directx/api_notmicrosoftgdk_windows.go +++ b/internal/graphicsdriver/directx/api_notmicrosoftgdk_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !microsoftgdk -// +build !microsoftgdk package directx diff --git a/internal/graphicsdriver/metal/view_macos_darwin.go b/internal/graphicsdriver/metal/view_macos_darwin.go index 2431a7602..47aee137a 100644 --- a/internal/graphicsdriver/metal/view_macos_darwin.go +++ b/internal/graphicsdriver/metal/view_macos_darwin.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !ios -// +build !ios package metal diff --git a/internal/graphicsdriver/opengl/context_gl.go b/internal/graphicsdriver/opengl/context_gl.go index 4d1f4fe34..b23db99c3 100644 --- a/internal/graphicsdriver/opengl/context_gl.go +++ b/internal/graphicsdriver/opengl/context_gl.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !opengles -// +build !android,!ios,!js,!opengles package opengl diff --git a/internal/graphicsdriver/opengl/context_gles.go b/internal/graphicsdriver/opengl/context_gles.go index a84163531..1b896a61d 100644 --- a/internal/graphicsdriver/opengl/context_gles.go +++ b/internal/graphicsdriver/opengl/context_gles.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build (android || ios || opengles) && !js -// +build android ios opengles -// +build !js package opengl diff --git a/internal/graphicsdriver/opengl/gl/conversions_cgo.go b/internal/graphicsdriver/opengl/gl/conversions_cgo.go index 33d33b111..a2fc88c06 100644 --- a/internal/graphicsdriver/opengl/gl/conversions_cgo.go +++ b/internal/graphicsdriver/opengl/gl/conversions_cgo.go @@ -1,7 +1,6 @@ // SPDX-License-Identifier: MIT //go:build !darwin && !windows -// +build !darwin,!windows package gl diff --git a/internal/graphicsdriver/opengl/gl/conversions_nocgo.go b/internal/graphicsdriver/opengl/gl/conversions_nocgo.go index 2ea2043d4..cf8bf3ddd 100644 --- a/internal/graphicsdriver/opengl/gl/conversions_nocgo.go +++ b/internal/graphicsdriver/opengl/gl/conversions_nocgo.go @@ -1,7 +1,6 @@ // SPDX-License-Identifier: MIT //go:build darwin || windows -// +build darwin windows package gl diff --git a/internal/graphicsdriver/opengl/gl/package.go b/internal/graphicsdriver/opengl/gl/package.go index ba9cabc63..8ed31c681 100644 --- a/internal/graphicsdriver/opengl/gl/package.go +++ b/internal/graphicsdriver/opengl/gl/package.go @@ -10,7 +10,6 @@ // For details, see http://oss.sgi.com/projects/FreeB. //go:build !js -// +build !js // Package gl implements Go bindings to OpenGL. package gl diff --git a/internal/graphicsdriver/opengl/gl/package_notpurego.go b/internal/graphicsdriver/opengl/gl/package_notpurego.go index f546ee4e4..deaa63672 100644 --- a/internal/graphicsdriver/opengl/gl/package_notpurego.go +++ b/internal/graphicsdriver/opengl/gl/package_notpurego.go @@ -1,7 +1,6 @@ // SPDX-License-Identifier: MIT //go:build !darwin && !windows -// +build !darwin,!windows package gl diff --git a/internal/graphicsdriver/opengl/gl/package_purego.go b/internal/graphicsdriver/opengl/gl/package_purego.go index da37a3efc..b678b49d9 100644 --- a/internal/graphicsdriver/opengl/gl/package_purego.go +++ b/internal/graphicsdriver/opengl/gl/package_purego.go @@ -1,7 +1,6 @@ // SPDX-License-Identifier: MIT //go:build darwin || windows -// +build darwin windows package gl diff --git a/internal/graphicsdriver/opengl/gl/procaddr_others.go b/internal/graphicsdriver/opengl/gl/procaddr_others.go index d3309f8c1..f0494c7e2 100644 --- a/internal/graphicsdriver/opengl/gl/procaddr_others.go +++ b/internal/graphicsdriver/opengl/gl/procaddr_others.go @@ -1,7 +1,6 @@ // SPDX-License-Identifier: MIT //go:build !darwin && !windows -// +build !darwin,!windows // This file implements GlowGetProcAddress for every supported platform. The // correct version is chosen automatically based on build tags: diff --git a/internal/graphicsdriver/opengl/gles/default.go b/internal/graphicsdriver/opengl/gles/default.go index e394428c3..9cbca4146 100644 --- a/internal/graphicsdriver/opengl/gles/default.go +++ b/internal/graphicsdriver/opengl/gles/default.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios || opengles -// +build android ios opengles package gles diff --git a/internal/graphicsdriver/opengl/gles/gomobile.go b/internal/graphicsdriver/opengl/gles/gomobile.go index 08e8ca0dd..88298193a 100644 --- a/internal/graphicsdriver/opengl/gles/gomobile.go +++ b/internal/graphicsdriver/opengl/gles/gomobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package gles diff --git a/internal/graphicsdriver/opengl/graphics_gl.go b/internal/graphicsdriver/opengl/graphics_gl.go index a7f84cf6e..5977ca58d 100644 --- a/internal/graphicsdriver/opengl/graphics_gl.go +++ b/internal/graphicsdriver/opengl/graphics_gl.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !opengles -// +build !android,!ios,!js,!opengles package opengl diff --git a/internal/graphicsdriver/opengl/graphics_gles.go b/internal/graphicsdriver/opengl/graphics_gles.go index 879e1e23b..cf18ca117 100644 --- a/internal/graphicsdriver/opengl/graphics_gles.go +++ b/internal/graphicsdriver/opengl/graphics_gles.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build (android || ios || opengles) && !js -// +build android ios opengles -// +build !js package opengl diff --git a/internal/graphicsdriver/opengl/graphics_mobile.go b/internal/graphicsdriver/opengl/graphics_mobile.go index baf631da5..d190aa85a 100644 --- a/internal/graphicsdriver/opengl/graphics_mobile.go +++ b/internal/graphicsdriver/opengl/graphics_mobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package opengl diff --git a/internal/graphicsdriver/opengl/shader_gl.go b/internal/graphicsdriver/opengl/shader_gl.go index e964927aa..1281999f9 100644 --- a/internal/graphicsdriver/opengl/shader_gl.go +++ b/internal/graphicsdriver/opengl/shader_gl.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !opengles -// +build !android,!ios,!js,!opengles package opengl diff --git a/internal/graphicsdriver/opengl/shader_gles.go b/internal/graphicsdriver/opengl/shader_gles.go index 92429475b..f309af4a8 100644 --- a/internal/graphicsdriver/opengl/shader_gles.go +++ b/internal/graphicsdriver/opengl/shader_gles.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build (android || ios || opengles) && !js -// +build android ios opengles -// +build !js package opengl diff --git a/internal/microsoftgdk/microsoftgdk_windows.go b/internal/microsoftgdk/microsoftgdk_windows.go index bfca00fa8..470e57585 100644 --- a/internal/microsoftgdk/microsoftgdk_windows.go +++ b/internal/microsoftgdk/microsoftgdk_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build microsoftgdk -// +build microsoftgdk package microsoftgdk diff --git a/internal/microsoftgdk/notmicrosoftgdk.go b/internal/microsoftgdk/notmicrosoftgdk.go index d8940c372..e5b0b323e 100644 --- a/internal/microsoftgdk/notmicrosoftgdk.go +++ b/internal/microsoftgdk/notmicrosoftgdk.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !windows || !microsoftgdk -// +build !windows !microsoftgdk package microsoftgdk diff --git a/internal/nintendosdk/nintendosdk.go b/internal/nintendosdk/nintendosdk.go index b06e0664b..ad5c313f6 100644 --- a/internal/nintendosdk/nintendosdk.go +++ b/internal/nintendosdk/nintendosdk.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build nintendosdk -// +build nintendosdk package nintendosdk diff --git a/internal/png/gen.go b/internal/png/gen.go index 1eb555214..b28a2834e 100644 --- a/internal/png/gen.go +++ b/internal/png/gen.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/processtest_test.go b/internal/processtest/processtest_test.go index 61ae2b190..0d46cdd00 100644 --- a/internal/processtest/processtest_test.go +++ b/internal/processtest/processtest_test.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js -// +build !android,!ios,!js package processtest_test diff --git a/internal/processtest/testdata/issue1753.go b/internal/processtest/testdata/issue1753.go index e991db248..a1ca668a4 100644 --- a/internal/processtest/testdata/issue1753.go +++ b/internal/processtest/testdata/issue1753.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2079.go b/internal/processtest/testdata/issue2079.go index 495c4e827..19fe6fd4d 100644 --- a/internal/processtest/testdata/issue2079.go +++ b/internal/processtest/testdata/issue2079.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2089.go b/internal/processtest/testdata/issue2089.go index a2932da03..4fe2cb2e1 100644 --- a/internal/processtest/testdata/issue2089.go +++ b/internal/processtest/testdata/issue2089.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2129.go b/internal/processtest/testdata/issue2129.go index 1c19acc3a..dbbfbafe5 100644 --- a/internal/processtest/testdata/issue2129.go +++ b/internal/processtest/testdata/issue2129.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2138.go b/internal/processtest/testdata/issue2138.go index c6366a02e..2a040628b 100644 --- a/internal/processtest/testdata/issue2138.go +++ b/internal/processtest/testdata/issue2138.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2154_1.go b/internal/processtest/testdata/issue2154_1.go index 9be4ff2c9..9073b2103 100644 --- a/internal/processtest/testdata/issue2154_1.go +++ b/internal/processtest/testdata/issue2154_1.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main @@ -32,7 +31,7 @@ func init() { h = 2 ) - //src2 := ebiten.NewImage(1, 1) + // src2 := ebiten.NewImage(1, 1) src0 := ebiten.NewImage(w, h) src0.Fill(color.RGBA{0xff, 0xff, 0xff, 0xff}) diff --git a/internal/processtest/testdata/issue2154_2.go b/internal/processtest/testdata/issue2154_2.go index d910a2662..17f0fcdf5 100644 --- a/internal/processtest/testdata/issue2154_2.go +++ b/internal/processtest/testdata/issue2154_2.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2162.go b/internal/processtest/testdata/issue2162.go index 9b7ea59de..5428b74b5 100644 --- a/internal/processtest/testdata/issue2162.go +++ b/internal/processtest/testdata/issue2162.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2180.go b/internal/processtest/testdata/issue2180.go index 3b25eefc8..d3b8fb966 100644 --- a/internal/processtest/testdata/issue2180.go +++ b/internal/processtest/testdata/issue2180.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2362.go b/internal/processtest/testdata/issue2362.go index 821fd535b..088471f12 100644 --- a/internal/processtest/testdata/issue2362.go +++ b/internal/processtest/testdata/issue2362.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/processtest/testdata/issue2390.go b/internal/processtest/testdata/issue2390.go index 59689cb5a..25628a1d4 100644 --- a/internal/processtest/testdata/issue2390.go +++ b/internal/processtest/testdata/issue2390.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build ignore -// +build ignore package main diff --git a/internal/ui/api_windows.go b/internal/ui/api_windows.go index 70ced6c13..3d047ebca 100644 --- a/internal/ui/api_windows.go +++ b/internal/ui/api_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package ui diff --git a/internal/ui/hideconsole_notwindows.go b/internal/ui/hideconsole_notwindows.go index 06a9bd06a..a226f0580 100644 --- a/internal/ui/hideconsole_notwindows.go +++ b/internal/ui/hideconsole_notwindows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !windows || nintendosdk -// +build !windows nintendosdk package ui diff --git a/internal/ui/hideconsole_windows.go b/internal/ui/hideconsole_windows.go index 0cc17789b..b1b5e61ad 100644 --- a/internal/ui/hideconsole_windows.go +++ b/internal/ui/hideconsole_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package ui diff --git a/internal/ui/input_glfw.go b/internal/ui/input_glfw.go index ceb1e61c5..0afc44f7d 100644 --- a/internal/ui/input_glfw.go +++ b/internal/ui/input_glfw.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk -// +build !android,!ios,!js,!nintendosdk package ui diff --git a/internal/ui/input_mobile.go b/internal/ui/input_mobile.go index 1973fbc8b..5f987caef 100644 --- a/internal/ui/input_mobile.go +++ b/internal/ui/input_mobile.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build (android || ios) && !nintendosdk -// +build android ios -// +build !nintendosdk package ui diff --git a/internal/ui/input_nintendosdk.go b/internal/ui/input_nintendosdk.go index bcbaf9580..9cca96190 100644 --- a/internal/ui/input_nintendosdk.go +++ b/internal/ui/input_nintendosdk.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build nintendosdk -// +build nintendosdk package ui diff --git a/internal/ui/keys_glfw.go b/internal/ui/keys_glfw.go index 57d024f91..fea83efd5 100644 --- a/internal/ui/keys_glfw.go +++ b/internal/ui/keys_glfw.go @@ -15,7 +15,6 @@ // Code generated by genkeys.go using 'go generate'. DO NOT EDIT. //go:build !android && !ios && !js && !nintendosdk -// +build !android,!ios,!js,!nintendosdk package ui diff --git a/internal/ui/keys_mobile.go b/internal/ui/keys_mobile.go index 4728021b6..6f1f84679 100644 --- a/internal/ui/keys_mobile.go +++ b/internal/ui/keys_mobile.go @@ -15,8 +15,6 @@ // Code generated by genkeys.go using 'go generate'. DO NOT EDIT. //go:build (android || ios) && !nintendosdk -// +build android ios -// +build !nintendosdk package ui diff --git a/internal/ui/run_notsinglethread.go b/internal/ui/run_notsinglethread.go index 76f032433..6a66e4f1f 100644 --- a/internal/ui/run_notsinglethread.go +++ b/internal/ui/run_notsinglethread.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk && !ebitenginesinglethread && !ebitensinglethread -// +build !android,!ios,!js,!nintendosdk,!ebitenginesinglethread,!ebitensinglethread package ui diff --git a/internal/ui/run_singlethread.go b/internal/ui/run_singlethread.go index cbac47a93..8ce2387e8 100644 --- a/internal/ui/run_singlethread.go +++ b/internal/ui/run_singlethread.go @@ -13,11 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk && (ebitenginesinglethread || ebitensinglethread) -// +build !android -// +build !ios -// +build !js -// +build !nintendosdk -// +build ebitenginesinglethread ebitensinglethread package ui diff --git a/internal/ui/ui_glfw.go b/internal/ui/ui_glfw.go index c5bf9a384..4d0ab786d 100644 --- a/internal/ui/ui_glfw.go +++ b/internal/ui/ui_glfw.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk -// +build !android,!ios,!js,!nintendosdk package ui diff --git a/internal/ui/ui_glfw_darwin.go b/internal/ui/ui_glfw_darwin.go index e1cf131a8..c7abb2c27 100644 --- a/internal/ui/ui_glfw_darwin.go +++ b/internal/ui/ui_glfw_darwin.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !ios && !nintendosdk -// +build !ios,!nintendosdk package ui diff --git a/internal/ui/ui_glfw_gl.go b/internal/ui/ui_glfw_gl.go index a2c7a1409..b5f10a193 100644 --- a/internal/ui/ui_glfw_gl.go +++ b/internal/ui/ui_glfw_gl.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk && !opengles -// +build !android,!ios,!js,!nintendosdk,!opengles package ui diff --git a/internal/ui/ui_glfw_gles.go b/internal/ui/ui_glfw_gles.go index a7338552d..edb9353f0 100644 --- a/internal/ui/ui_glfw_gles.go +++ b/internal/ui/ui_glfw_gles.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk && opengles -// +build !android,!ios,!js,!nintendosdk,opengles package ui diff --git a/internal/ui/ui_glfw_unix.go b/internal/ui/ui_glfw_unix.go index af0a3e7a7..2bc00984b 100644 --- a/internal/ui/ui_glfw_unix.go +++ b/internal/ui/ui_glfw_unix.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !darwin && !js && !windows && !nintendosdk -// +build !android,!darwin,!js,!windows,!nintendosdk package ui diff --git a/internal/ui/ui_glfw_windows.go b/internal/ui/ui_glfw_windows.go index 9350104ad..79ae17ab5 100644 --- a/internal/ui/ui_glfw_windows.go +++ b/internal/ui/ui_glfw_windows.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package ui diff --git a/internal/ui/ui_mobile.go b/internal/ui/ui_mobile.go index 73527e7d8..91a47f1d4 100644 --- a/internal/ui/ui_mobile.go +++ b/internal/ui/ui_mobile.go @@ -13,8 +13,6 @@ // limitations under the License. //go:build (android || ios) && !nintendosdk -// +build android ios -// +build !nintendosdk package ui diff --git a/internal/ui/ui_nintendosdk.go b/internal/ui/ui_nintendosdk.go index 60373ff1a..08250b317 100644 --- a/internal/ui/ui_nintendosdk.go +++ b/internal/ui/ui_nintendosdk.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build nintendosdk -// +build nintendosdk package ui diff --git a/internal/ui/window_glfw.go b/internal/ui/window_glfw.go index 839b79be5..a9f529dbb 100644 --- a/internal/ui/window_glfw.go +++ b/internal/ui/window_glfw.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios && !js && !nintendosdk -// +build !android,!ios,!js,!nintendosdk package ui diff --git a/internal/vibrate/vibrate_android.go b/internal/vibrate/vibrate_android.go index 6be434440..aeb42a6e8 100644 --- a/internal/vibrate/vibrate_android.go +++ b/internal/vibrate/vibrate_android.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package vibrate diff --git a/internal/vibrate/vibrate_ios.go b/internal/vibrate/vibrate_ios.go index 755dea38a..a8a23419f 100644 --- a/internal/vibrate/vibrate_ios.go +++ b/internal/vibrate/vibrate_ios.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !nintendosdk -// +build !nintendosdk package vibrate diff --git a/internal/vibrate/vibrate_null.go b/internal/vibrate/vibrate_null.go index 0fe2a371c..0c333f99d 100644 --- a/internal/vibrate/vibrate_null.go +++ b/internal/vibrate/vibrate_null.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build (!android && !ios && !js) || nintendosdk -// +build !android,!ios,!js nintendosdk package vibrate diff --git a/mobile/ebitenmobileview/input.go b/mobile/ebitenmobileview/input.go index eb9b7db46..1e552a2bd 100644 --- a/mobile/ebitenmobileview/input.go +++ b/mobile/ebitenmobileview/input.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package ebitenmobileview diff --git a/mobile/ebitenmobileview/mobile.go b/mobile/ebitenmobileview/mobile.go index bebce6537..6616b45f8 100644 --- a/mobile/ebitenmobileview/mobile.go +++ b/mobile/ebitenmobileview/mobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios // Package ebitenmobileview offers functions for OpenGL/Metal view of mobiles. // diff --git a/mobile/impl_mobile.go b/mobile/impl_mobile.go index 69968c9da..b8b864762 100644 --- a/mobile/impl_mobile.go +++ b/mobile/impl_mobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package mobile diff --git a/mobile/impl_notmobile.go b/mobile/impl_notmobile.go index 4a72c3837..93364daa3 100644 --- a/mobile/impl_notmobile.go +++ b/mobile/impl_notmobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build !android && !ios -// +build !android,!ios package mobile diff --git a/run_mobile.go b/run_mobile.go index 847058705..543b61324 100644 --- a/run_mobile.go +++ b/run_mobile.go @@ -13,7 +13,6 @@ // limitations under the License. //go:build android || ios -// +build android ios package ebiten