Elm Exactly

Restrictionmodules-program

Stated in Section 3.7 Syntactic Restrictions.

The following restrictions concern a program, and Chapter 9 imposes them. The var\var of every port declaration of every module of a program is distinct from the var\var of every other port declaration of the program and from the name of every manager of the platform (Chapter 8). No module of a program has the identifier of a module of the initial basis. In the main module, main does not occur free in the expression of its own declaration, so main is not recursive, even through a delayed occurrence.

Read it in its chapter·Permanent address: /standard/restrictions/modules-program

Tests (1)

In Lean

This restriction is decided on the syntax tree, as the book states it, by Src.ModulesProgram (StandardElmMech/Src/Restrictions.lean, line 343), whose decider the kernel runs; each written test program has a theorem that it meets the restrictions, or that it breaks this one. Broken by: StandardA84DuplicatePortNameTest.

Discussions

Discuss this restriction·Search the discussions on GitHub

Discussions are on GitHub; one about this restriction has [res:modules-program] in its title.

A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.