// src/framework/shadowlisp/primitives/SlFalse.ts
//
// Vision 49: Boolean false element - IS a Matrix component
//
// <sl-false/> evaluates to false.

import type { SExpr } from '../../../lisp/SExpr';
import { SlMatrixElement } from '../SlMatrixElement';

/**
 * SlFalse - Boolean false element that IS a Matrix component.
 *
 * @example
 * <sl-false/>   => false
 */
export class SlFalse extends SlMatrixElement {
  async evalSelf(_env: SExpr[]): Promise<SExpr> {
    return false;
  }

  toSExpr(): SExpr {
    return false;
  }
}

if (!customElements.get('sl-false')) {
  customElements.define('sl-false', SlFalse);
}
