SingleUnitIdentifiers.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. /*
  2. * Copyright (c) 2022, the SerenityOS developers.
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <AK/Array.h>
  8. #include <AK/StringView.h>
  9. namespace JS::Intl {
  10. // Table 2: Single units sanctioned for use in ECMAScript, https://tc39.es/ecma402/#table-sanctioned-single-unit-identifiers
  11. constexpr auto sanctioned_single_unit_identifiers()
  12. {
  13. return AK::Array {
  14. "acre"sv,
  15. "bit"sv,
  16. "byte"sv,
  17. "celsius"sv,
  18. "centimeter"sv,
  19. "day"sv,
  20. "degree"sv,
  21. "fahrenheit"sv,
  22. "fluid-ounce"sv,
  23. "foot"sv,
  24. "gallon"sv,
  25. "gigabit"sv,
  26. "gigabyte"sv,
  27. "gram"sv,
  28. "hectare"sv,
  29. "hour"sv,
  30. "inch"sv,
  31. "kilobit"sv,
  32. "kilobyte"sv,
  33. "kilogram"sv,
  34. "kilometer"sv,
  35. "liter"sv,
  36. "megabit"sv,
  37. "megabyte"sv,
  38. "meter"sv,
  39. "microsecond"sv,
  40. "mile"sv,
  41. "mile-scandinavian"sv,
  42. "milliliter"sv,
  43. "millimeter"sv,
  44. "millisecond"sv,
  45. "minute"sv,
  46. "month"sv,
  47. "nanosecond"sv,
  48. "ounce"sv,
  49. "percent"sv,
  50. "petabyte"sv,
  51. "pound"sv,
  52. "second"sv,
  53. "stone"sv,
  54. "terabit"sv,
  55. "terabyte"sv,
  56. "week"sv,
  57. "yard"sv,
  58. "year"sv,
  59. };
  60. }
  61. }