Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Utils.php

function Utils::getLineTerminators

Returns line terminators array

Return value

array

2 calls to Utils::getLineTerminators()
Utils::quoteLiteralString in vendor/mck89/peast/lib/Peast/Syntax/Utils.php
This function converts a string to a quoted javascript string
Utils::unquoteLiteralString in vendor/mck89/peast/lib/Peast/Syntax/Utils.php
This function takes a string as it appears in the source code and returns an unquoted version of it

File

vendor/mck89/peast/lib/Peast/Syntax/Utils.php, line 91

Class

Utils
Utilities class.

Namespace

Peast\Syntax

Code

protected static function getLineTerminators() {
    if (!self::$lineTerminatorsCache) {
        self::$lineTerminatorsCache = array();
        foreach (Scanner::$lineTerminatorsChars as $char) {
            self::$lineTerminatorsCache[] = is_int($char) ? self::unicodeToUtf8($char) : $char;
        }
    }
    return self::$lineTerminatorsCache;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal