The basic idea is that if you had a package github.com/foobar/foobar with a main.go like this:

//go:generate go github.com/foobar/foobar/tools/genversion.go

package main

var Version string

func main() {
    fmt.Printf("foobar v%s\n" + Version)
    // ...
}
Then your tools/genversion.go would template a file like this:

package main

func init() {
    Version = "v1.3.1"
}
The basic idea is that if you had a package github.com/foobar/foobar with a main.go like this:

//go:generate go github.com/foobar/foobar/tools/genversion.go

package main

var Version string

func main() {
    fmt.Printf("foobar v%s\n" + Version)
    // ...
}
Then your tools/genversion.go would template a file like this:

package main

func init() {
    Version = "v1.3.1"
}
So finally constructor function prototype’s linkage would look something like this:

Warrior.prototype.__proto__ = Hero.prototype;
I think what you really mean is:

let newArray = seaCreatures.slice(-seaCreatures.length + 1);
This could result into something like:

const warrior = new Warrior();
console.log(warrior instanceof Hero); // true
console.log(warrior instanceof Warrior); // false
What one should do instead is:

Warrior.prototype.__proto__ = Object.create(Hero.prototype);
One thing to point out about Object.assign is that now character is really a pointer to name.

~$ node --version
v10.8.0

~$ node
> // Initialize an object
undefined
> const name = {
...     firstName: 'Philip',
...     lastName: 'Fry'
... };
undefined
>
> // Initialize another object
undefined
> const details = {
...     job: 'Delivery Boy',
...     employer: 'Planet Express'
... };
undefined
>
> // Merge the objects
undefined
> const character = Object.assign(name, details);
undefined
>
> console.log(character);
{ firstName: 'Philip',
  lastName: 'Fry',
  job: 'Delivery Boy',
  employer: 'Planet Express' }
undefined
> console.log(name);
{ firstName: 'Philip',
  lastName: 'Fry',
  job: 'Delivery Boy',
  employer: 'Planet Express' }
undefined
> console.log(details);
{ job: 'Delivery Boy', employer: 'Planet Express' }
undefined
> name.foo = '1'
'1'
> character
{ firstName: 'Philip',
  lastName: 'Fry',
  job: 'Delivery Boy',
  employer: 'Planet Express',
  foo: '1' }
Rather, I think you should set the [[Prototype]] property of Healer’s prototype to point to Hero’s prototype. See this example for what seem like a better way to me:

function Hero(name, level){
    this.name = name;
    this.level=level;
}

function Healer(name, level, spell){
    Hero.call(this, name, level);
	this.spell = spell;
}

Hero.prototype.greet = function(){return "I am " + this.name}
Healer.prototype.heal = function(){return this.name + " casts " + this.spell}

var healer = new Healer("Pyro", 126, "Resta");

healer.heal()
// "Pyro casts Resta"
healer.greet() // undefined, as expected
// VM1872:1 Uncaught TypeError: healer.greet is not a function

// Instead of setting Healer.prototype, we're setting [[Prototype]] of Healer.prototype
Object.setPrototypeOf(Healer.prototype, Hero.prototype);

healer.greet() // This is now found, by traversing the prototype chain. You don't have to reassign healer. 
// "I am Pyro"
healer.heal() // healer's prototype is still Healer.prototype so this is fine
// "Pyro casts Resta"

// because prototypes are linked properly, children of Hero automatically obtain new methods defined on Hero
Hero.prototype.charge=function(){return "CHARGE!!"}
healer.charge() // didn't need to change anything on healer object or Healer function
// "CHARGE!!"
healer.constructor // healer still has proper constructor
// ƒ Healer(name, level, spell){
//     Hero.call(this, name, level);
//	this.spell = spell;
// }

Recommend

Using ldflags to Set Version Information for Go Applications Targeting Sub-Package Variables

Using ldflags to Set Version Information for Go Applications Using ldflags with go build

Using ldflags to Set Version Information for Go Applications Building Your Sample Application

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 5 — Aktivierung externer Zugriffe für Ihren normalen Nutzer Wenn das Root-Konto schlüsselbasierte Authentifizierung nutzt.

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 5 — Aktivierung externer Zugriffe für Ihren normalen Nutzer

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 4 — Eine standardmäßige Firewall installieren

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 3 — Vergabe von administrativen Rechten

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 2 — Erstellen eines neuen Nutzers

Ersteinrichtung des Servers mit Ubuntu 18.04 Schritt 1 — Als root anmelden

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 9: Desactivar un entorno virtual

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 8: Probar el entorno virtual

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 7: Activar un entorno virtual

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 6: Crear un entorno virtual

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 5: Instalar venv

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 4: Instalar herramientas adicionales

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 3: Instalar pip

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 2: Comprobar la versión de Python

Cómo instalar Python 3 y configurar un entorno de programación en Ubuntu 20.04 [Guía de inicio rápido] Paso 1: Realizar la actualización y la renovación

Comment créer une application de citations en utilisant AdonisJs et MySQL Étape 6 - Mise en service de l’application

Comment créer une application de citations en utilisant AdonisJs et MySQL Étape 5 - Validation des entrées des utilisateurs

Comment créer une application de citations en utilisant AdonisJs et MySQL Étape 4 - Création de contrôleurs et configuration de routes

Comment créer une application de citations en utilisant AdonisJs et MySQL Étape 3 - Création d’un schéma de base de données

Comment créer une application de citations en utilisant AdonisJs et MySQL Étape 2 - Utilisation du moteur de modèles Edge