Simplify Module/Submodule statement argument usage
[yangtools.git] / yang / yang-parser-rfc7950 / src / main / java / org / opendaylight / yangtools / yang / parser / rfc7950 / stmt / import_ / AbstractImportStatementSupport.java
index bb40970a9ead84d05087db775df616c75135d4fa..1cffa632d5f5c1667f95f51476777c473b0735ae 100644 (file)
@@ -60,14 +60,13 @@ abstract class AbstractImportStatementSupport
         final ModelActionBuilder importAction = stmt.newInferenceAction(SOURCE_PRE_LINKAGE);
         final Prerequisite<StmtContext<?, ?, ?>> imported = importAction.requiresCtx(stmt,
                 PreLinkageModuleNamespace.class, moduleName, SOURCE_PRE_LINKAGE);
-        final Prerequisite<Mutable<?, ?, ?>> linkageTarget = importAction
-                .mutatesCtx(stmt.getRoot(), SOURCE_PRE_LINKAGE);
+        importAction.mutatesCtx(stmt.getRoot(), SOURCE_PRE_LINKAGE);
 
         importAction.apply(new InferenceAction() {
             @Override
             public void apply(final InferenceContext ctx) {
                 final StmtContext<?, ?, ?> importedModuleContext = imported.resolve(ctx);
-                Verify.verify(moduleName.equals(importedModuleContext.getStatementArgument()));
+                Verify.verify(moduleName.equals(importedModuleContext.coerceRawStatementArgument()));
                 final URI importedModuleNamespace = importedModuleContext.getFromNamespace(ModuleNameToNamespace.class,
                         moduleName);
                 Verify.verifyNotNull(importedModuleNamespace);