fail_errors_sorted.carbon 1.0 KB

123456789101112131415161718192021222324
  1. // Part of the Carbon Language project, under the Apache License v2.0 with LLVM
  2. // Exceptions. See /LICENSE for license information.
  3. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. //
  5. // ARGS: compile --phase=lex %s
  6. //
  7. // AUTOUPDATE
  8. // TIP: To test this file alone, run:
  9. // TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/driver/testdata/fail_errors_sorted.carbon
  10. // TIP: To dump output, run:
  11. // TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/driver/testdata/fail_errors_sorted.carbon
  12. // CHECK:STDERR: fail_errors_sorted.carbon:[[@LINE+4]]:24: error: opening symbol without a corresponding closing symbol
  13. // CHECK:STDERR: fn run(String program) {
  14. // CHECK:STDERR: ^
  15. // CHECK:STDERR:
  16. fn run(String program) {
  17. return True;
  18. // CHECK:STDERR: fail_errors_sorted.carbon:[[@LINE+4]]:10: error: invalid digit 'a' in decimal numeric literal
  19. // CHECK:STDERR: var x = 3a;
  20. // CHECK:STDERR: ^
  21. // CHECK:STDERR:
  22. var x = 3a;