Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "ndarray/casting-modes/docs/types/index.d"

Index

Functions

Functions

Export assignment modes

  • modes(): Array<string>
  • Returns a list of ndarray casting modes.

    Notes

    • The output array contains the following modes:

      • 'none': only allow casting between identical types
      • 'equiv': allow casting between identical and byte swapped types
      • 'safe': only allow "safe" casts
      • 'same-kind': allow "safe" casts and casts within the same kind (e.g., between signed integers or between floats)
      • 'unsafe': allow casting between all types (including between integers and floats)

    Returns Array < string >

    list of ndarray casting modes

    Example

    var list = modes();
    // returns [ 'none', 'equiv', 'safe', 'same-kind', 'unsafe' ]