Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 5E86C200B43 for ; Tue, 19 Jul 2016 22:32:00 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 59086160A76; Tue, 19 Jul 2016 20:32:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 7CFF2160A5C for ; Tue, 19 Jul 2016 22:31:59 +0200 (CEST) Received: (qmail 43626 invoked by uid 500); 19 Jul 2016 20:31:58 -0000 Mailing-List: contact dev-help@flex.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flex.apache.org Delivered-To: mailing list dev@flex.apache.org Received: (qmail 43614 invoked by uid 99); 19 Jul 2016 20:31:58 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Jul 2016 20:31:58 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id D662A1A8317 for ; Tue, 19 Jul 2016 20:31:57 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.793 X-Spam-Level: * X-Spam-Status: No, score=1.793 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_WEB=0.614, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id 2o96vhNzFP9o for ; Tue, 19 Jul 2016 20:31:55 +0000 (UTC) Received: from mail-wm0-f42.google.com (mail-wm0-f42.google.com [74.125.82.42]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 6758E60D56 for ; Tue, 19 Jul 2016 20:31:55 +0000 (UTC) Received: by mail-wm0-f42.google.com with SMTP id i5so40595670wmg.0 for ; Tue, 19 Jul 2016 13:31:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:message-id:mime-version:subject:date:references:to:in-reply-to; bh=pAAVysobMzDha6IoRI9+Ge6X3gsS0lFiSo59Z2ou6Iw=; b=dyRJjNlQPk1J5U/EZSLC4hwk8gApQWMWztlHdSqjkBPq49EWkEQKsYzLLn4yYl/tyJ idg4ExLDVmVfvedvNaEgUEhdk9zJwSitj8Eh8n19L5V9kkaoKoVU6UVRUiK68y+9RhMB UG5VIxgOIjAjPps8FonGHYaxwJzav7bTr7nTdvpS4F9NOmuj7JiDwY+wH+dAOk1SWZHb LR8RnWs0+XogTAFHqukctH9qPERJkvOvzydtWvcfbmldyRASaInLkwRl/HGPnIpUPMpf xNaibwSX9keGzuSk6Aeit8AjGvJh2JCdnoTw1x+OiNDrm/xDZ0CiVlkgyPxWRrdOnCx6 OUNA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:message-id:mime-version:subject:date :references:to:in-reply-to; bh=pAAVysobMzDha6IoRI9+Ge6X3gsS0lFiSo59Z2ou6Iw=; b=f9qSif8YxRTbj99gEIgaMGnMcgLlSJuPtz64fGXVz7jeotayVgY8xtIN+duvP0qaGV q0xwVFSJaCXtXEzguV+UPNB27fgLmp1k5wogWcyudF9j9Ke+VhlbPQppYK/h3fiGnqPO +tKU9O4zZrG5fZM1RALCGvSDtUGYPC8Bv2UOa+5ezSADXyx8FANfJpG/MTJt+fuhyyXT lCTCxUcZ8wt2F7v2qNlGtiEUKXxerKZWEQOVHXAgv+9G5voIJawo0Iogmsq86vNoF+7Q gNePcNQrYyF0VoHgD+QloM8se6S0DxaVJjlYdx4tbFh2N7ZVA7sYRBV+jpjudtGYDP69 Bv7A== X-Gm-Message-State: ALyK8tKNhi8NuuS1yCVKJv8oneAnsRSK0blpsF6PtOfZm8ZoC6T656KNvuyOLLJAlRyr5g== X-Received: by 10.28.26.69 with SMTP id a66mr6295203wma.8.1468960309065; Tue, 19 Jul 2016 13:31:49 -0700 (PDT) Received: from [127.0.0.1] ([185.120.125.113]) by smtp.gmail.com with ESMTPSA id v203sm25863234wmv.2.2016.07.19.13.31.47 for (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 19 Jul 2016 13:31:48 -0700 (PDT) From: Harbs Content-Type: multipart/alternative; boundary="Apple-Mail=_0D2DD3F4-EDE0-458F-99CF-74BCBFE72F9E" Message-Id: Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: FlexJS Closure Compiler optimizations Date: Tue, 19 Jul 2016 23:31:46 +0300 References: To: dev@flex.apache.org In-Reply-To: X-Mailer: Apple Mail (2.1878.6) archived-at: Tue, 19 Jul 2016 20:32:00 -0000 --Apple-Mail=_0D2DD3F4-EDE0-458F-99CF-74BCBFE72F9E Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 I was not getting any errors, but I was getting a lot of warnings. I eliminated virtually all the warnings in my code with the exception of = two "WARNING - unreachable code=94 errors. Eliminating the first one = causes a Falcon compiler error, and the second appears to be a bug in = the Closure compiler. The remaining warnings I=92m getting are the following ones. I have no = idea why I=92m getting them or how to eliminate them. I also don=92t = know whether this is causing my problems of the main app class not being = defined. Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/array/array.= js:619: WARNING - actual parameter 1 of goog.array.contains does not = match formal parameter found : (Array|null) required: (IArrayLike|null|string) if (!goog.array.contains(arr, obj)) { ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/array/array.= js:659: WARNING - actual parameter 1 of goog.array.indexOf does not = match formal parameter found : (Array|null) required: (IArrayLike|null|string) if (arguments.length =3D=3D 2 || (i =3D goog.array.indexOf(arr, = opt_obj2)) < 0) { ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/array/array.= js:662: WARNING - actual parameter 1 of goog.array.insertAt does not = match formal parameter found : (Array|null) required: (IArrayLike|null) goog.array.insertAt(arr, obj, i); ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/array/array.= js:1643: WARNING - actual parameter 1 of goog.array.forEach does not = match formal parameter found : Array required: (IArrayLike|null|string) goog.array.forEach(index_arr, function(index) { = result.push(arr[index]); }); ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/events/liste= nermap.js:149: WARNING - actual parameter 1 of goog.array.removeAt does = not match formal parameter found : Array required: (IArrayLike|null) goog.array.removeAt(listenerArray, index); ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/events/liste= nermap.js:171: WARNING - actual parameter 1 of goog.array.remove does = not match formal parameter found : Array required: (IArrayLike|null) var removed =3D goog.array.remove(this.listeners[type], listener); ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/labs/userage= nt/browser.js:233: WARNING - actual parameter 1 of goog.array.forEach = does not match formal parameter found : Array> required: (IArrayLike|null|string) goog.array.forEach(versionTuples, function(tuple) { ^ Jul 19, 2016 11:22:39 PM com.google.javascript.jscomp.LoggerErrorManager = println WARNING: /Users/harbs/Documents/Apache Flex = Dist/FlexJSNightly/js/lib/google/closure-library/closure/goog/labs/userage= nt/engine.js:153: WARNING - actual parameter 1 of goog.array.find does = not match formal parameter found : Array> required: (IArrayLike|null|string) var pair =3D goog.array.find(tuples, function(pair) { return key =3D=3D = pair[0]; }); =20 On Jul 19, 2016, at 4:50 PM, Alex Harui wrote: >> 1. It=92s optimized to the point where it does not work. If I run >> MyApp.start() in index.html, I get an error that MyApp is not = defined. >> Looking in the JS, I see that Em=3D=91MyApp=92. Is there something = special I >> need to do to prevent this from happening? >=20 > This usually means some exception was thrown at init time and MyApp = never > got set as a exported symbol. You have to eliminate all runtime > exceptions during class definition and prototype setup before MyApp is > defined. --Apple-Mail=_0D2DD3F4-EDE0-458F-99CF-74BCBFE72F9E--