[BE] Various linter fixes

This commit is contained in:
Lauren Tan
2023-02-13 16:52:04 -05:00
parent 31d8aad40e
commit 985a289a4c
3 changed files with 3 additions and 6 deletions
@@ -698,8 +698,6 @@ function codegenInstructionValue(
break;
}
case "FunctionExpression": {
const id =
instrValue.name !== null ? t.identifier(instrValue.name) : null;
value = instrValue.expr;
break;
}
@@ -15,7 +15,6 @@ import {
makeScopeId,
Place,
ReactiveScope,
ScopeId,
} from "../HIR/HIR";
import { eachInstructionOperand } from "../HIR/visitors";
import DisjointSet from "../Utils/DisjointSet";
@@ -77,7 +76,7 @@ import { assertExhaustive } from "../Utils/utils";
* mutate(x); // bc y is aliased here, it should still be considered mutable above
* ```
*/
export function inferReactiveScopeVariables(fn: HIRFunction) {
export function inferReactiveScopeVariables(fn: HIRFunction): void {
// Represents the set of reactive scopes as disjoint sets of identifiers
// that mutate together.
const scopeIdentifiers = new DisjointSet<Identifier>();
@@ -20,7 +20,7 @@ type VisitorState = {
nextId: number;
};
class Visitor extends ReactiveFunctionVisitor<VisitorState> {
override visitScope(block: ReactiveScopeBlock, state: VisitorState) {
override visitScope(block: ReactiveScopeBlock, state: VisitorState): void {
this.traverseScope(block, state);
for (const dep of block.scope.dependencies) {
const { identifier } = dep.place;
@@ -63,7 +63,7 @@ class Visitor extends ReactiveFunctionVisitor<VisitorState> {
}
}
}
export function promoteUsedTemporaries(fn: ReactiveFunction) {
export function promoteUsedTemporaries(fn: ReactiveFunction): void {
const state: VisitorState = {
nextId: 0,
temporaries: new Map(),