parent
							
								
									97a629eef9
								
							
						
					
					
						commit
						9a470a49d8
					
				
					 4 changed files with 10 additions and 8 deletions
				
			
		|  | @ -81,7 +81,7 @@ dependencies { | ||||||
| 	implementation ('net.fabricmc:tiny-mappings-parser:0.3.0+build.17') | 	implementation ('net.fabricmc:tiny-mappings-parser:0.3.0+build.17') | ||||||
| 
 | 
 | ||||||
| 	implementation 'net.fabricmc:access-widener:1.1.0' | 	implementation 'net.fabricmc:access-widener:1.1.0' | ||||||
| 	implementation 'net.fabricmc:mapping-io:0.1.3' | 	implementation 'net.fabricmc:mapping-io:0.2.0' | ||||||
| 
 | 
 | ||||||
| 	implementation ('net.fabricmc:lorenz-tiny:3.0.0') { | 	implementation ('net.fabricmc:lorenz-tiny:3.0.0') { | ||||||
| 		transitive = false | 		transitive = false | ||||||
|  |  | ||||||
|  | @ -76,7 +76,7 @@ public class LayeredMappingsDependency implements SelfResolvingDependency { | ||||||
| 					Tiny2Writer tiny2Writer = new Tiny2Writer(writer, false); | 					Tiny2Writer tiny2Writer = new Tiny2Writer(writer, false); | ||||||
| 
 | 
 | ||||||
| 					MappingDstNsReorder nsReorder = new MappingDstNsReorder(tiny2Writer, Collections.singletonList(MappingNamespace.NAMED.stringValue())); | 					MappingDstNsReorder nsReorder = new MappingDstNsReorder(tiny2Writer, Collections.singletonList(MappingNamespace.NAMED.stringValue())); | ||||||
| 					MappingSourceNsSwitch nsSwitch = new MappingSourceNsSwitch(nsReorder, MappingNamespace.INTERMEDIARY.stringValue()); | 					MappingSourceNsSwitch nsSwitch = new MappingSourceNsSwitch(nsReorder, MappingNamespace.INTERMEDIARY.stringValue(), true); | ||||||
| 					mappings.accept(nsSwitch); | 					mappings.accept(nsSwitch); | ||||||
| 
 | 
 | ||||||
| 					Files.deleteIfExists(mappingsFile); | 					Files.deleteIfExists(mappingsFile); | ||||||
|  |  | ||||||
|  | @ -24,6 +24,7 @@ | ||||||
| 
 | 
 | ||||||
| package net.fabricmc.loom.configuration.providers.mappings.parchment; | package net.fabricmc.loom.configuration.providers.mappings.parchment; | ||||||
| 
 | 
 | ||||||
|  | import java.io.IOException; | ||||||
| import java.util.Locale; | import java.util.Locale; | ||||||
| 
 | 
 | ||||||
| import net.fabricmc.mappingio.MappingVisitor; | import net.fabricmc.mappingio.MappingVisitor; | ||||||
|  | @ -35,7 +36,7 @@ public final class ParchmentPrefixStripingMappingVisitor extends ForwardingMappi | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
| 	@Override | 	@Override | ||||||
| 	public boolean visitMethodArg(int argPosition, int lvIndex, String srcName) { | 	public boolean visitMethodArg(int argPosition, int lvIndex, String srcName) throws IOException { | ||||||
| 		return super.visitMethodArg(argPosition, lvIndex, stripMethodArg(srcName)); | 		return super.visitMethodArg(argPosition, lvIndex, stripMethodArg(srcName)); | ||||||
| 	} | 	} | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
|  | @ -24,6 +24,7 @@ | ||||||
| 
 | 
 | ||||||
| package net.fabricmc.loom.configuration.providers.mappings.parchment; | package net.fabricmc.loom.configuration.providers.mappings.parchment; | ||||||
| 
 | 
 | ||||||
|  | import java.io.IOException; | ||||||
| import java.util.Collections; | import java.util.Collections; | ||||||
| import java.util.List; | import java.util.List; | ||||||
| 
 | 
 | ||||||
|  | @ -39,7 +40,7 @@ public record ParchmentTreeV1( | ||||||
| 		@Nullable | 		@Nullable | ||||||
| 		List<Package> packages | 		List<Package> packages | ||||||
| ) { | ) { | ||||||
| 	public void visit(MappingVisitor visitor, String srcNamespace) { | 	public void visit(MappingVisitor visitor, String srcNamespace) throws IOException { | ||||||
| 		while (true) { | 		while (true) { | ||||||
| 			if (visitor.visitHeader()) { | 			if (visitor.visitHeader()) { | ||||||
| 				visitor.visitNamespaces(srcNamespace, Collections.emptyList()); | 				visitor.visitNamespaces(srcNamespace, Collections.emptyList()); | ||||||
|  | @ -68,7 +69,7 @@ public record ParchmentTreeV1( | ||||||
| 			@Nullable | 			@Nullable | ||||||
| 			List<String> javadoc | 			List<String> javadoc | ||||||
| 	) { | 	) { | ||||||
| 		public void visit(MappingVisitor visitor) { | 		public void visit(MappingVisitor visitor) throws IOException { | ||||||
| 			if (visitor.visitClass(name())) { | 			if (visitor.visitClass(name())) { | ||||||
| 				if (!visitor.visitElementContent(MappedElementKind.CLASS)) { | 				if (!visitor.visitElementContent(MappedElementKind.CLASS)) { | ||||||
| 					return; | 					return; | ||||||
|  | @ -99,7 +100,7 @@ public record ParchmentTreeV1( | ||||||
| 			@Nullable | 			@Nullable | ||||||
| 			List<String> javadoc | 			List<String> javadoc | ||||||
| 	) { | 	) { | ||||||
| 		public void visit(MappingVisitor visitor) { | 		public void visit(MappingVisitor visitor) throws IOException { | ||||||
| 			if (visitor.visitField(name, descriptor)) { | 			if (visitor.visitField(name, descriptor)) { | ||||||
| 				if (!visitor.visitElementContent(MappedElementKind.FIELD)) { | 				if (!visitor.visitElementContent(MappedElementKind.FIELD)) { | ||||||
| 					return; | 					return; | ||||||
|  | @ -120,7 +121,7 @@ public record ParchmentTreeV1( | ||||||
| 			@Nullable | 			@Nullable | ||||||
| 			List<String> javadoc | 			List<String> javadoc | ||||||
| 	) { | 	) { | ||||||
| 		public void visit(MappingVisitor visitor) { | 		public void visit(MappingVisitor visitor) throws IOException { | ||||||
| 			if (visitor.visitMethod(name, descriptor)) { | 			if (visitor.visitMethod(name, descriptor)) { | ||||||
| 				if (!visitor.visitElementContent(MappedElementKind.METHOD)) { | 				if (!visitor.visitElementContent(MappedElementKind.METHOD)) { | ||||||
| 					return; | 					return; | ||||||
|  | @ -145,7 +146,7 @@ public record ParchmentTreeV1( | ||||||
| 			@Nullable | 			@Nullable | ||||||
| 			String javadoc | 			String javadoc | ||||||
| 	) { | 	) { | ||||||
| 		public void visit(MappingVisitor visitor) { | 		public void visit(MappingVisitor visitor) throws IOException { | ||||||
| 			if (visitor.visitMethodArg(index, index, name)) { | 			if (visitor.visitMethodArg(index, index, name)) { | ||||||
| 				if (!visitor.visitElementContent(MappedElementKind.METHOD_ARG)) { | 				if (!visitor.visitElementContent(MappedElementKind.METHOD_ARG)) { | ||||||
| 					return; | 					return; | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue