---
title: "Deprecation: #91001 - Various methods within GeneralUtility"
manual: "TYPO3 Core Changelog"
version: "main"
permalink: "https://docs.typo3.org/permalink/changelog:deprecation-91001"
source: "Changelog/10.4/Deprecation-91001-VariousMethodsWithinGeneralUtility.rst"
typo3-version: "10.4"
typo3-major: 10
type: "deprecation"
issue: 91001
forge: "https://forge.typo3.org/issues/91001"
tags: ["PHP-API", "FullyScanned", "ext:core"]
rendered: "2026-09-19T11:14:12+00:00"
---

# Deprecation: #91001 - Various methods within GeneralUtility {#deprecation-91001}

See [forge#91001](https://forge.typo3.org/issues/91001)

## Description {#description}

The following methods within GeneralUtility have been marked as deprecated,
as the native PHP methods can be used directly:

-   `GeneralUtility::IPv6Hex2Bin()`
-   `GeneralUtility::IPv6Bin2Hex()`
-   `GeneralUtility::compressIPv6()`
-   `GeneralUtility::milliseconds()`

In addition, these methods are unused by Core and marked as deprecated as well:

-   `GeneralUtility::linkThisUrl()`
-   `GeneralUtility::flushDirectory()`

## Impact {#impact}

Calling any methods directly from PHP will trigger a PHP `E_USER_DEPRECATED` error.

## Affected Installations {#affected-installations}

TYPO3 installations with third-party extensions using any of these methods.

## Migration {#migration}

As the following methods are just wrappers around native PHP methods, it is
recommended to switch to native PHP to speed up performance:

-   `GeneralUtility::IPv6Hex2Bin($hex)`: `inet_pton($hex)`
-   `GeneralUtility::IPv6Bin2Hex($bin)`: `inet_ntop($bin)`
-   `GeneralUtility::compressIPv6($address)`: `inet_ntop(inet_pton($address))`
-   `GeneralUtility::milliseconds()`: `round(microtime(true) * 1000)`

As for `GeneralUtility::linkThisUrl()` it is recommended to migrate to
PSR-7 (UriInterface).

The method `GeneralUtility::flushDirectory()` uses a clearing
folder structure which is only used for caching to avoid race-conditioning. It
is recommended to use `GeneralUtility::rmdir()` or implement the code
directly in the third-party extension.
