3d3543e880e8d01a5f3de62c8e5137fb6cddf741 425 B

123456789101112131415161718
  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:STDOUT: result: 4
  7. package ExplorerTest;
  8. alias TypeAlias = i32;
  9. fn Main() -> TypeAlias {
  10. var n: TypeAlias = 1;
  11. var m: i32 = n;
  12. var p: i32* = &n;
  13. var q: TypeAlias* = &m;
  14. return *p + *q + m + n;
  15. }