a757d2af41
Bug: https://github.com/dart-lang/sdk/issues/60438 Change-Id: I908d4e4a9143142281d8198870f40eba6cf6f67f Tested: trybots Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/427500 Reviewed-by: Ivan Inozemtsev <iinozemtsev@google.com> Commit-Queue: Paul Berry <paulberry@google.com> Reviewed-by: Morgan :) <davidmorgan@google.com> Reviewed-by: Daco Harkes <dacoharkes@google.com> Reviewed-by: Samuel Rawlins <srawlins@google.com>
62 lines
1.9 KiB
C++
62 lines
1.9 KiB
C++
// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
// NOTE: THIS FILE IS GENERATED. DO NOT EDIT.
|
|
//
|
|
// Instead modify 'tools/experimental_features.yaml' and run
|
|
// 'dart tools/generate_experimental_flags.dart' to update.
|
|
|
|
#include "vm/experimental_features.h"
|
|
|
|
#include <cstring>
|
|
#include "platform/assert.h"
|
|
#include "vm/globals.h"
|
|
|
|
namespace dart {
|
|
|
|
bool GetExperimentalFeatureDefault(ExperimentalFeature feature) {
|
|
constexpr bool kFeatureValues[] = {
|
|
true, true, true, true, true, true, true, true, true,
|
|
true, true, true, true, true, true, true, true, true,
|
|
true, true, true, true, true, true, true, true, true,
|
|
};
|
|
ASSERT(static_cast<size_t>(feature) < ARRAY_SIZE(kFeatureValues));
|
|
return kFeatureValues[static_cast<int>(feature)];
|
|
}
|
|
|
|
const char* GetExperimentalFeatureName(ExperimentalFeature feature) {
|
|
constexpr const char* kFeatureNames[] = {
|
|
"sound-flow-analysis",
|
|
"null-aware-elements",
|
|
"inference-using-bounds",
|
|
"wildcard-variables",
|
|
"digit-separators",
|
|
"inference-update-3",
|
|
"inline-class",
|
|
"inference-update-2",
|
|
"sealed-class",
|
|
"class-modifiers",
|
|
"records",
|
|
"patterns",
|
|
"unnamed-libraries",
|
|
"inference-update-1",
|
|
"enhanced-enums",
|
|
"named-arguments-anywhere",
|
|
"super-parameters",
|
|
"constructor-tearoffs",
|
|
"generic-metadata",
|
|
"triple-shift",
|
|
"nonfunction-type-aliases",
|
|
"non-nullable",
|
|
"extension-methods",
|
|
"constant-update-2018",
|
|
"control-flow-collections",
|
|
"set-literals",
|
|
"spread-collections",
|
|
};
|
|
ASSERT(static_cast<size_t>(feature) < ARRAY_SIZE(kFeatureNames));
|
|
return kFeatureNames[static_cast<int>(feature)];
|
|
}
|
|
|
|
} // namespace dart
|