Purity analysis for functional, prototype-based higher-order languages.