HEX
Server: Apache
System: Linux www 6.18.6-i1-amd #905 SMP Mon Jan 19 08:49:07 CET 2026 x86_64
User: sws1073755998 (1073755998)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: //usr/share/nodejs/es-abstract/2022/BigInt/signedRightShift.js
'use strict';

var GetIntrinsic = require('get-intrinsic');

var $TypeError = GetIntrinsic('%TypeError%');

var Type = require('../Type');
var BigIntLeftShift = require('./leftShift');

// https://262.ecma-international.org/11.0/#sec-numeric-types-bigint-signedRightShift

module.exports = function BigIntSignedRightShift(x, y) {
	if (Type(x) !== 'BigInt' || Type(y) !== 'BigInt') {
		throw new $TypeError('Assertion failed: `x` and `y` arguments must be BigInts');
	}

	return BigIntLeftShift(x, -y);
};