From 50f10f1f474e1a37501e6b4635b2fd1dbd8cecb2 Mon Sep 17 00:00:00 2001
From: Volker Berlin <volker.berlin@googlemail.com>
Date: Tue, 10 Sep 2019 17:52:14 +0200
Subject: [PATCH] move debugNames into WasmOptions

---
 .../inetsoftware/jwebassembly/wasm/WasmOptions.java  | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/src/de/inetsoftware/jwebassembly/wasm/WasmOptions.java b/src/de/inetsoftware/jwebassembly/wasm/WasmOptions.java
index 26a0743..49e5b22 100644
--- a/src/de/inetsoftware/jwebassembly/wasm/WasmOptions.java
+++ b/src/de/inetsoftware/jwebassembly/wasm/WasmOptions.java
@@ -26,6 +26,8 @@ import de.inetsoftware.jwebassembly.JWebAssembly;
  */
 public class WasmOptions {
 
+    private final boolean debugNames;
+
     private final boolean useGC;
 
     /**
@@ -35,9 +37,19 @@ public class WasmOptions {
      *            compiler properties
      */
     public WasmOptions( HashMap<String, String> properties ) {
+        debugNames = Boolean.parseBoolean( properties.get( JWebAssembly.DEBUG_NAMES ) );
         useGC = Boolean.parseBoolean( properties.getOrDefault( JWebAssembly.WASM_USE_GC, "false" ) );
     }
 
+    /**
+     * Property for adding debug names to the output if true.
+     * 
+     * @return true, add debug information
+     */
+    public boolean debugNames() {
+        return debugNames;
+    }
+
     /**
      * If the GC feature of WASM should be use or the GC of the JavaScript host.
      *