User`s guide
Programming Fundamentals
16-19
Now modify the function slightly so that the input variable is named java and run it on
a version of MATLAB prior to Version 7.8:
function y = dotindextwice_B(java)
y = java.lang.String;
Now when you run the function without arguments, MATLAB misinterprets the word
java, treating it as if it were the stem of a Java class name:
x = dotindextwice_B; % Deliberately called with no arguments
Prior to Version 7.8, this function did not throw an error. In fact, it returned an instance
of the java.lang.String class:
class(x)
ans =
java.lang.String
This violates the rule that variables in functions are supposed to hide all other uses
of the name. Beginning in Version 7.8, calling function dotindextwice_B without
arguments results in an error, just as calling dotindextwice_A does.
MATLAB Upgrades Support for HDF5 to Version 1.8.1
The R2009a release of MATLAB uses version 1.8.1 of the HDF5 library. The HDF Group
has deprecated two of the HDF5 library functions, H5Pget_cache and H5Pset_cache.
Their M-file counterparts, H5P.get_config and H5P.set_config, may not work
as they did in prior releases of MATLAB. To replace these deprecated functions
in your code, consider these four new HDF5 functions: H5P.get_mdc_config,
H5P.set_mdc_config, H5F.get_mdc_config, and H5F.set_mdc_config.
Compatibility Considerations
If your code uses H5P.get_cache or H5P.get_cache, your program will produce a
warning message.
Indirect Calls to Superclass Constructors Now Errors
You can no longer call an indirect superclass constructor from a subclass constructor. For
example, suppose class B is derived from class A, and class C is derived from class B. The