blob: 2c3b26c8b1a5189df3d8a45e194dece5f119c97d [file] [log] [blame]
// Copyright (c) 2011, 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.
// @dart = 2.9
/// @assertion Strings support escape sequences for special characters. The
/// escapes are:
/// . . .
/// • \u{HEX_DIGIT_SEQUENCE} is the unicode scalar value represented by the
/// HEX_DIGIT_SEQUENCE. It is a compile-time error when the value of the
/// HEX_DIGIT_SEQUENCE is not a valid unicode scalar value.
/// HEX_DIGIT_SEQUENCE:
/// HEX_DIGIT HEX_DIGIT? HEX_DIGIT? HEX_DIGIT? HEX_DIGIT? HEX_DIGIT?
/// ;
/// @description Checks that it is a compile-time error when the value
/// of the HEX_DIGIT_SEQUENCE contains other symbols than HEX_DIGIT.
/// @author msyabro
/// @reviewer rodionov
main() {
try {
'\u{ffg}';
// ^
// [analyzer] unspecified
// [cfe] unspecified
} catch (e) {}
}