---
title: "LogOp: type in IR, TypeShade API reference for developers"
description: "LogOp, a type in IR. The operator tag on Expr.logical: the short-circuiting boolean operators && and ||."
url: https://typeshade.dev/api/logop/
language: en
---

# `LogOp`

Type in IR

The operator tag on Expr.logical: the short-circuiting boolean operators && and ||.

`import type { LogOp } from 'typeshade'`
`import type { LogOp } from 'typeshade/core/ir'`

The signature, the description and the examples come from the compiler's own source at commit af54ddad5.

## Syntax

```ts
type LogOp = '&&' | '||';
```

## Description

The operator tag on `Expr.logical`: the short-circuiting boolean operators `&&` and `||`. Both operands and the result are `bool`. It is a separate `Expr.op` from `binop` because WGSL and GLSL give `&&` and `||` short-circuit evaluation, which a plain binary operator does not have.

## Source

[`src/core/ir/nodes/operators.ts`, line 29](https://github.com/typeshade/typeshade/blob/af54ddad5/src/core/ir/nodes/operators.ts#L29), at commit af54ddad5
