fail_recursive_mixing.carbon 529 B

12345678910111213141516171819202122
  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. package ExplorerTest api;
  7. __mixin M1 {
  8. fn F1[self: Self](x: Self) -> Self{
  9. return x;
  10. }
  11. // CHECK:STDERR: COMPILATION ERROR: explorer/testdata/mixin/fail_recursive_mixing.carbon:[[@LINE+1]]: incomplete mixin `M1` used in mix declaration
  12. __mix M1;
  13. }
  14. class C {
  15. __mix M1;
  16. }
  17. fn Main() -> i32 {
  18. return 0;
  19. }