default xml namespace directive causes VerifyError: Error #1025 for a private class variable

VERIFIED INVALID

Status

VERIFIED INVALID
10 years ago
9 years ago

People

(Reporter: cpeyer, Unassigned)

Tracking

Details

(Reporter)

Description

10 years ago
Steps to reproduce:
as:
package {
	public class TestClass {
		private var _testVar:String;
		public function TestClass() {
			var testXML:XML = <node1 xmlns="http://www.testurl.com/"><node2><node3>some words of wisdom</node3></node2></node1>;
			default xml namespace = testXML.namespace("");
			_testVar = testXML.node2.node3;
		}
		public function get testVar():String {
			return _testVar;
		}		
	}
}

import TestClass;
var myTestClass:TestClass = new TestClass();
var someVar:String = myTestClass.testVar;
trace(someVar);

 
 Actual Results:
verify TestClass/get testVar()
                        stack:
                        scope: [global Object$ TestClass$] 
                         locals: TestClass 
  0:getlocal0
                        stack: TestClass
                        scope: [global Object$ TestClass$] 
                         locals: TestClass 
  1:pushscope
                        stack:
                        scope: [global Object$ TestClass$] TestClass 
                         locals: TestClass 
  2:getlocal1
VerifyError: Error #1025: An invalid register 1 was accessed.
	at TestClass/get testVar()
	at Test_fla::MainTimeline/Test_fla::frame1()

 Expected Results:
No verify error. 
 
 Workaround (if any):
1. set _testVar to be a public class variable OR
2. don't use default namespace:
var testNS:Namespace = new Namespace(testXML.namespace(""));
_testVar = testXML.testNS::node2.testNS::node3;

 Bug originally pointed out by end-user: Levi Mendes -  levimendes@gmail.com
 
 

This bug transferred from: http://bugs.adobe.com/jira/browse/ASC-2800
(Reporter)

Comment 1

10 years ago
test transfer ignore.
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → INVALID
(Reporter)

Updated

9 years ago
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.