function y = upper(x)
%MATLAB Code Generation Library Function

%   Limitations:
%   1. Only supports 'char' inputs, cell array not supported.
%   2. Input values must be in the range 0-127.

%   Copyright 1984-2018 The MathWorks, Inc.
%#codegen

eml_invariant(nargin > 0, ...
    'MATLAB:minrhs');
coder.internal.prefer_const(x);
eml_invariant(~iscell(x), 'Coder:toolbox:CellArraysNotSupported', mfilename);
if ischar(x)
    y = eml_string_transform(x, 'upper');
else
    eml_invariant(coder.internal.isAmbiguousTypes, ...
        'Coder:toolbox:unsupportedClass', 'upper', class(x));
    y = coder.ignoreConst(x);
end
