>>>>> "Jie" == Jie Liu <lj8175@gmail.com> writes: Jie> + if(str == NULL) Jie> + throw new NullPointerException(); Jie> + Jie> int length = str->length(); Why doesn't 'str->length()' throw the NPE? Tom