Checks if the given expression (that really ought to refer to a type
expression) represents a primitive type.
500693
public static boolean isPrimitive(JCExpression ref) {
		String typeName = ref.toString();
		return PRIMITIVE_TYPE_NAME_PATTERN.matcher(typeName).matches();
	}
582646
function isPrimitiveType (obj) {
  return ( typeof obj === 'boolean' ||
       typeof obj === 'number' ||
       typeof obj === 'string' ||
       obj === null ||
       util.isDate(obj) ||
       util.isArray(obj));
}
596376
private boolean validTemplateTypeOfExpression(Node expr) {
    // The expression must have three children. The templateTypeOf keyword, a
    // templatized type and an index
    if (!checkParameterCount(expr, Keywords.TEMPLATETYPEOF)) {
      return false;
    }
    // The parameter must be a valid type expression
    if (!validTypeTransformationExpression(getCallArgument(expr, 0))) {
      warnInvalidInside(Keywords.TEMPLATETYPEOF.name, expr);
      return false;
    }
    if (!getCallArgument(expr, 1).isNumber()) {
      warnInvalid("index", expr);
      warnInvalidInside(Keywords.TEMPLATETYPEOF.name, expr);
      return false;
    }
    double index = getCallArgument(expr, 1).getDouble();
    if (index < 0 || index % 1 != 0) {
      warnInvalid("index", expr);
      warnInvalidInside(Keywords.TEMPLATETYPEOF.name, expr);
      return false;
    }
    return true;
  }
681729
public static boolean isPrimitiveLike(Type t)
  {
    if(isNumber(t)) {
      return true;
    }
    if(isBoolean(t)) {
      return true;
    }
    if(isEnum(t)) {
      return true;
    }
    if(isCharacter(t)) {
      return true;
    }
    if(isDate(t)) {
      return true;
    }
    if(t == String.class) {
      return true;
    }
    return false;
  }
412695
Type checkSpeculative(JCExpression expr, ResultInfo resultInfo) {
        return checkSpeculative(expr, expr.type, resultInfo);
    }
852274
public static boolean isPrimitive(Class<?> javaType)
   {
      return javaType.isPrimitive() || (javaType.isArray() && isPrimitive(javaType.getComponentType()));
   }
368896
def _is_valid_type(self, inpt):
        """"""
        from dlkit.abstract_osid.type.primitives import Type as abc_type
        if isinstance(inpt, abc_type):
            return True
        else:
            return False
307796
function isPrimitive( value ) {
	var type = typeof value;
	return type === 'string' || type === 'number' || type === 'boolean' || value === null || value === undefined;
}
1287013
@Pure
	protected boolean isTypeReference(JvmTypeReference typeReference) {
		return (typeReference != null && !typeReference.eIsProxy()
			&& typeReference.getType() != null && !typeReference.getType().eIsProxy());
	}
666986
def is_primitive(self):
        """"""
        if is_py2:
            return isinstance(
                self.val, 
                (
                    types.NoneType,
                    types.BooleanType,
                    types.IntType,
                    types.LongType,
                    types.FloatType
                )
            )

        else:
            return isinstance(
                self.val,
                (
                    type(None),
                    bool,
                    int,
                    float
                )
            )
15297
def is_primitive(self, t: URIRef) -> bool:
        
        return FHIR.Primitive in self._o.objects(t, RDFS.subClassOf)
1360297
public static boolean isPrimitive(Object value) {

        if (value == null) {
            return true;

        } else if (value.getClass().isPrimitive() == true) {
            return true;

        } else if (Integer.class.isInstance(value)) {
            return true;

        } else if (Long.class.isInstance(value)) {
            return true;

        } else if (Double.class.isInstance(value)) {
            return true;

        } else if (Float.class.isInstance(value)) {
            return true;

        } else if (Short.class.isInstance(value)) {
            return true;

        } else if (Byte.class.isInstance(value)) {
            return true;

        } else if (Character.class.isInstance(value)) {
            return true;

        } else if (Boolean.class.isInstance(value)) {
            return true;

        } else if (BigDecimal.class.isInstance(value)) {
            return true;

        } else if (BigInteger.class.isInstance(value)) {
            return true;
        }

        return false;
    }
1124772
public static boolean isSpreadSafe(Expression expression) {
        if (expression instanceof MethodCallExpression) {
            return ((MethodCallExpression) expression).isSpreadSafe();
        }
        if (expression instanceof PropertyExpression) {
            return ((PropertyExpression) expression).isSpreadSafe();
        }
        return false;
    }
1028025
protected boolean isIntentionalEarlyExit(/* @Nullable */ XExpression expression) {
		ExtendedEarlyExitComputer earlyExitComputer = getReferenceOwner().getServices().getEarlyExitComputer();
		return earlyExitComputer.isIntentionalEarlyExit(expression);
	}
13295
function (expression, types) {
        var args = types.split(" | "),
            i, len, found = false;

        for (i=0, len=args.length; i < len && !found && expression.hasNext(); i++) {
            found = this.isType(expression, args[i]);
        }

        return found;
    }
823857
public static boolean isTypePrimitive(TypeName value) {
		return isTypeIncludedIn(value, Byte.TYPE, Character.TYPE, Boolean.TYPE, Short.TYPE, Integer.TYPE, Long.TYPE,
				Float.TYPE, Double.TYPE);
	}
361268
function isPrimitive(type) {
	return (type === String || type === Number || type === Boolean || type === Symbol);
}