User Tools

Site Tools


01_user_documentation:07_rgg_xl:02_xl:10_rgg_addition:04_operator_overload:02_function

Functions

Instances of de.grogra.xl.lang.FloatToFloat represent functions which take floats as input and return values of type float. Such instances cant be created by:

  • lambda expressions of the XL programming language, e.g.,
    FloatToFloat f = float x => float
  • some expression containing x

Index

  • FloatToFloat[float] compute the FloatToFloat function on the float argument.

The package de.grogra.math contains many predefined FloatToFloat objects, and is imported by default in RGG files. Thus, it is possible to write:

new Abs()[-5]; // return 5
//or define the object once and use it several times:
static Abs ABS = new Abs();
ABS[-5];
ABS[42]; // ...
01_user_documentation/07_rgg_xl/02_xl/10_rgg_addition/04_operator_overload/02_function.txt · Last modified: 2025/08/20 10:32 by gaetan