Language Features

June 26, 2026 ยท View on GitHub

Status of core JavaScript language features in GiavaScript.

Declarations and assignments

FeatureStatus
var declarationAvailable
var without initializerAvailable
Reassignment with =Available
Compound assignment (+=, -=, *=, /=)Available
Postfix increment and decrement (++, --)Available
letNot available
constNot available

Expressions and operators

FeatureStatus
Numeric literals (int, float)Available
String literals (single and double quotes)Available
Arithmetic (+, -, *, /, %)Available
Exponent operator (^, non-standard)Available
Parenthesized expressionsAvailable
Comparisons (<, >, <=, >=)Available
Equality (==, !=)Available
Strict equality (===, !==)Available
Logical operators (&&, ||, !)Available
typeof operatorAvailable
void operatorAvailable
Unary plus (+)Available
Comments (//, /* */)Available
Template literalsAvailable

Equality operator semantics

  • == and != use coercive (loose) equality behavior.
  • === and !== use strict (non-coercive) equality behavior.

typeof semantics

typeof returns string representations of value types:

  • "number" for Int32 and Float64
  • "string" for String
  • "boolean" for Bool
  • "object" for Array, Hash, and null
  • "function" for callable values (user-defined and built-in)
  • "undefined" for undefined and undeclared identifiers (does not throw)

Logical operator semantics

  • a && b: evaluates a first; if a is falsy, returns a and does not evaluate b; otherwise evaluates and returns b.
  • a || b: evaluates a first; if a is truthy, returns a and does not evaluate b; otherwise evaluates and returns b.
  • !a: evaluates a and returns a boolean negation (true/false).
  • a ? b : c: evaluates a first; if a is truthy, evaluates and returns b; otherwise evaluates and returns c.
  • Precedence: ! binds tighter than &&, && binds tighter than ||, and || binds tighter than ? :.

Functions and control flow

FeatureStatus
Function declarations (function name(...) { ... })Available
Function expressions (var f = function(...) { ... })Available
Named function expressions (var f = function name(...) { ... })Available
Arrow functions (() => expr, x => expr, () => { ... })Available
Function callsAvailable
Returning values with returnAvailable
First-class function valuesAvailable
if, else if, elseAvailable
C-style for loops (for (init; condition; update))Available
for...of loops (iterate over arrays and strings)Available
for...in loops (iterate over object keys)Available
break / continue inside loopsAvailable
while / do...while loopsAvailable
Ternary operator (a ? b : c)Available
switch statementsAvailable
throw statementsAvailable
try / catch / finallyAvailable

Values and collections

FeatureStatus
nullAvailable
undefinedAvailable
Array literals and indexingAvailable
Object literalsAvailable
Dot and bracket property accessAvailable
Template literalsAvailable

Classic global functions

FeatureStatus
parseInt()Available
parseFloat()Available
isNaN()Available
readLine()Available
Date.now()Available
new Date()Available
console.log()Available
console.warn()Available
console.error()Available

Notes

  • This reflects the current behavior in the interpreter and specs.
  • let and const declarations return explicit errors: Error: unsupported declaration 'let' and Error: unsupported declaration 'const'.
  • Use var for variable declarations.
  • Statements can be separated by newlines without requiring semicolons. A semicolon is not required when two statements are on separate lines.