bend-lint-rules
Releases (5)
-
0.2.2.0 invalid
expected a package named bend-lint-api@0.2.2.0 on https://hub.bend-lang.com
26 files do not load
- language/decreasing_call.bend
- language/forward_reference.bend
- language/reused_binder.bend
- language/unneeded_plus.bend
- layout/canon_import_path.bend
- layout/case.bend
- layout/directive_order.bend
- layout/format.bend
- layout/imports.bend
- lib/linter/directives.bend
- lib/text/main.bend
- no_unused/imports.bend
- performance/append_in_loop.bend
- performance/bang_after_fork.bend
- performance/dead_accumulator.bend
- performance/deep_call_in_fork.bend
- performance/drop_in_bang.bend
- performance/eager_branch.bend
- performance/gpu_fit.bend
- performance/list_index_loop.bend
- performance/loop_invariant_call.bend
- performance/missed_fork.bend
- performance/repeated_call.bend
- performance/template_value_field.bend
- performance/unused_result.bend
- rules.bend
-
0.2.1.0 invalid
expected a package named bend-lint-api@0.2.1.0 on https://hub.bend-lang.com
26 files do not load
- language/decreasing_call.bend
- language/forward_reference.bend
- language/reused_binder.bend
- language/unneeded_plus.bend
- layout/canon_import_path.bend
- layout/case.bend
- layout/directive_order.bend
- layout/format.bend
- layout/imports.bend
- lib/linter/directives.bend
- lib/text/main.bend
- no_unused/imports.bend
- performance/append_in_loop.bend
- performance/bang_after_fork.bend
- performance/dead_accumulator.bend
- performance/deep_call_in_fork.bend
- performance/drop_in_bang.bend
- performance/eager_branch.bend
- performance/gpu_fit.bend
- performance/list_index_loop.bend
- performance/loop_invariant_call.bend
- performance/missed_fork.bend
- performance/repeated_call.bend
- performance/template_value_field.bend
- performance/unused_result.bend
- rules.bend
-
0.2.0.0 indexed
-
0.1.1.0 unindexed
-
0.1.0.0 unindexed
Definitions (801)
language/decreasing_call.bend
- type ParamA parameter: its binder, whether it is erased (it does not count), and its name.
- type SmallerA binder known smaller than the parameter or field `root`: a field a match took apart from it.
- type VerdictWhat the arguments of a call say: it decreases; it does not, at the argument numbered `at` (from 0) for the parameter `param`, or with every argument unchanged; or the rule cannot tell.
- type LoopWhat judging a definition's calls of itself reads: its parameters, the binders its lets bind (an argument that is one stands for its value, which the rule does not follow), and the file's text.
- def Param.is_erasedFunctions =========
- def Param.all
- def rootsThe roots that `binder` is smaller than, with `binder` itself.
- def pairs.of
- def pairs
- def takenWhat a case's patterns take apart: each pattern, a constructor, makes its variables smaller than its scrutinee, and than all that scrutinee is smaller than.
- def known.atWhat a case below `parent` takes apart, if `node` is one and `parent` its match.
- def knownWhat the cases above a call (`chain`, outermost first; `parent` is the node above the first) take apart.
- def is_smaller
- def stepWhat one argument, a variable, says: none to read on (it is the parameter, unchanged), else the verdict: it decreases (a field a match took apart), the rule cannot tell (a let's name), or it fails.
- def verdictThe verdict on a call's arguments against the parameters, from the one numbered `at`.
- def ordinal
- def message
- def finding
- def callThe findings about a call of its definition to itself, below `path`.
- def callsThe same, if `node` is a live call of its definition to itself (`recursive`).
- def visit
- def letThe binders the lets of a definition bind, below `path`.
- def defsThe findings in each definition among `nodes`, onto `out`.
- def run
- def rule
language/forward_reference.bend
- type PlaceA definition of the file: where it is among the file's nodes, and its name as written.
- type UserWhat judging the uses in one definition reads: where each definition of the file is, by the name the check gives it; and where the definition is, with its name.
- def messageFunctions =========
- def placesWhere each definition among `nodes`, the file's, is, from `at`, onto `out`.
- def belowThe finding about a use of `used` from `user`, if `used` is below it.
- def judged
- def User.places
- def use
- def usersThe findings in the definitions among `nodes`, from `at`, onto `out`.
- def run
- def rule
language/reused_binder.bend
- type OnceA binder that can be used once: its number, and its name.
- type SeenThe live uses of one binder among some nodes: the first, and the first that an earlier one on its path precedes, if any.
- def messageFunctions =========
- def Once.ofThe binders a definition declares that can be used once, as their syntax says for sure: a parameter written without `+` (unless one is `bare`: its quantity is its law's), and a let's name written without `+`.
- def scrutineeThe binders a match takes apart: the variables right under it, its scrutinees.
- def is_live_insideWhether the nodes under `node`, which is live if `live`, are: a body is; a type is not (an equality, a function or pair type, a type's arguments).
- def is_match
- def is_annotation
- def Seen.ofWhat a node's uses of `b` are: its own, if it is a live use, else `under`'s, those under it.
- def Seen.thenThe uses of `seen`, then those of `next`, the nodes after them: on one path, or, if `apart`, on paths of their own.
- def scanThe live uses of `b` among `nodes`, the nodes under one, after `seen`: `live` says whether they are live, `apart` whether each is a path of its own (a match's), and `typed` whether only the first is live (an annotation's: the second is a type); `at` counts the nodes.
- def finding
- def judgedThe finding about a binder of `owner` used twice on one path, unless a match takes it apart (`matched`).
- def judgeThe finding about each of `onces`, binders of `owner`, used twice on one path, onto `out`; a binder a match takes apart (`matched`) is skipped.
- def defs
- def run
- def rule
language/unneeded_plus.bend
- type OwnerWhat judging the binders of one definition reads: the definitions of the file used as values (named, not called), as the check names them; the definition, as the check names it; and its binders that a match or a let takes apart.
- def value.visitThe definition a reference below `path` names, if it is used as a value: not as the function of an application.
- def is_constructed
- def matched.visitThe binder a variable below `path` uses, if it is taken apart there: it is a match's scrutinee, or the value of a let with a constructor pattern (`Vert{x, y} = v`).
- def is_onceWhether a binder used `used` times needs no `+`: none or one use.
- def plusThe binder a node of this kind declares with `+`, if it does.
- def is_parameter
- def message
- def is_needlessWhether a `+` binder its body uses at most once (`once`) needs no `+`: not if a match takes it apart, nor if it is a parameter of a definition used as a value: the type it must have can ask for the `+`.
- def judgedThe findings about a `+` binder (`binder`, if the node declares one) that its facts say its body uses at most once.
- def visit
- def defs
- def run
- def rule
layout/canon_import_path.bend
- def segments.stepPaths =====
- def segments.goA path's segments, last first: "" and "." dropped, ".." applied.
- def segments
- def upsEach segment of `from` as "..", then `to`.
- def is_same_headWhether both lists start with the same segment.
- def relative.go
- def relativeThe segments that lead from the folder `from` to `to`.
- def canonThe segments as a path that starts with ./ or ../.
- def is_hubHub imports name a package, not a path.
- def verdict
- def judgeA written path, against the one from `file` to `loads`, the file its import loads.
- def pathsThe findings on the paths of `nodes`' imports, onto `out`.
- def run
- def rule
layout/case.bend
- type CaseTypes =====
- def has_no_underscoreCase ====
- def has_no_capital
- def is_pascal.rest
- def is_pascal
- def is_snake.of
- def is_snake
- def fits
- def has_small_head
- def has_capital_head
- def snake_cap
- def snake`s` in snake_case: a word starts at a capital after a small letter or digit, or at the last capital of a run before a small letter.
- def pascal`s` in PascalCase: `_` goes, and the character after it becomes a capital.
- def recased
- def endsWhether the type the last of `nodes` writes ends in a sort: it is one, or a function type whose result does.
- def typedThe case of a name whose written type is the last of `nodes`: none written, either.
- def returnsThe case of a def's name, by its written return type, among its nodes.
- def wantedThe case a declaration's name takes, if the file chooses it.
- def nounA name of `syntax`, in a message.