/*@
@ ensures \result == (this.value() < x.value() + y.value() ? -1 : this.value() > x.value() + y.value() ? +1 : 0);
@
162051
public /*@ pure @*/ int addAndCmp(FDBigInteger x, FDBigInteger y) {
        FDBigInteger big;
        FDBigInteger small;
        int xSize = x.size();
        int ySize = y.size();
        int bSize;
        int sSize;
        if (xSize >= ySize) {
            big = x;
            small = y;
            bSize = xSize;
            sSize = ySize;
        } else {
            big = y;
            small = x;
            bSize = ySize;
            sSize = xSize;
        }
        int thSize = this.size();
        if (bSize == 0) {
            return thSize == 0 ? 0 : 1;
        }
        if (sSize == 0) {
            return this.cmp(big);
        }
        if (bSize > thSize) {
            return -1;
        }
        if (bSize + 1 < thSize) {
            return 1;
        }
        long top = (big.data[big.nWords - 1] & LONG_MASK);
        if (sSize == bSize) {
            top += (small.data[small.nWords - 1] & LONG_MASK);
        }
        if ((top >>> 32) == 0) {
            if (((top + 1) >>> 32) == 0) {
                // good case - no carry extension
                if (bSize < thSize) {
                    return 1;
                }
                // here sum.nWords == this.nWords
                long v = (this.data[this.nWords - 1] & LONG_MASK);
                if (v < top) {
                    return -1;
                }
                if (v > top + 1) {
                    return 1;
                }
            }
        } else { // (top>>>32)!=0 guaranteed carry extension
            if (bSize + 1 > thSize) {
                return -1;
            }
            // here sum.nWords == this.nWords
            top >>>= 32;
            long v = (this.data[this.nWords - 1] & LONG_MASK);
            if (v < top) {
                return -1;
            }
            if (v > top + 1) {
                return 1;
            }
        }
        return this.cmp(big.add(small));
    }
672273
@Override
    public T data(Object... values) {
        if (values == null || values.length == 0) {
            return (T) this;
        }
        for (Object value : values) {
            this.data().add(value);
        }
        return (T) this;
    }
79947
public function protectedAdd($x_value, $x_negative, $y_value, $y_negative)
    {
        $x_size = count($x_value);
        $y_size = count($y_value);
        if ($x_size == 0) {
            return array(
                MATH_BIGINTEGER_VALUE => $y_value,
                MATH_BIGINTEGER_SIGN => $y_negative
            );
        } elseif ($y_size == 0) {
            return array(
                MATH_BIGINTEGER_VALUE => $x_value,
                MATH_BIGINTEGER_SIGN => $x_negative
            );
        }
        // subtract, if appropriate
        if ($x_negative != $y_negative) {
            if ($x_value == $y_value) {
                return array(
                    MATH_BIGINTEGER_VALUE => array(),
                    MATH_BIGINTEGER_SIGN => false
                );
            }
            $temp = $this->protectedSubtract($x_value, false, $y_value, false);
            $temp[MATH_BIGINTEGER_SIGN] = $this->protectedCompare($x_value, false, $y_value, false) > 0 ?
            $x_negative :
            $y_negative
            ;
            return $temp;
        }
        if ($x_size < $y_size) {
            $size  = $x_size;
            $value = $y_value;
        } else {
            $size  = $y_size;
            $value = $x_value;
        }
        $value[] = 0; // just in case the carry adds an extra digit
        $carry = 0;
        for ($i = 0, $j = 1; $j < $size; $i += 2, $j += 2) {
            $sum = $x_value[$j] * MATH_BIGINTEGER_BASE_FULL + $x_value[$i] + $y_value[$j] * MATH_BIGINTEGER_BASE_FULL +
            $y_value[$i] + $carry;
            $carry = $sum >= MATH_BIGINTEGER_MAX_DIGIT2;
            $sum = $carry ? $sum - MATH_BIGINTEGER_MAX_DIGIT2 : $sum;
            $temp = (int) ($sum / MATH_BIGINTEGER_BASE_FULL);
            $value[$i] = (int) ($sum - MATH_BIGINTEGER_BASE_FULL * $temp);
            $value[$j] = $temp;
        }
        if ($j == $size) { // ie. if $y_size is odd
            $sum = $x_value[$i] + $y_value[$i] + $carry;
            $carry = $sum >= MATH_BIGINTEGER_BASE_FULL;
            $value[$i] = $carry ? $sum - MATH_BIGINTEGER_BASE_FULL : $sum;
            ++ $i; // ie. let $i = $j since we've just done $value[$i]
        }
        if ($carry) {
            for (; $value[$i] == MATH_BIGINTEGER_MAX_DIGIT; ++ $i) {
                $value[$i] = 0;
            }
            ++ $value[$i];
        }
        return array(
            MATH_BIGINTEGER_VALUE => $this->protectedTrim($value),
            MATH_BIGINTEGER_SIGN => $x_negative
        );
    }
683573
function (x, y) {
    if(isNaN(x) || isNaN(y)) {
        throw new Error();
    }

    while (y !== 0) {
        var z = x % y;
        x = y;
        y = z;
    }

    return x;
}
1078186
function () {
            return (isFinite(this.pos.x) && isFinite(this.pos.y) && isFinite(this._width) && isFinite(this._height));
        }
