fail_incomplete.carbon 1.3 KB

12345678910111213141516171819202122232425262728
  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. // AUTOUPDATE
  6. // CHECK:STDERR: fail_incomplete.carbon:[[@LINE+4]]:12: ERROR: `constraint` introducer should be followed by a name.
  7. // CHECK:STDERR: constraint "Foo"
  8. // CHECK:STDERR: ^~~~~
  9. // CHECK:STDERR:
  10. constraint "Foo"
  11. // CHECK:STDERR: fail_incomplete.carbon:[[@LINE+3]]:1: ERROR: `constraint` introducer should be followed by a name.
  12. // CHECK:STDERR: constraint
  13. // CHECK:STDERR: ^~~~~~~~~~
  14. constraint
  15. // CHECK:STDOUT: - filename: fail_incomplete.carbon
  16. // CHECK:STDOUT: parse_tree: [
  17. // CHECK:STDOUT: {kind: 'FileStart', text: ''},
  18. // CHECK:STDOUT: {kind: 'NamedConstraintIntroducer', text: 'constraint'},
  19. // CHECK:STDOUT: {kind: 'InvalidParse', text: '"Foo"', has_error: yes},
  20. // CHECK:STDOUT: {kind: 'NamedConstraintDecl', text: '"Foo"', has_error: yes, subtree_size: 3},
  21. // CHECK:STDOUT: {kind: 'NamedConstraintIntroducer', text: 'constraint'},
  22. // CHECK:STDOUT: {kind: 'InvalidParse', text: '', has_error: yes},
  23. // CHECK:STDOUT: {kind: 'NamedConstraintDecl', text: 'constraint', has_error: yes, subtree_size: 3},
  24. // CHECK:STDOUT: {kind: 'FileEnd', text: ''},
  25. // CHECK:STDOUT: ]