nested templates support