Implement Stat, and fix a bug about truncation