You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by gr...@apache.org on 2019/05/04 21:36:46 UTC

[royale-asjs] branch improvements/Language updated: Leaving conditional stuff out for now. It will definitely be possible to introduce this type of in the future, but it affects all instances. Needs some discussion. Also renamed 'override' group changin 'fixedLength' to 'mainTypeSafety' (it is not just for fixed length safety, and just represents commonly used mutation methods)

This is an automated email from the ASF dual-hosted git repository.

gregdove pushed a commit to branch improvements/Language
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git


The following commit(s) were added to refs/heads/improvements/Language by this push:
     new 453fd5b  Leaving conditional stuff out for now. It will definitely be possible to introduce this type of in the future, but it affects all instances. Needs some discussion. Also renamed 'override' group changin 'fixedLength' to 'mainTypeSafety' (it is not just for fixed length safety, and just represents commonly used mutation methods)
453fd5b is described below

commit 453fd5bddf16a107769a66b549be29786d550685
Author: greg-dove <gr...@gmail.com>
AuthorDate: Sun May 5 06:52:23 2019 +1200

    Leaving conditional stuff out for now. It will definitely be possible to introduce this type of in the future, but it affects all instances. Needs some discussion.
    Also renamed 'override' group changin 'fixedLength' to 'mainTypeSafety' (it is not just for fixed length safety, and just represents commonly used mutation methods)
---
 .../src/main/royale/org/apache/royale/utils/Language.as | 17 +++++++----------
 1 file changed, 7 insertions(+), 10 deletions(-)

diff --git a/frameworks/projects/Language/src/main/royale/org/apache/royale/utils/Language.as b/frameworks/projects/Language/src/main/royale/org/apache/royale/utils/Language.as
index a7d8c19..c926fef 100644
--- a/frameworks/projects/Language/src/main/royale/org/apache/royale/utils/Language.as
+++ b/frameworks/projects/Language/src/main/royale/org/apache/royale/utils/Language.as
@@ -40,11 +40,7 @@ package org.apache.royale.utils
     COMPILE::JS
     public class Language
     {
-    
-        /**
-         * @royalesuppresspublicvarwarning
-         */
-        public static var runtimeVectorSafety:Boolean = goog.DEBUG || true;
+        
         
         //--------------------------------------
         //   Static Property
@@ -794,9 +790,10 @@ class VectorSupport {
         props[Language.SYNTH_TAG_FIELD] = {
             value: inst
         };
-        
-        if (Language.runtimeVectorSafety) {
-            blend(props, getFixedLengthOverrides())
+        blend(props, getMainTypeSafetyOverrides());
+        //possible future runtime performance tuning based on compilation 'define' setting tweaks
+       /* if (Language.runtimeVectorSafety) {
+            blend(props, getMainTypeSafetyOverrides())
         } else {
             blend(props, {
                 'insertAt':{
@@ -806,7 +803,7 @@ class VectorSupport {
                     value: inst.removeAt
                 }
             })
-        }
+        }*/
         
         Object.defineProperties (array, props);
         return array;
@@ -857,7 +854,7 @@ class VectorSupport {
     }
     
     private static var _fixedLenObject:Object;
-    public static function getFixedLengthOverrides():Object{
+    public static function getMainTypeSafetyOverrides():Object{
         if (_fixedLenObject) return _fixedLenObject;
         _fixedLenObject = {
             'pop': {