mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 15:51:07 +01:00
Add an interface for initialization of vars without an explicit initializer (#6934)
When a `var` is not explicitly given an initializer, initialize it in one of two ways: * If its type implements the new interface `Core.Default`, call `Core.Default.Op` to initialize it. * Otherwise, if its type implements `UnformedInit`, leave it in an unformed state. For now, this is always an uninitialized state, but that will change in the future. * If neither of those apply, the `var` declaration is ill-formed. This is a step towards implementing leads decision #6739 and proposals #257 and #5913. Assisted-by: Gemini 3.1 Pro via Antigravity --------- Co-authored-by: Geoff Romer <gromer@google.com>
This commit is contained in:
co-authored by
Geoff Romer
parent
fd2d210c63
commit
ce50f181f1
+5
-5
@@ -224,14 +224,14 @@ fn ConvertNullptrConstant() -> Core.Optional(i32*) {
|
||||
// CHECK:STDOUT: !42 = !DILocation(line: 32, column: 3, scope: !40)
|
||||
// CHECK:STDOUT: !43 = distinct !DISubprogram(name: "ConvertNullptrConstant", linkageName: "_CConvertNullptrConstant.Main", scope: null, file: !6, line: 35, type: !25, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 36, column: 3, scope: !43)
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.NullptrT.CppCompat.Core:ImplicitAs.83dbfcd16e56a769.Core.b88d1103f417c6d4", scope: null, file: !46, line: 46, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.NullptrT.CppCompat.Core:ImplicitAs.83dbfcd16e56a769.Core.b88d1103f417c6d4", scope: null, file: !46, line: 51, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
|
||||
// CHECK:STDOUT: !46 = !DIFile(filename: "{{.*}}/prelude/types/cpp/nullptr.carbon", directory: "")
|
||||
// CHECK:STDOUT: !47 = !DISubroutineType(types: !48)
|
||||
// CHECK:STDOUT: !48 = !{!27, !27}
|
||||
// CHECK:STDOUT: !49 = !{!50}
|
||||
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !45, type: !27)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 47, column: 14, scope: !45)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 47, column: 7, scope: !45)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.95809cda2a4fffc7", scope: null, file: !54, line: 26, type: !25, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 52, column: 14, scope: !45)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 52, column: 7, scope: !45)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "None", linkageName: "_CNone.Optional.Core.95809cda2a4fffc7", scope: null, file: !54, line: 27, type: !25, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !54 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 27, column: 5, scope: !53)
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 28, column: 5, scope: !53)
|
||||
|
||||
@@ -114,6 +114,7 @@ fn PassValueExpr(y: Cpp.Y) {
|
||||
// CHECK:STDOUT: target triple = "x86_64-unknown-linux-gnu"
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: @_Cc.Main = global i16 0
|
||||
// CHECK:STDOUT: @llvm.global_ctors = appending global [1 x { i32, ptr, ptr }] [{ i32, ptr, ptr } { i32 0, ptr @_C__global_init.Main, ptr null }]
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: alwaysinline mustprogress uwtable
|
||||
// CHECK:STDOUT: define dso_local void @_Z11pass_signedasil.carbon_thunk(ptr noundef %0, ptr noundef %1, i32 noundef %2, i64 noundef %3) #0 {
|
||||
@@ -224,6 +225,13 @@ fn PassValueExpr(y: Cpp.Y) {
|
||||
// CHECK:STDOUT: ; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
|
||||
// CHECK:STDOUT: declare void @llvm.lifetime.start.p0(ptr captures(none)) #3
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; Function Attrs: nounwind
|
||||
// CHECK:STDOUT: define internal void @_C__global_init.Main() #2 !dbg !48 {
|
||||
// CHECK:STDOUT: entry:
|
||||
// CHECK:STDOUT: store i16 poison, ptr @_Cc.Main, align 2, !dbg !49
|
||||
// CHECK:STDOUT: ret void, !dbg !50
|
||||
// CHECK:STDOUT: }
|
||||
// CHECK:STDOUT:
|
||||
// CHECK:STDOUT: ; uselistorder directives
|
||||
// CHECK:STDOUT: uselistorder ptr @llvm.lifetime.start.p0, { 7, 6, 5, 4, 3, 2, 1, 0 }
|
||||
// CHECK:STDOUT:
|
||||
@@ -284,6 +292,9 @@ fn PassValueExpr(y: Cpp.Y) {
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 19, column: 3, scope: !31)
|
||||
// CHECK:STDOUT: !46 = !DILocation(line: 20, column: 3, scope: !31)
|
||||
// CHECK:STDOUT: !47 = !DILocation(line: 16, column: 1, scope: !31)
|
||||
// CHECK:STDOUT: !48 = distinct !DISubprogram(name: "__global_init", linkageName: "_C__global_init.Main", scope: null, file: !6, type: !22, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !49 = !DILocation(line: 14, column: 1, scope: !48)
|
||||
// CHECK:STDOUT: !50 = !DILocation(line: 0, scope: !48)
|
||||
// CHECK:STDOUT: ; ModuleID = 'import_struct.carbon'
|
||||
// CHECK:STDOUT: source_filename = "import_struct.carbon"
|
||||
// CHECK:STDOUT: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
|
||||
|
||||
+15
-14
@@ -296,6 +296,7 @@ fn ReturnPtrWithThunk() -> Core.Optional(Cpp.C*) {
|
||||
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655"(ptr %self) #2 !dbg !63 {
|
||||
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !66
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !66
|
||||
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !66
|
||||
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !67
|
||||
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !68
|
||||
// CHECK:STDOUT: ret ptr %2, !dbg !69
|
||||
@@ -359,28 +360,28 @@ fn ReturnPtrWithThunk() -> Core.Optional(Cpp.C*) {
|
||||
// CHECK:STDOUT: !42 = distinct !DISubprogram(name: "ReturnPtrWithThunk", linkageName: "_CReturnPtrWithThunk.Main", scope: null, file: !6, line: 38, type: !28, spFlags: DISPFlagDefinition, unit: !5)
|
||||
// CHECK:STDOUT: !43 = !DILocation(line: 39, column: 10, scope: !42)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 39, column: 3, scope: !42)
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.e76fd6d2be138e4a", scope: null, file: !46, line: 93, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
|
||||
// CHECK:STDOUT: !45 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.e76fd6d2be138e4a", scope: null, file: !46, line: 96, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !49)
|
||||
// CHECK:STDOUT: !46 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
|
||||
// CHECK:STDOUT: !47 = !DISubroutineType(types: !48)
|
||||
// CHECK:STDOUT: !48 = !{!17, !17}
|
||||
// CHECK:STDOUT: !49 = !{!50}
|
||||
// CHECK:STDOUT: !50 = !DILocalVariable(arg: 1, scope: !45, type: !17)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 94, column: 12, scope: !45)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 94, column: 5, scope: !45)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.90961d7b1ce4f089:OptionalAs.0e326e799dad0c64.Core.8f431b36581f9e63", scope: null, file: !46, line: 68, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !54)
|
||||
// CHECK:STDOUT: !51 = !DILocation(line: 97, column: 12, scope: !45)
|
||||
// CHECK:STDOUT: !52 = !DILocation(line: 97, column: 5, scope: !45)
|
||||
// CHECK:STDOUT: !53 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.90961d7b1ce4f089:OptionalAs.0e326e799dad0c64.Core.8f431b36581f9e63", scope: null, file: !46, line: 71, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !54)
|
||||
// CHECK:STDOUT: !54 = !{!55}
|
||||
// CHECK:STDOUT: !55 = !DILocalVariable(arg: 1, scope: !53, type: !17)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 69, column: 12, scope: !53)
|
||||
// CHECK:STDOUT: !57 = !DILocation(line: 69, column: 5, scope: !53)
|
||||
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.8f431b36581f9e63", scope: null, file: !46, line: 29, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !59)
|
||||
// CHECK:STDOUT: !56 = !DILocation(line: 72, column: 12, scope: !53)
|
||||
// CHECK:STDOUT: !57 = !DILocation(line: 72, column: 5, scope: !53)
|
||||
// CHECK:STDOUT: !58 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.8f431b36581f9e63", scope: null, file: !46, line: 30, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !59)
|
||||
// CHECK:STDOUT: !59 = !{!60}
|
||||
// CHECK:STDOUT: !60 = !DILocalVariable(arg: 1, scope: !58, type: !17)
|
||||
// CHECK:STDOUT: !61 = !DILocation(line: 30, column: 12, scope: !58)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 30, column: 5, scope: !58)
|
||||
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655", scope: null, file: !46, line: 138, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !64)
|
||||
// CHECK:STDOUT: !61 = !DILocation(line: 31, column: 12, scope: !58)
|
||||
// CHECK:STDOUT: !62 = !DILocation(line: 31, column: 5, scope: !58)
|
||||
// CHECK:STDOUT: !63 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.f53db17714b9f655", scope: null, file: !46, line: 150, type: !47, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !64)
|
||||
// CHECK:STDOUT: !64 = !{!65}
|
||||
// CHECK:STDOUT: !65 = !DILocalVariable(arg: 1, scope: !63, type: !17)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 139, column: 14, scope: !63)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 140, column: 5, scope: !63)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 139, column: 18, scope: !63)
|
||||
// CHECK:STDOUT: !69 = !DILocation(line: 141, column: 5, scope: !63)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 151, column: 14, scope: !63)
|
||||
// CHECK:STDOUT: !67 = !DILocation(line: 153, column: 5, scope: !63)
|
||||
// CHECK:STDOUT: !68 = !DILocation(line: 151, column: 18, scope: !63)
|
||||
// CHECK:STDOUT: !69 = !DILocation(line: 154, column: 5, scope: !63)
|
||||
|
||||
@@ -198,6 +198,7 @@ fn GetRefs() {
|
||||
// CHECK:STDOUT: call void @_Z9TakeCRRefO1C.carbon_thunk(ptr %.loc19_18.2.temp), !dbg !25
|
||||
// CHECK:STDOUT: call void @_Z13TakeConstCRefRK1C.carbon_thunk(ptr %c.var), !dbg !26
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %n.var), !dbg !21
|
||||
// CHECK:STDOUT: store i32 poison, ptr %n.var, align 4, !dbg !21
|
||||
// CHECK:STDOUT: call void @_Z10TakeIntRefRi(ptr %n.var), !dbg !27
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc24_22.3.temp), !dbg !22
|
||||
// CHECK:STDOUT: store i32 42, ptr %.loc24_22.3.temp, align 4, !dbg !22
|
||||
@@ -365,6 +366,7 @@ fn GetRefs() {
|
||||
// CHECK:STDOUT: call void @_Z9TakeCRRefRK1C10ForceThunk.carbon_thunk1(ptr %.loc20_18.2.temp), !dbg !27
|
||||
// CHECK:STDOUT: call void @_Z13TakeConstCRefRK1C10ForceThunk.carbon_thunk1(ptr %c.var), !dbg !28
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %n.var), !dbg !23
|
||||
// CHECK:STDOUT: store i32 poison, ptr %n.var, align 4, !dbg !23
|
||||
// CHECK:STDOUT: call void @_Z10TakeIntRefRi10ForceThunk.carbon_thunk1(ptr %n.var), !dbg !29
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %.loc25_22.3.temp), !dbg !24
|
||||
// CHECK:STDOUT: store i32 42, ptr %.loc25_22.3.temp, align 4, !dbg !24
|
||||
|
||||
+38
-36
@@ -182,6 +182,7 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
|
||||
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299"(ptr %self) #0 !dbg !88 {
|
||||
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !91
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !91
|
||||
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !91
|
||||
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !92
|
||||
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !93
|
||||
// CHECK:STDOUT: ret ptr %2, !dbg !94
|
||||
@@ -191,6 +192,7 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
|
||||
// CHECK:STDOUT: define linkonce_odr ptr @"_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f"(ptr %self) #0 !dbg !95 {
|
||||
// CHECK:STDOUT: %1 = alloca ptr, align 8, !dbg !98
|
||||
// CHECK:STDOUT: call void @llvm.lifetime.start.p0(ptr %1), !dbg !98
|
||||
// CHECK:STDOUT: store ptr poison, ptr %1, align 8, !dbg !98
|
||||
// CHECK:STDOUT: store ptr %self, ptr %1, align 8, !dbg !99
|
||||
// CHECK:STDOUT: %2 = load ptr, ptr %1, align 8, !dbg !100
|
||||
// CHECK:STDOUT: ret ptr %2, !dbg !101
|
||||
@@ -248,70 +250,70 @@ fn ConvertFromConstVoidPtr(p: const Cpp.void*) -> const i32* {
|
||||
// CHECK:STDOUT: !35 = !DILocation(line: 19, column: 27, scope: !32)
|
||||
// CHECK:STDOUT: !36 = !DILocation(line: 19, column: 3, scope: !32)
|
||||
// CHECK:STDOUT: !37 = !DILocation(line: 18, column: 1, scope: !32)
|
||||
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.66983884551336cb", scope: null, file: !39, line: 93, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !38 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.66983884551336cb", scope: null, file: !39, line: 96, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !42)
|
||||
// CHECK:STDOUT: !39 = !DIFile(filename: "{{.*}}/prelude/types/optional.carbon", directory: "")
|
||||
// CHECK:STDOUT: !40 = !DISubroutineType(types: !41)
|
||||
// CHECK:STDOUT: !41 = !{!14, !14}
|
||||
// CHECK:STDOUT: !42 = !{!43}
|
||||
// CHECK:STDOUT: !43 = !DILocalVariable(arg: 1, scope: !38, type: !14)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 94, column: 12, scope: !38)
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 94, column: 5, scope: !38)
|
||||
// CHECK:STDOUT: !46 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.295aa3526801a9d4", scope: null, file: !39, line: 93, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !47)
|
||||
// CHECK:STDOUT: !44 = !DILocation(line: 97, column: 12, scope: !38)
|
||||
// CHECK:STDOUT: !45 = !DILocation(line: 97, column: 5, scope: !38)
|
||||
// CHECK:STDOUT: !46 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.295aa3526801a9d4", scope: null, file: !39, line: 96, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !47)
|
||||
// CHECK:STDOUT: !47 = !{!48}
|
||||
// CHECK:STDOUT: !48 = !DILocalVariable(arg: 1, scope: !46, type: !14)
|
||||
// CHECK:STDOUT: !49 = !DILocation(line: 94, column: 12, scope: !46)
|
||||
// CHECK:STDOUT: !50 = !DILocation(line: 94, column: 5, scope: !46)
|
||||
// CHECK:STDOUT: !51 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.e995c7ea1c3d1cc3", scope: null, file: !39, line: 93, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !52)
|
||||
// CHECK:STDOUT: !49 = !DILocation(line: 97, column: 12, scope: !46)
|
||||
// CHECK:STDOUT: !50 = !DILocation(line: 97, column: 5, scope: !46)
|
||||
// CHECK:STDOUT: !51 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.e5cf8fcbb4feaae2:ImplicitAs.0f95c9e18c91e00a.Core.e995c7ea1c3d1cc3", scope: null, file: !39, line: 96, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !52)
|
||||
// CHECK:STDOUT: !52 = !{!53}
|
||||
// CHECK:STDOUT: !53 = !DILocalVariable(arg: 1, scope: !51, type: !14)
|
||||
// CHECK:STDOUT: !54 = !DILocation(line: 94, column: 12, scope: !51)
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 94, column: 5, scope: !51)
|
||||
// CHECK:STDOUT: !56 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.90961d7b1ce4f089:OptionalAs.0e326e799dad0c64.Core.7bed839a0b822504", scope: null, file: !39, line: 68, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !57)
|
||||
// CHECK:STDOUT: !54 = !DILocation(line: 97, column: 12, scope: !51)
|
||||
// CHECK:STDOUT: !55 = !DILocation(line: 97, column: 5, scope: !51)
|
||||
// CHECK:STDOUT: !56 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.90961d7b1ce4f089:OptionalAs.0e326e799dad0c64.Core.7bed839a0b822504", scope: null, file: !39, line: 71, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !57)
|
||||
// CHECK:STDOUT: !57 = !{!58}
|
||||
// CHECK:STDOUT: !58 = !DILocalVariable(arg: 1, scope: !56, type: !14)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 69, column: 12, scope: !56)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 69, column: 5, scope: !56)
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.3667eb502d1ddfa9:OptionalAs.c7a50af9bdd61b43.Core.57bd8d0c2213b1aa", scope: null, file: !39, line: 75, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !62)
|
||||
// CHECK:STDOUT: !59 = !DILocation(line: 72, column: 12, scope: !56)
|
||||
// CHECK:STDOUT: !60 = !DILocation(line: 72, column: 5, scope: !56)
|
||||
// CHECK:STDOUT: !61 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.3667eb502d1ddfa9:OptionalAs.c7a50af9bdd61b43.Core.57bd8d0c2213b1aa", scope: null, file: !39, line: 78, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !62)
|
||||
// CHECK:STDOUT: !62 = !{!63}
|
||||
// CHECK:STDOUT: !63 = !DILocalVariable(arg: 1, scope: !61, type: !14)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 76, column: 29, scope: !61)
|
||||
// CHECK:STDOUT: !65 = !DILocation(line: 76, column: 12, scope: !61)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 76, column: 5, scope: !61)
|
||||
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.3667eb502d1ddfa9:OptionalAs.c7a50af9bdd61b43.Core.02dd0be934e1c38a", scope: null, file: !39, line: 75, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !68)
|
||||
// CHECK:STDOUT: !64 = !DILocation(line: 79, column: 29, scope: !61)
|
||||
// CHECK:STDOUT: !65 = !DILocation(line: 79, column: 12, scope: !61)
|
||||
// CHECK:STDOUT: !66 = !DILocation(line: 79, column: 5, scope: !61)
|
||||
// CHECK:STDOUT: !67 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert.3667eb502d1ddfa9:OptionalAs.c7a50af9bdd61b43.Core.02dd0be934e1c38a", scope: null, file: !39, line: 78, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !68)
|
||||
// CHECK:STDOUT: !68 = !{!69}
|
||||
// CHECK:STDOUT: !69 = !DILocalVariable(arg: 1, scope: !67, type: !14)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 76, column: 29, scope: !67)
|
||||
// CHECK:STDOUT: !71 = !DILocation(line: 76, column: 12, scope: !67)
|
||||
// CHECK:STDOUT: !72 = !DILocation(line: 76, column: 5, scope: !67)
|
||||
// CHECK:STDOUT: !73 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.7bed839a0b822504", scope: null, file: !39, line: 29, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !74)
|
||||
// CHECK:STDOUT: !70 = !DILocation(line: 79, column: 29, scope: !67)
|
||||
// CHECK:STDOUT: !71 = !DILocation(line: 79, column: 12, scope: !67)
|
||||
// CHECK:STDOUT: !72 = !DILocation(line: 79, column: 5, scope: !67)
|
||||
// CHECK:STDOUT: !73 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.7bed839a0b822504", scope: null, file: !39, line: 30, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !74)
|
||||
// CHECK:STDOUT: !74 = !{!75}
|
||||
// CHECK:STDOUT: !75 = !DILocalVariable(arg: 1, scope: !73, type: !14)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 30, column: 12, scope: !73)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 30, column: 5, scope: !73)
|
||||
// CHECK:STDOUT: !76 = !DILocation(line: 31, column: 12, scope: !73)
|
||||
// CHECK:STDOUT: !77 = !DILocation(line: 31, column: 5, scope: !73)
|
||||
// CHECK:STDOUT: !78 = distinct !DISubprogram(name: "Convert", linkageName: "_CConvert:thunk.e8f8f92d3d08d149:ImplicitAs.ffd58aeb29886b72.Core.b88d1103f417c6d4", scope: null, file: !79, line: 40, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !80)
|
||||
// CHECK:STDOUT: !79 = !DIFile(filename: "{{.*}}/prelude/types/cpp/void.carbon", directory: "")
|
||||
// CHECK:STDOUT: !80 = !{!81}
|
||||
// CHECK:STDOUT: !81 = !DILocalVariable(arg: 1, scope: !78, type: !14)
|
||||
// CHECK:STDOUT: !82 = !DILocation(line: 40, column: 3, scope: !78)
|
||||
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.9544e72a46e24ed6", scope: null, file: !39, line: 29, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
|
||||
// CHECK:STDOUT: !83 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.Optional.Core.9544e72a46e24ed6", scope: null, file: !39, line: 30, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !84)
|
||||
// CHECK:STDOUT: !84 = !{!85}
|
||||
// CHECK:STDOUT: !85 = !DILocalVariable(arg: 1, scope: !83, type: !14)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 30, column: 12, scope: !83)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 30, column: 5, scope: !83)
|
||||
// CHECK:STDOUT: !88 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299", scope: null, file: !39, line: 138, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !89)
|
||||
// CHECK:STDOUT: !86 = !DILocation(line: 31, column: 12, scope: !83)
|
||||
// CHECK:STDOUT: !87 = !DILocation(line: 31, column: 5, scope: !83)
|
||||
// CHECK:STDOUT: !88 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.a3238f3d1f6ba299", scope: null, file: !39, line: 150, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !89)
|
||||
// CHECK:STDOUT: !89 = !{!90}
|
||||
// CHECK:STDOUT: !90 = !DILocalVariable(arg: 1, scope: !88, type: !14)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 139, column: 14, scope: !88)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 140, column: 5, scope: !88)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 139, column: 18, scope: !88)
|
||||
// CHECK:STDOUT: !94 = !DILocation(line: 141, column: 5, scope: !88)
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f", scope: null, file: !39, line: 138, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !96)
|
||||
// CHECK:STDOUT: !91 = !DILocation(line: 151, column: 14, scope: !88)
|
||||
// CHECK:STDOUT: !92 = !DILocation(line: 153, column: 5, scope: !88)
|
||||
// CHECK:STDOUT: !93 = !DILocation(line: 151, column: 18, scope: !88)
|
||||
// CHECK:STDOUT: !94 = !DILocation(line: 154, column: 5, scope: !88)
|
||||
// CHECK:STDOUT: !95 = distinct !DISubprogram(name: "Some", linkageName: "_CSome.e8f8f92d3d08d149:OptionalStorage.Core.2e8a3baa837dcd9f", scope: null, file: !39, line: 150, type: !40, spFlags: DISPFlagDefinition, unit: !5, retainedNodes: !96)
|
||||
// CHECK:STDOUT: !96 = !{!97}
|
||||
// CHECK:STDOUT: !97 = !DILocalVariable(arg: 1, scope: !95, type: !14)
|
||||
// CHECK:STDOUT: !98 = !DILocation(line: 139, column: 14, scope: !95)
|
||||
// CHECK:STDOUT: !99 = !DILocation(line: 140, column: 5, scope: !95)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 139, column: 18, scope: !95)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 141, column: 5, scope: !95)
|
||||
// CHECK:STDOUT: !98 = !DILocation(line: 151, column: 14, scope: !95)
|
||||
// CHECK:STDOUT: !99 = !DILocation(line: 153, column: 5, scope: !95)
|
||||
// CHECK:STDOUT: !100 = !DILocation(line: 151, column: 18, scope: !95)
|
||||
// CHECK:STDOUT: !101 = !DILocation(line: 154, column: 5, scope: !95)
|
||||
// CHECK:STDOUT: ; ModuleID = 'receive.carbon'
|
||||
// CHECK:STDOUT: source_filename = "receive.carbon"
|
||||
// CHECK:STDOUT: target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
|
||||
|
||||
Reference in New Issue
Block a user