Rule 8.1
On this page

Rule 8.1

Chapter 8, Functions and entry points Test

An entry point is a top-level function; an entry method on a class must be refused.

The rule text and the parts under it are the compiler's own English, as the design document writes them.

Rationale

this is not a GPU instance, and an entry has no receiver.

Derives from

Entry Points; surface §3 and §4.

How it is verified

Checked by a test. A test, a gate script or a CI workflow names this rule, and the traceability check fails when a file listed below stops naming it.

Where the rule says the compiler enforces it:

TS8035 CLASS_MEMBER (A decorator has no place on "C.k"; an entry is a top-level function.), beside surface §7’s row “@compute method on a class”.

The files that verify it at commit 26de7be8, each at the first line that names the rule:

Explained in

The sections of the surface document that explain this rule, at commit 26de7be8:

Error codes that enforce it

The diagnostic codes the rule names under Enforced by, or whose registry text names the rule:

TS8035 CLASS_MEMBER
A class member shape the surface does not take, or a use of a member the class rules refuse, and a new that builds no class (Rule 8.13).

See also

Source

The rule at commit 26de7be8:

Edit this page Report a problem