@@ -1377,24 +1377,84 @@ pub fn to_real_manifest(
13771377 }
13781378
13791379 if is_embedded {
1380+ let manifest:: TomlManifest {
1381+ cargo_features : _,
1382+ package : _,
1383+ project : _,
1384+ badges : _,
1385+ features : _,
1386+ lib,
1387+ bin,
1388+ example,
1389+ test,
1390+ bench,
1391+ dependencies : _,
1392+ dev_dependencies : _,
1393+ dev_dependencies2 : _,
1394+ build_dependencies : _,
1395+ build_dependencies2 : _,
1396+ target : _,
1397+ lints : _,
1398+ hints : _,
1399+ workspace,
1400+ profile : _,
1401+ patch : _,
1402+ replace : _,
1403+ _unused_keys : _,
1404+ } = & original_toml;
13801405 let mut invalid_fields = vec ! [
1381- ( "`workspace`" , original_toml . workspace. is_some( ) ) ,
1382- ( "`lib`" , original_toml . lib. is_some( ) ) ,
1383- ( "`bin`" , original_toml . bin. is_some( ) ) ,
1384- ( "`example`" , original_toml . example. is_some( ) ) ,
1385- ( "`test`" , original_toml . test. is_some( ) ) ,
1386- ( "`bench`" , original_toml . bench. is_some( ) ) ,
1406+ ( "`workspace`" , workspace. is_some( ) ) ,
1407+ ( "`lib`" , lib. is_some( ) ) ,
1408+ ( "`bin`" , bin. is_some( ) ) ,
1409+ ( "`example`" , example. is_some( ) ) ,
1410+ ( "`test`" , test. is_some( ) ) ,
1411+ ( "`bench`" , bench. is_some( ) ) ,
13871412 ] ;
13881413 if let Some ( package) = original_toml. package ( ) {
1414+ let manifest:: TomlPackage {
1415+ edition : _,
1416+ rust_version : _,
1417+ name : _,
1418+ version : _,
1419+ authors : _,
1420+ build,
1421+ metabuild : _,
1422+ default_target : _,
1423+ forced_target : _,
1424+ links,
1425+ exclude : _,
1426+ include : _,
1427+ publish : _,
1428+ workspace,
1429+ im_a_teapot : _,
1430+ autolib,
1431+ autobins,
1432+ autoexamples,
1433+ autotests,
1434+ autobenches,
1435+ default_run : _,
1436+ description : _,
1437+ homepage : _,
1438+ documentation : _,
1439+ readme : _,
1440+ keywords : _,
1441+ categories : _,
1442+ license : _,
1443+ license_file : _,
1444+ repository : _,
1445+ resolver : _,
1446+ metadata : _,
1447+ _invalid_cargo_features : _,
1448+ } = package. as_ref ( ) ;
13891449 invalid_fields. extend ( [
1390- ( "`package.workspace`" , package . workspace . is_some ( ) ) ,
1391- ( "`package.build`" , package . build . is_some ( ) ) ,
1392- ( "`package.links`" , package . links . is_some ( ) ) ,
1393- ( "`package.autolib`" , package . autolib . is_some ( ) ) ,
1394- ( "`package.autobins`" , package . autobins . is_some ( ) ) ,
1395- ( "`package.autoexamples`" , package . autoexamples . is_some ( ) ) ,
1396- ( "`package.autotests`" , package . autotests . is_some ( ) ) ,
1397- ( "`package.autobenches`" , package . autobenches . is_some ( ) ) ,
1450+ ( "`package.workspace`" , workspace. is_some ( ) ) ,
1451+ ( "`package.build`" , build. is_some ( ) ) ,
1452+ ( "`package.links`" , links. is_some ( ) ) ,
1453+ ( "`package.autolib`" , autolib. is_some ( ) ) ,
1454+ ( "`package.autobins`" , autobins. is_some ( ) ) ,
1455+ ( "`package.autoexamples`" , autoexamples. is_some ( ) ) ,
1456+ ( "`package.autotests`" , autotests. is_some ( ) ) ,
1457+ ( "`package.autobenches`" , autobenches. is_some ( ) ) ,
13981458 ] ) ;
13991459 }
14001460 let invalid_fields = invalid_fields
0 commit comments