From 5d3ad4ba52d7b6fb7c7be2dfb69e064ce07aff64 Mon Sep 17 00:00:00 2001 From: Ayke van Laethem Date: Wed, 27 Jan 2021 23:43:01 +0100 Subject: [PATCH] all: fix main package in examples The package with the main function should always have the name main. This was not the case in three packages. This was silently allowed before, but since a TinyGo change (https://github.com/tinygo-org/tinygo/pull/1592) this now results in a linker failure. Perhaps this should result in a better error message in TinyGo. However, the example code also needs to be fixed, so hence this PR. --- examples/hcsr04/main.go | 2 +- examples/ssd1331/main.go | 2 +- examples/ssd1351/main.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/hcsr04/main.go b/examples/hcsr04/main.go index 4115e97..191bc07 100644 --- a/examples/hcsr04/main.go +++ b/examples/hcsr04/main.go @@ -1,4 +1,4 @@ -package hcsr04 +package main import ( "machine" diff --git a/examples/ssd1331/main.go b/examples/ssd1331/main.go index 3eec908..40877f8 100644 --- a/examples/ssd1331/main.go +++ b/examples/ssd1331/main.go @@ -1,4 +1,4 @@ -package ssd1331 +package main import ( "machine" diff --git a/examples/ssd1351/main.go b/examples/ssd1351/main.go index 00099cc..b1274ad 100644 --- a/examples/ssd1351/main.go +++ b/examples/ssd1351/main.go @@ -1,4 +1,4 @@ -package ssd1351 +package main import ( "machine"