You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// CHECK:STDERR: fail_todo_import_string_literal_object_like_macro.carbon:[[@LINE+11]]:3: error: semantics TODO: `Unsupported: macro evaluated to a constant of type: const char[4]` [SemanticsTodo]
268
-
// CHECK:STDERR: Cpp.CONFIG_VALUE;
269
-
// CHECK:STDERR: ^~~~~~~~~~~~~~~~
270
-
// CHECK:STDERR: fail_todo_import_string_literal_object_like_macro.carbon:[[@LINE+8]]:3: note: in `Cpp` name lookup for `CONFIG_VALUE` [InCppNameLookup]
271
-
// CHECK:STDERR: Cpp.CONFIG_VALUE;
272
-
// CHECK:STDERR: ^~~~~~~~~~~~~~~~
273
-
// CHECK:STDERR:
274
-
// CHECK:STDERR: fail_todo_import_string_literal_object_like_macro.carbon:[[@LINE+4]]:3: error: member name `CONFIG_VALUE` not found in `Cpp` [MemberNameNotFoundInInstScope]
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+8]]:2: note: in `Cpp` name lookup for `Utf16Greeting` [InCppNameLookup]
301
+
// CHECK:STDERR: Cpp.Utf16Greeting;
302
+
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
303
+
// CHECK:STDERR:
304
+
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+4]]:2: error: member name `Utf16Greeting` not found in `Cpp` [MemberNameNotFoundInInstScope]
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+8]]:2: note: in `Cpp` name lookup for `Utf32Greeting` [InCppNameLookup]
313
+
// CHECK:STDERR: Cpp.Utf32Greeting;
314
+
// CHECK:STDERR: ^~~~~~~~~~~~~~~~~
315
+
// CHECK:STDERR:
316
+
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+4]]:2: error: member name `Utf32Greeting` not found in `Cpp` [MemberNameNotFoundInInstScope]
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+8]]:2: note: in `Cpp` name lookup for `WideGreeting` [InCppNameLookup]
325
+
// CHECK:STDERR: Cpp.WideGreeting;
326
+
// CHECK:STDERR: ^~~~~~~~~~~~~~~~
327
+
// CHECK:STDERR:
328
+
// CHECK:STDERR: fail_import_unsupported_string_literal_types.carbon:[[@LINE+4]]:2: error: member name `WideGreeting` not found in `Cpp` [MemberNameNotFoundInInstScope]
329
+
// CHECK:STDERR: Cpp.WideGreeting;
330
+
// CHECK:STDERR: ^~~~~~~~~~~~~~~~
331
+
// CHECK:STDERR:
332
+
Cpp.WideGreeting;
333
+
}
334
+
335
+
// --- fail_bad_string.carbon
336
+
337
+
library "[[@TEST_NAME]]";
338
+
339
+
importCpp inline '''
340
+
#define BadString "123" 456
341
+
''';
342
+
343
+
fnF() {
344
+
// CHECK:STDERR: fail_bad_string.carbon:[[@LINE+11]]:2: error: failed to parse macro Cpp.BadString to a valid constant expression [InCppMacroEvaluation]
345
+
// CHECK:STDERR: Cpp.BadString;
346
+
// CHECK:STDERR: ^~~~~~~~~~~~~
347
+
// CHECK:STDERR: fail_bad_string.carbon:[[@LINE+8]]:2: note: in `Cpp` name lookup for `BadString` [InCppNameLookup]
348
+
// CHECK:STDERR: Cpp.BadString;
349
+
// CHECK:STDERR: ^~~~~~~~~~~~~
350
+
// CHECK:STDERR:
351
+
// CHECK:STDERR: fail_bad_string.carbon:[[@LINE+4]]:2: error: member name `BadString` not found in `Cpp` [MemberNameNotFoundInInstScope]
0 commit comments