/**
 * @license Copyright (c) 2017-2025, CKSource Holding sp. z o.o. All rights reserved.
 * For licensing, see LICENSE.md.
 */

'use strict';

module.exports = function measureCall( fn, ...args ) {
	const start = performance.now();
	const result = fn( ...args );
	const end = performance.now();

	console.log( `Function ${ fn.name } executed in ${ ( end - start ).toFixed( 2 ) } ms` );

	return result;
};
