fix a bug in ClassNew[]