1136666
function (v) {
            var a = this.val,
                x = v.x,
                y = v.y;

            v.x = x * a[0] + y * a[3] + a[6];
            v.y = x * a[1] + y * a[4] + a[7];

            return v;
        }
244176
function () {
            var tmp, a = this.val;

            tmp = a[1];
            a[1] = a[3];
            a[3] = tmp;
            tmp = a[2];
            a[2] = a[6];
            a[6] = tmp;
            tmp = a[5];
            a[5] = a[7];
            a[7] = tmp;

            return this;
        }
1044201
public T value(Object... values) {
        if (values == null || values.length == 0) {
            return (T) this;
        }
        if (this.value == null) {
            this.value = new ArrayList<Object>(values.length);
        }
        if (this.value instanceof List) {
            ((List) this.value).addAll(Arrays.asList(values));
        }
        return (T) this;
    }
611473
function(point) {
        var result = false;

        if (point) {
            result =
                this.x === point.x &&
                this.y === point.y;
        }

        return result;
    }
657167
@Override
    public double doubleValueExact() {
        double d = this.number.doubleValue();
        if (d == Double.NEGATIVE_INFINITY || d == Double.POSITIVE_INFINITY) {
            throw new ArithmeticException("Unable to convert to double: "
                    + this.number);
        }
        return d;
    }
1121460
function(x, y) {
        if (this._translateX === undefined) { this._translateX = 0; }
        if (this._translateY === undefined) { this._translateY = 0; }

        if (x !== null && x !== undefined) { this._translateX = unit(x, 'px'); }
        if (y !== null && y !== undefined) { this._translateY = unit(y, 'px'); }

        this.translate = this._translateX + "," + this._translateY;
      }
512214
function set(x, y, z) {
         if (x !== +x || y !== +y || z !== +z) {
           throw new Error("invalid x, y, z parameters (not a number)");
         }
         /**
          * x value of the vector
          * @public
          * @type Number
          * @name x
          * @memberOf me.Vector3d
          */
         //this.x = x;

         /**
          * y value of the vector
          * @public
          * @type Number
          * @name y
          * @memberOf me.Vector3d
          */
         //this.y = y;

         /**
          * z value of the vector
          * @public
          * @type Number
          * @name z
          * @memberOf me.Vector3d
          */
         //this.z = z;


         return this._set(x, y, z);
       }
739064
@Override
    public void setValue(final double VALUE) {
        if (isEnabled()) {
            super.setValue(VALUE);

            this.stepValue = 2 * ((int) (Math.abs(VALUE) * 10) % 10);
            if (stepValue > 10) {
                stepValue -= 20;
            }

            if (VALUE == 0) {
                this.visibleValue = 90;
            }

            if (VALUE > 0 && VALUE <= 90) {
                this.visibleValue = (90 - VALUE % 360);
            }

            if (VALUE > 90 && VALUE <= 180) {
                this.visibleValue = (VALUE - 90);
            }

            if (VALUE > 180 && VALUE <= 270) {
                this.visibleValue = (270 - VALUE);
            }

            if (VALUE > 270 && VALUE <= 360) {
                this.visibleValue = (VALUE - 270);
            }

            if (VALUE < 0 && VALUE >= -90) {
                this.visibleValue = (90 - Math.abs(VALUE));
            }

            if (VALUE < -90 && VALUE >= -180) {
                this.visibleValue = Math.abs(VALUE) - 90;
            }

            if (VALUE < -180 && VALUE >= -270) {
                this.visibleValue = 270 - Math.abs(VALUE);
            }

            if (VALUE < -270 && VALUE >= -360) {
                this.visibleValue = Math.abs(VALUE) - 270;
            }

            fireStateChanged();
            repaint();
        }
    }
906081
@Override
	public void set(double x1, double y1, double z1) {
		this.x = x1;
		this.y = y1;
		this.z = z1;
	}
306965
private static Number impl_(Number x, Number y) {
        return (x.doubleValue() > y.doubleValue() ? y : x);
    }
843047
function() {
    var stmt = this.stmt()
      , state = this.prevState
      , block
      , op;

    // special-case statements since it
    // is not an expression. We could
    // implement postfix conditionals at
    // the expression level, however they
    // would then fail to enclose properties
    if (this.allowPostfix) {
      this.allowPostfix = false;
      state = 'expression';
    }

    switch (state) {
      case 'assignment':
      case 'expression':
      case 'function arguments':
        while (op =
             this.accept('if')
          || this.accept('unless')
          || this.accept('for')) {
          switch (op.type) {
            case 'if':
            case 'unless':
              stmt = new nodes.If(this.expression(), stmt);
              stmt.postfix = true;
              stmt.negate = 'unless' == op.type;
              this.accept(';');
              break;
            case 'for':
              var key
                , val = this.id().name;
              if (this.accept(',')) key = this.id().name;
              this.expect('in');
              var each = new nodes.Each(val, key, this.expression());
              block = new nodes.Block(this.parent, each);
              block.push(stmt);
              each.block = block;
              stmt = each;
          }
        }
    }

    return stmt;
  }
353622
function(value) {
            	var V = value.elements || value;

            	if (this.elements.length != V.length) 
            	    return this.map(function(v) { return v + value });
            	else
            	    return this.map(function(x, i) { return x + V[i - 1]; });
                }