Returns whether a value is a number literal that shouldn't be divided.
486032
def is_literal_number?(value)
      value.is_a?(Literal) &&
        value.value.is_a?((Sass::Script::Value::Number)) &&
        !value.value.original.nil?
    end
499219
public static boolean isNumber(String value) {
        try {
            Double.parseDouble(value);
        } catch (NumberFormatException nfe) {
            return false;
        }
        return true;
    }
416548
public static function isInteger($value)
    {
        if (!is_scalar($value) || is_float($value)) {
            return false;
        }
        if (is_int($value)) {
            return true;
        }

        return (bool)preg_match('/^-?[0-9]+$/', $value);
    }
833672
function isInt32Hint(node) {
            return int32Hint && node.operator === "|" && node.right &&
              node.right.type === "Literal" && node.right.value === 0;
        }
1293642
def is_int_like(value):
    
    try:
        if isinstance(value, int): return True
        return int(value) == value and str(value).isdigit()
    except:
        return False
768636
public boolean isAnyNumeric(){
    int cnt =0;
    for(int i=0;i<_cols.length;++i) {
      if( !_cols[i]._ignored && !_cols[i]._response && _cols[i]._isNumeric) {
        cnt = 1;
        break;
      }
    }
    if(cnt ==1) return true;
    else return false;
  }
129817
def is_valid(number):
    """"""
    n = str(number)
    if not n.isdigit():
        return False
    return int(n[-1]) == get_check_digit(n[:-1])
1320718
function(num) {
            if(typeof num !== "number") {
                return NaN;
            }
            var isNegative = (num < 0),
                result;

            if(isNegative) {
                num = -num;
            }
            if(num < 10) {
                num += (10 - num) / 10;
            }
            result = this.logBaseTen(num);
            return (isNegative) ? -result : result;
        }
430011
def _format_num(self, value):
        """"""
        # (value is True or value is False) is ~5x faster than isinstance(value, bool)
        if value is True or value is False:
            raise TypeError('value must be a Number, not a boolean.')
        return self.num_type(value)
874669
function assertLong(value, unsigned) {
    if (typeof value === 'number') {
        return Long.fromNumber(value, unsigned);
    } else if (typeof value === 'string') {
        return Long.fromString(value, unsigned);
    } else if (value && value instanceof Long) {
        if (typeof unsigned !== 'undefined') {
            if (unsigned && !value.unsigned) return value.toUnsigned();
            if (!unsigned && value.unsigned) return value.toSigned();
        }
        return value;
    } else
        throw TypeError("Illegal value: "+value+" (not an integer or Long)");
}
817263
def StrictlyAlphanumeric(msg=None):
    '''
    
    '''
    def fn(value):
        if not (
            isinstance(value, basestring) and
            value.isalnum() and not
            value.isdigit() and not
            value.isalpha()
        ):
            raise Invalid(msg or (
                'Invalid input <{0}>; expected an integer'.format(value))
            )
        else:
            return value
    return fn
1058883
private function check($value) {

		if(true === is_string($value) || is_numeric($value)) {

			if(true === $this -> strict) {
				return true === is_int($value);
			}

			return !in_array(preg_match('/^-?[0-9]+$/', $value), [false, 0]);
		}

		return false;
	}
158861
public static boolean isIntValue(final String value) {
        try {
            Integer.parseInt(value);
            return true;
        } catch (final NumberFormatException ex) {
            return false;
        }
    }
16096
private boolean isNumeric(String value) {

        if (!CmsStringUtil.isEmpty(value)) {
            NumberFormat formatter = NumberFormat.getInstance();
            ParsePosition pos = new ParsePosition(0);
            formatter.parse(value, pos);
            return value.length() == pos.getIndex();
        } else {
            return false;
        }
    }
503214
def isInt(num):
    
    try:
        len(num) # FIXME fails for Numeric but Numeric is obsolete
    except:
        try:
            return (num - math.floor(num) == 0) == True
        except: return False
    else: return False
382994
private static int isNumeric(String s) {
        final char[] chars = s.toCharArray();
        int num = 0;

        // note: this method does not account for leading zeroes as could occur in build
        // meta data parts. Leading zeroes are thus simply ignored when parsing the
        // number.
        for (int i = 0; i < chars.length; ++i) {
            final char c = chars[i];
            if (c >= '0' && c <= '9') {
                num = num * DECIMAL + Character.digit(c, DECIMAL);
            } else {
                return -1;
            }
        }
        return num;
    }
704835
function isInteger(value) {
        // Validate value is a number
        if (typeof (value) !== "number" || isNaN(parseInt(value, 10))) {
            return false;
        }

        // Validate number is an integer
        if (Math.floor(value) !== value) {
            return false;
        }

        // Validate number is finite
        if (!isFinite(value)) {
            return false;
        }

        return true;
    }